Skip to content

EFCore Dialect 1 support

Compare
Choose a tag to compare
@jeffovercash jeffovercash released this 17 Apr 19:09
· 7 commits to main since this release

Where Identifiers are determined if they need quote identifying access to the ConnectionString, Connection, or DBContext is not possible. The original Fb code just assumes Dialect 3 (which has been the recommended dialect for 23+ years now). To get around this for use in Dialect 1 DBs as a static variable was added in InterBaseSql.EntityFrameworkCore.InterBase.Storage.Internal.IBSqlGenerationHelper called Dialect. It defaults to 3 so if working with a Dialect 3 DB nothing new is needed. To get the proper quote identifying (which would be to not do quoting) in Dialect 1 add the following line somewhere in your code before you start using the DBContext.

        InterBaseSql.EntityFrameworkCore.InterBase.Storage.Internal.IBSqlGenerationHelper.Dialect = 1;

now when the EFCore code generates SQL for you it will not double-quote columns, tables, views, etc.