MySqlConnector
MySqlConnector copied to clipboard
Support SERVER_PS_OUT_PARAMS
If MySqlConnector sets the ProtocolCapabilities.PreparedStatementMultiResults (CLIENT_PS_MULTI_RESULTS) flag, then prepared CALL statements will automatically provide a extra result set (flagged with ServerStatus.PsOutParams = SERVER_PS_OUT_PARAMS) with the contents of the out parameters.
This would remove the need to explicitly SELECT them in order to populate ParameterDirection.Output parameters after executing a CommandType.StoredProcedure command. (Split from #742.)
However, since this is an optional protocol feature (since MySQL 5.5.3, and TBD support from cloud providers), the client would still need to support both ways of retrieving output parameters. The CALL statement would still have to be parsed so that the order of parameters is known so that they can be assigned correctly.
(Perhaps a lot of the existing logic can be reused by setting ResultSet.ContainsCommandParameters based on the ServerStatus.PsOutParams flag?)