Db2DbHelper
This class implements IDbHelper for Db2. It queries SYSCAT.COLUMNS (schema-qualified by CURRENT SCHEMA when none is specified) to build the list of DbField objects RepoDB uses internally to generate SQL statements, and reads back generated identity values via IDENTITY_VAL_LOCAL() against SYSIBM.SYSDUMMY1.
It is automatically registered by Db2Bootstrap — you do not need to instantiate it directly under normal use.
Properties
| Name | Description |
|---|---|
| DbTypeResolver | The IResolver<string, Type> used to convert a Db2 column data type (e.g. VARCHAR) into its equivalent .NET CLR type. Defaults to Db2DbTypeNameToClientTypeResolver. |
Usability
Only override this if you need a custom type resolver.
var dbHelper = new Db2DbHelper(new MyCustomDb2DbTypeNameToClientTypeResolver());
DbHelperMapper.Add<DB2Connection>(dbHelper, true);