Examples: Show a PTI Table
Below is the table definition for an example of a table that uses the timebucket option without sequencing:
CREATE TABLE ts_timebucketonly_nonseq (i INT, j INT, k INT) PRIMARY TIME INDEX(TIMESTAMP(6), DATE '2016-10-01', HOURS(2));
This statement lists the table definition for ts_timebucketonly_nonseq:
SHOW TABLE ts_timebucketonly_nonseq;
The SHOW TABLE output includes the two generated columns, TD_TIMEBUCKET and TD_TIMECODE, in addition to default values for the table creation options that were not specified.
CREATE SET TABLE ts_timebucketonly_nonseq, NO FALLBACK, NO BEFORE JOURNAL, NO AFTER JOURNAL, CHECKSUM = DEFAULT, DEFAULT MERGEBLOCKRATIO, MAP = TD_MAP1 ( TD_TIMEBUCKET BIGINT NOT NULL GENERATED SYSTEM TIMECOLUMN, TD_TIMECODE TIMESTAMP(6) NOT NULL GENERATED TIMECOLUMN, i INTEGER, j INTEGER, k INTEGER) PRIMARY TIME INDEX (TIMESTAMP(6), DATE '2016-10-01', HOURS(2), NONSEQUENCED);