How to check the state and type from one table
Table information: state and type
The Status of the table object is showed below:
- C = Set integrity pending
- N = Normal
- X = Inoperative
The type of the table is showed below
TYPE | CHAR(1) | Type of object.
|
To verify the table status and type, after to connect on database at command prompt type:
db2 "select substr(tabname,1,20) , status, type from syscat.tables \
where tabname = 'table_name'"
You will have something like:
TABNAME STATUS TYPE
Table_name N T
1 record(s) selected.
Using the Syscat.tables you can find much more information like Table Status, Which tablespaces the tables reside, table type ,etc.
Access the URL below and on the search type : syscat.tables to see all options and informations that you can see about tables.
http://publib.boulder.ibm.com/infocenter/db2luw/v9/index.jsp