MySqlDbHelper
This class implements IDbHelper for MySql.Data. It queries INFORMATION_SCHEMA.COLUMNS to build the list of DbField objects RepoDB uses internally to generate SQL statements. Columns with a blob/text-like data type (blob, longtext, mediumtext, longblob, mediumblob, tinyblob, binary, varbinary) are treated as unbounded — their reported size is ignored.
It also resolves the newly generated identity value via SELECT LAST_INSERT_ID().
It is automatically registered by MySqlBootstrap — you do not need to instantiate it directly under normal use.
Properties
| Name | Description |
|---|---|
| DbTypeResolver | The IResolver<string, Type> used to convert a MySQL column data type (e.g. varchar) into its equivalent .NET CLR type. Defaults to MySqlDbTypeNameToClientTypeResolver. |
Usability
Only override this if you need a custom type resolver.
var dbHelper = new MySqlDbHelper(new MyCustomMySqlDbTypeNameToClientTypeResolver());
DbHelperMapper.Add<MySqlConnection>(dbHelper, true);