Пример #1
0
 public Table(
     Database db,
     String schema,
     String name,
     String comments,
     Properties properties,
     Pattern excludeIndirectColumns,
     Pattern excludeColumns)
     throws SQLException {
   this.schema = schema;
   this.name = name;
   setComments(comments);
   initColumns(db, excludeIndirectColumns, excludeColumns);
   initIndexes(db, properties);
   initPrimaryKeys(db.getMetaData(), properties);
   numRows = Config.getInstance().isNumRowsEnabled() ? fetchNumRows(db, properties) : -1;
 }
Пример #2
0
 /**
  * Construct a table that knows everything about the database table's metadata
  *
  * @param db
  * @param schema
  * @param name
  * @param comments
  * @param properties
  * @param excludeIndirectColumns
  * @param excludeColumns
  * @throws SQLException
  */
 public Table(
     Database db,
     String schema,
     String name,
     String comments,
     Properties properties,
     Pattern excludeIndirectColumns,
     Pattern excludeColumns)
     throws SQLException {
   this.schema = schema;
   this.name = name;
   this.db = db;
   this.properties = properties;
   logger.fine(
       "Creating " + getClass().getSimpleName().toLowerCase() + " " + schema == null
           ? name
           : (schema + '.' + name));
   setComments(comments);
   initColumns(excludeIndirectColumns, excludeColumns);
   initIndexes();
   initPrimaryKeys(db.getMetaData());
 }