Show Table in SQL
The following examples show an Object File System system table.
SHOW TABLE t1;
Result:
CREATE MULTISET TABLE D2.t1 ,FALLBACK ,
NO BEFORE JOURNAL,
NO AFTER JOURNAL,
CHECKSUM = DEFAULT,
DEFAULT MERGEBLOCKRATIO,
STORAGE = TD_OFSSTORAGE
(
StoreNo SMALLINT,
OrderTotal INTEGER)
NO PRIMARY INDEX ;
Show Table in XML
SHOW IN XML TABLE t1 ;
Result:
<?xml version="1.0" encoding="UTF-16" standalone="no" ?> <TeradataDBObjectSet version="1.0" xmlns="http://schemas.teradata.com/dbobject" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://schemas8956.example.com/dbobject http://schemas8956.example.com/dbobject/DBObject.xsd"> <Table afterJournal="No" baseClass="Table" beforeJournal="No" checkSumLevel="Default" dbName="D1" fallback="true" kind="Multiset" map_kind="contiguous" mergeBlockRatio="Default" name="t1" objId="0:3400" objVer="1" storage="TD_OFSSTORAGE" storage_kind="nos" systemVersioned="false"> <ColumnList> <Column name="StoreNo" nullable="true" order="1"><DataType><Integer/></DataType></Column> <Column name="OrderTotal" nullable="true" order="2"><DataType><Integer/></DataType></Column> <Column name="StoreName" nullable="true" order="3"><DataType><Char casespecific="false" charset="LATIN" length="50" uppercase="false" varying="true"/></DataType></Column> </ColumnList> <Indexes> <NoPrimaryIndex/> </Indexes> <OrderList> <Column name="OrderTotal" order="1"/> </OrderList> <SQLText> <![CDATA[CREATE MULTISET TABLE D1.t1 ,FALLBACK , NO BEFORE JOURNAL, NO AFTER JOURNAL, CHECKSUM = DEFAULT, DEFAULT MERGEBLOCKRATIO, STORAGE = TD_OFSSTORAGE ( StoreNo INTEGER, OrderTotal INTEGER, StoreName VARCHAR(50) CHARACTER SET LATIN NOT CASESPECIFIC) NO PRIMARY INDEX ORDER BY ( OrderTotal ) ]]> </SQLText> </Table> <Environment> <Server dbRelease="20a.00.00.08" dbVersion="20a.00.00.08D31" hostName="TDLabs"/> <User userId="00000100" userName="DBC"/> <Session charset="ASCII" dateTime="2022-01-07T21:56:37"/> </Environment> </TeradataDBObjectSet>