You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Most/all ADO.Net providers I've used have returned their specific types instead of the System.Data.Common types. An example is PostgreSQL:CreateCommand().
Are you opposed to these convenience methods?
Taking a glance at 0.25.1 code, seems like, for example, it could be changed from:
It would be good to apply these kinds of changes to all applicable DbConnection, DbCommand, etc. methods as well. This would make provider specific, and helpful, APIs become more visible and reduce friction from always having to cast from the common types. Example: #127, you can't see AddWithValue unless you cast.
The text was updated successfully, but these errors were encountered:
Here are the "public new" methods in Connector/NET, which could be cloned for API compatibility (ticks by the ones that already exist):
MySqlCommand:
public new MySqlConnection Connection { get; set; }
public new MySqlParameterCollection Parameters { get; } ✔️
public new MySqlTransaction Transaction { get; set; }
public new MySqlParameter CreateParameter()
public new MySqlDataReader ExecuteReader()
public new MySqlDataReader ExecuteReader(CommandBehavior)
MySqlConnection:
public new MySqlTransaction BeginTransaction() ✔️
public new MySqlTransaction BeginTransaction(IsolationLevel)
public new MySqlCommand CreateCommand()
MySqlDataReader:
public new void Dispose() 😱
MySqlParameterCollection:
public new MySqlParameter this[int index] { get; set; } ✔️
public new MySqlParameter this[string name] { get; set; }
Hello.
Most/all ADO.Net providers I've used have returned their specific types instead of the
System.Data.Common
types. An example is PostgreSQL:CreateCommand().Are you opposed to these convenience methods?
Taking a glance at 0.25.1 code, seems like, for example, it could be changed from:
To:
It would be good to apply these kinds of changes to all applicable
DbConnection
,DbCommand
, etc. methods as well. This would make provider specific, and helpful, APIs become more visible and reduce friction from always having to cast from the common types. Example: #127, you can't seeAddWithValue
unless you cast.The text was updated successfully, but these errors were encountered: