16.20 - Examples: INSERT-SELECT and PTI Tables - Teradata Database - Teradata Vantage NewSQL Engine

Teradata Vantageā„¢ Time Series Tables and Operations

Product
Teradata Database
Teradata Vantage NewSQL Engine
Release Number
16.20
Published
March 2019
Content Type
Programming Reference
Publication ID
B035-1208-162K
Language
English (United States)
Last Update
2019-05-02

Table and Data Definition for INSERT-SELECT Examples

Below are the PTI table definitions for the INSERT-SELECT examples.

CREATE TABLE ocean_buoy(buoyid INT,temperature INT)
PRIMARY TIME INDEX(TIMESTAMP(6), DATE '2012-01-01', HOURS(1), COLUMNS(buoyid));
CREATE TABLE ocean_buoy_1(buoyid INT,temperature INT)
PRIMARY TIME INDEX(TIMESTAMP(6), DATE '2012-01-01', HOURS(1), COLUMNS(buoyid));
CREATE TABLE ocean_buoy_2(buoyid INT,temperature INT)
PRIMARY TIME INDEX(TIMESTAMP(6), DATE '2012-01-01', COLUMNS(buoyid));

Following are the non-PTI table definitions for the INSERT-SELECT examples.

CREATE TABLE normal_table (timecode TIMESTAMP(2), buoyid INT, temperature INT);
CREATE TABLE normal_table2 (my_timebucket BIGINT NOT NULL, my_timecode TIMESTAMP(2), buoyid INT, temperature INT);