XML Format - Analytics Database - Teradata Vantage

SQL Data Definition Language Syntax and Examples

Deployment
VantageCloud
VantageCore
Edition
Enterprise
IntelliFlex
VMware
Product
Analytics Database
Teradata Vantage
Release Number
17.20
Published
June 2022
Language
English (United States)
Last Update
2024-10-04
dita:mapPath
jco1628111346878.ditamap
dita:ditavalPath
qkf1628213546010.ditaval
dita:id
mdr1472255012272
lifecycle
latest
Product Category
Teradata Vantage™
SHOW IN XML TABLE riverflow_csv;
*** XML of DDL statement returned.
*** Total elapsed time was 1 second.
 
---------------------------------------------------------------------------------------------------------
<?xml version="1.0" encoding="UTF-16" standalone="no" ?><TeradataDBObjectSet version="1.0" xmlns="http://schemas.teradata.com/dbobject" xmlns:xsi="htt
p://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://schemas.teradata.com/dbobject http://schemas.teradata.com/dbobject/DBObject.xsd"><
Table authName="MyAuthObj" authType="GENERAL" baseClass="Table" dbName="NU" fallback="true" foreigntable="true" kind="Multiset" map="TD_MAP1" map_kind=
"contiguous" name="riverflow_csv" objId="2:52890" objVer="1"><ColumnList><Column name="Location" nullable="true" order="1"><DataType><Char casespecif
ic="true" charset="UNICODE" length="2048" uppercase="false" varying="true"/></DataType></Column><Column name="GageHeight2" nullable="true" order="2">
<DataType><Decimal precision="3" scale="2"/></DataType></Column><Column name="Flow" nullable="true" order="3"><DataType><Decimal precision="3" scale=
"2"/></DataType></Column><Column name="site_no" nullable="true" order="4"><DataType><Integer/></DataType></Column><Column format="Y4-MM-DDBHH:MI" nam
e="datetime" nullable="true" order="5"><DataType><TimeStamp fractionalSecondsPrecision="0"/></DataType></Column><Column name="Precipitation" nullable
="true" order="6"><DataType><Decimal precision="3" scale="2"/></DataType></Column><Column name="GageHeight" nullable="true" order="7"><DataType><Deci
mal precision="3" scale="2"/></DataType></Column></ColumnList><UsingClauseList><Clause name="LOCATION" value="/s3/YOUR-BUCKET.s3.amazonaws.com/CSV
DATA"/><Clause name="MANIFEST" value="FALSE"/><Clause name="PATHPATTERN" value="$var1/$site_no/$var3/$var4/$var5"/><Clause name="ROWFORMAT" value="{&
quot;field_delimiter&quot;:&quot;,&quot;,&quot;record_delimiter&quot;:&quot;\n&quot;,&quot;character_set&quot;:&quot;LATIN&quot;}"/><Clause name="STO
REDAS" value="TEXTFILE"/><Clause name="HEADER" value="TRUE"/><Clause name="STRIP_EXTERIOR_SPACES" value="FALSE"/><Clause name="STRIP_ENCLOSING_CHAR"
value="NONE"/></UsingClauseList><Indexes><NoPrimaryIndex/></Indexes><SQLText><![CDATA[CREATE MULTISET FOREIGN TABLE riverflow_csv ,FALLBACK ,
     EXTERNAL SECURITY MyAuthObj ,
     MAP = TD_MAP1
     (
      Location VARCHAR(2048) CHARACTER SET UNICODE CASESPECIFIC,
      GageHeight2 DECIMAL(3,2),
      Flow DECIMAL(3,2),
      site_no INTEGER,
      datetime TIMESTAMP(0) FORMAT 'Y4-MM-DDBHH:MI',
      Precipitation DECIMAL(3,2),
      GageHeight DECIMAL(3,2))
USING
(
      LOCATION  ('/s3/YOUR-BUCKET.s3.amazonaws.com/CSVDATA')
      MANIFEST  ('FALSE')
      PATHPATTERN  ('$var1/$site_no/$var3/$var4/$var5')
      ROWFORMAT  ('{"field_delimiter":",","record_delimiter":"\n","character_set":"LATIN"}')
      STOREDAS  ('TEXTFILE')
      HEADER  ('TRUE')
      STRIP_EXTERIOR_SPACES  ('FALSE')
      STRIP_ENCLOSING_CHAR  ('NONE')
)
NO PRIMARY INDEX ]]></SQLText></Table><Environment><Server dbRelease="17.10.01.01" dbVersion="17.10c.00.198dr196079" hostName="TDLabs"/><User userI
d="00000604" userName="JOE"/><Session charset="ASCII" dateTime="2021-06-09T15:03:48"/></Environment></TeradataDBObjectSet>