当我尝试创建如下表格时
CREATE SET TABLE pp_scratch.HADOOP_FPTI_DASHBOARD ,NO FALLBACK ,
NO BEFORE JOURNAL,
NO AFTER JOURNAL,
CHECKSUM = DEFAULT,
DEFAULT MERGEBLOCKRATIO
(
id decimal(10,0) NOT NULL GENERATED ALWAYS AS IDENTITY (START WITH 1, INCREMENT BY 1, MAXVALUE 999999999999, NO CYCLE)
job_status VARCHAR(32) CHARACTER SET LATIN NOT CASESPECIFIC NOT NULL,
current_processing_hr VARCHAR(32) CHARACTER SET LATIN NOT CASESPECIFIC NOT NULL,
no_of_files_moved VARCHAR(10) CHARACTER SET LATIN NOT CASESPECIFIC NOT NULL)
PRIMARY INDEX id;
你能帮忙解决出错的问题。CREATE TABLE失败。 [3707]语法错误,预期类似于 名称或Unicode分隔标识符或之间的'CYCLE'关键字 整数和','。
提前致谢
答案 0 :(得分:2)
Identity
选项之间没有逗号:
CREATE SET TABLE pp_scratch.HADOOP_FPTI_DASHBOARD ,NO FALLBACK ,
NO BEFORE JOURNAL,
NO AFTER JOURNAL,
CHECKSUM = DEFAULT,
DEFAULT MERGEBLOCKRATIO
(
id decimal(10,0) NOT NULL
GENERATED ALWAYS AS IDENTITY (START WITH 1
INCREMENT BY 1
MAXVALUE 999999999999
NO CYCLE),
job_status VARCHAR(32) CHARACTER SET LATIN NOT CASESPECIFIC NOT NULL,
current_processing_hr VARCHAR(32) CHARACTER SET LATIN NOT CASESPECIFIC NOT NULL,
no_of_files_moved VARCHAR(10) CHARACTER SET LATIN NOT CASESPECIFIC NOT NULL)
PRIMARY INDEX id;
答案 1 :(得分:0)
定义id
的行最后缺少逗号:
id decimal(10,0) NOT NULL
GENERATED ALWAYS AS IDENTITY (START WITH 1, INCREMENT BY 1, MAXVALUE 999999999999, NO CYCLE),
-----------------------------------------------------------------------------------------------------^