using System.Data.Common; using ZB.MOM.WW.OtOpcUa.Core.Abstractions; using ZB.MOM.WW.OtOpcUa.Driver.Sql.Contracts; using ZB.MOM.WW.OtOpcUa.Driver.Sql.Tests; namespace ZB.MOM.WW.OtOpcUa.Driver.Sql.Browser.Tests; /// /// in every respect except that it reports . /// It exists for exactly one assertion: Oracle's DATE carries a time-of-day component /// (OracleDialect.MapColumnType says so in as many words), so it is NOT the date-only type the /// row-selector ranking demotes on the other dialects, and an Oracle table whose DATE column is /// declared before its TIMESTAMP must still pick the DATE — the ordinary /// first-in-catalog-order tie-break. /// Without this control, implementing the ranking provider-blind ("any type family spelled /// date is date-only") passes every other test in the suite while silently changing the pick on /// the one backend where the spelling means something else. /// public sealed class OracleFlavouredSqliteDialect : ISqlDialect { private readonly SqliteDialect _inner = new(); /// The whole point of the type: an Oracle-shaped provider over the SQLite catalog. public SqlProvider Provider => SqlProvider.Oracle; /// public DbProviderFactory Factory => _inner.Factory; /// public int MaxBindParameters => _inner.MaxBindParameters; /// public string LivenessSql => _inner.LivenessSql; /// public string SingleRowLimitPrefix => _inner.SingleRowLimitPrefix; /// public string SingleRowLimitSuffix => _inner.SingleRowLimitSuffix; /// public string ListSchemasSql => _inner.ListSchemasSql; /// public string DefaultSchemaSql => _inner.DefaultSchemaSql; /// public string ListTablesSql => _inner.ListTablesSql; /// public string ListColumnsSql => _inner.ListColumnsSql; /// public string QuoteIdentifier(string ident) => _inner.QuoteIdentifier(ident); /// public string ParameterMarker(string baseName) => _inner.ParameterMarker(baseName); /// public string ParameterBindName(string baseName) => _inner.ParameterBindName(baseName); /// public void ConfigureCommand(DbCommand command) => _inner.ConfigureCommand(command); /// public DriverDataType MapColumnType(string sqlDataType) => _inner.MapColumnType(sqlDataType); }