public DatabaseMetadata(DbConnection connection, Dialect.Dialect dialect, bool extras) { meta = dialect.GetDataBaseSchema(connection); this.dialect = dialect; this.extras = extras; InitSequences(connection, dialect); sqlExceptionConverter = dialect.BuildSQLExceptionConverter(); }
private static Iesi.Collections.Generic.ISet<string> GetReservedWords(Dialect.Dialect dialect, IConnectionHelper connectionHelper) { Iesi.Collections.Generic.ISet<string> reservedDb = new HashedSet<string>(); connectionHelper.Prepare(); try { var metaData = dialect.GetDataBaseSchema(connectionHelper.Connection); foreach (var rw in metaData.GetReservedWords()) { reservedDb.Add(rw.ToLowerInvariant()); } } finally { connectionHelper.Release(); } return reservedDb; }