org.h2.table

## Class InformationSchemaTable

- java.lang.Object
- - org.h2.engine.DbObject
  - - org.h2.schema.SchemaObject
    - - org.h2.table.Table
      - - org.h2.table.MetaTable
        - - org.h2.table.InformationSchemaTable

All Implemented Interfaces:
  HasSQL

    public final class InformationSchemaTable
    extends MetaTable

This class is responsible to build the INFORMATION_SCHEMA tables.

### Field Summary

Fields
`static int` `META_TABLE_TYPE_COUNT` The number of meta table types.

### Fields inherited from class org.h2.table.MetaTable

`indexColumn, metaIndex, ROW_COUNT_APPROXIMATION, type`

### Fields inherited from class org.h2.table.Table

`columns, compareMode, EXCLUSIVE_LOCK, isHidden, READ_LOCK, TYPE_CACHED, TYPE_MEMORY, WRITE_LOCK`

### Fields inherited from class org.h2.engine.DbObject

`AGGREGATE, comment, COMMENT, CONSTANT, CONSTRAINT, database, DOMAIN, FUNCTION_ALIAS, INDEX, RIGHT, ROLE, SCHEMA, SEQUENCE, SETTING, SYNONYM, TABLE_OR_VIEW, trace, TRIGGER, USER`

### Fields inherited from interface org.h2.util.HasSQL

`ADD_PLAN_INFORMATION, DEFAULT_SQL_FLAGS, NO_CASTS, QUOTE_ONLY_WHEN_REQUIRED, REPLACE_LOBS_FOR_TRACE, TRACE_SQL_FLAGS`

### Constructor Summary

Constructors
Constructor and Description
`InformationSchemaTable(Schema schema, int id, int type)` Create a new metadata table.

### Method Summary

All Methods Instance Methods Concrete Methods
`boolean` `canGetRowCount(SessionLocal session)` Check if the row count can be retrieved quickly.
`java.util.ArrayList<Row>` `generateRows(SessionLocal session, SearchRow first, SearchRow last)` Generate the data for the given metadata table using the given first and last row filters.
`long` `getMaxDataModificationId()` Get the last data modification id.
`long` `getRowCount(SessionLocal session)` Get the row count for this table.
`long` `getRowCountApproximation(SessionLocal session)` Get the approximated row count for this table.
`boolean` `isView()`

### Methods inherited from class org.h2.table.MetaTable

`add, addIndex, addRow, canDrop, canReference, checkIndex, checkRename, checkSupportAlter, close, column, getCreateSQL, getIndexes, getScanIndex, getTableType, hideTable, identifier, isDeterministic, isInsertable, removeChildrenAndResources, removeRow, setMetaTableName, truncate`

### Methods inherited from class org.h2.table.Table

`addConstraint, addDependencies, addDependentView, addSequence, addSynonym, addTrigger, canTruncate, checkDeadlock, checkWritingAllowed, compareValues, convertInsertRow, convertUpdateRow, createRow, doesColumnExist, dropMultipleColumnsConstraintsAndIndexes, findColumn, findPrimaryKey, fire, fireAfterRow, fireBeforeRow, fireRow, getBestPlanItem, getCheckForeignKeyConstraints, getChildren, getColumn, getColumn, getColumn, getColumns, getCompareMode, getConstraints, getCreateSQLForCopy, getDependentViews, getDiskSpaceUsed, getIdentityColumn, getIndex, getIndexForColumn, getMainIndexColumn, getNullRow, getOnCommitDrop, getOnCommitTruncate, getPrimaryKey, getRow, getRowFactory, getRowIdColumn, getScanIndex, getSQLTableType, getTemplateRow, getTemplateSimpleRow, getTriggers, getType, hasSelectTrigger, isGlobalTemporary, isHidden, isLockedExclusively, isLockedExclusivelyBy, isPersistData, isPersistIndexes, isQueryComparable, isRowLockable, isTableExpression, lock, lockRow, removeColumnExpressionsDependencies, removeConstraint, removeDependentView, removeIndex, removeIndexOrTransferOwnership, removeSequence, removeSynonym, removeTrigger, rename, renameColumn, setCheckForeignKeyConstraints, setColumns, setHidden, setOnCommitDrop, setOnCommitTruncate, setTableExpression, unlock, updateRow, updateRows`

### Methods inherited from class org.h2.schema.SchemaObject

`getSchema, getSQL, getSQL`

### Methods inherited from class org.h2.engine.DbObject

`getComment, getCreateSQLForMeta, getDatabase, getDropSQL, getId, getModificationId, getName, invalidate, isTemporary, isValid, setComment, setModified, setObjectName, setTemporary, toString`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

### Methods inherited from interface org.h2.util.HasSQL

`getTraceSQL`

### Field Detail

#### META_TABLE_TYPE_COUNT

    public static final int META_TABLE_TYPE_COUNT

The number of meta table types. Supported meta table types are `0..META_TABLE_TYPE_COUNT - 1`.

See Also:
  Constant Field Values

### Constructor Detail

#### InformationSchemaTable

    public InformationSchemaTable(Schema schema,
                                  int id,
                                  int type)

Create a new metadata table.

Parameters:
  `schema` - the schema
  `id` - the object id
  `type` - the meta table type

### Method Detail

#### generateRows

    public java.util.ArrayList<Row> generateRows(SessionLocal session,
                                                 SearchRow first,
                                                 SearchRow last)

Description copied from class: `MetaTable`
Generate the data for the given metadata table using the given first and last row filters.

Specified by:
  `generateRows` in class `MetaTable`
Parameters:
  `session` - the session
  `first` - the first row to return
  `last` - the last row to return
Returns:
  the generated rows

#### getMaxDataModificationId

    public long getMaxDataModificationId()

Description copied from class: `Table`
Get the last data modification id.

Specified by:
  `getMaxDataModificationId` in class `Table`
Returns:
  the modification id

#### isView

    public boolean isView()

Overrides:
  `isView` in class `Table`

#### getRowCount

    public long getRowCount(SessionLocal session)

Description copied from class: `Table`
Get the row count for this table.

Overrides:
  `getRowCount` in class `MetaTable`
Parameters:
  `session` - the session
Returns:
  the row count

#### getRowCountApproximation

    public long getRowCountApproximation(SessionLocal session)

Description copied from class: `Table`
Get the approximated row count for this table.

Overrides:
  `getRowCountApproximation` in class `MetaTable`
Parameters:
  `session` - the session
Returns:
  the approximated row count

#### canGetRowCount

    public boolean canGetRowCount(SessionLocal session)

Description copied from class: `Table`
Check if the row count can be retrieved quickly.

Overrides:
  `canGetRowCount` in class `MetaTable`
Parameters:
  `session` - the session
Returns:
  true if it can