What are the challenges you face when working across database platforms? Take the survey
Options

EXTERNAL Table, Data_Source, etc.

Hi guys,

The syntax "External Table", "External Data_Source", etc. is not considered by the formatting template, instead SQL prompt even convert it to a sigle row.


CREATE EXTERNAL DATA SOURCE mydatasource
WITH (
    TYPE = HADOOP,
    LOCATION = 'hdfs://xxx.xxx.xxx.xxx:8020'
)

CREATE EXTERNAL FILE FORMAT myfileformat
WITH (
    FORMAT_TYPE = DELIMITEDTEXT,
    FORMAT_OPTIONS (FIELD_TERMINATOR ='|')
);

CREATE EXTERNAL TABLE ClickStream (
    url varchar(50),
    event_date date,
    user_IP varchar(50)
)
WITH (
        LOCATION='/webdata/employee.tbl',
        DATA_SOURCE = mydatasource,
        FILE_FORMAT = myfileformat
    )
;

Thank you for fixing it!

Torsten
MVP

Answers

Sign In or Register to comment.