diff --git a/include/common/ttokendef.h b/include/common/ttokendef.h index da34ca62536872599cb0e91db172d30a83e73346..51dd645a3099fe7de290a42f69649add248adca2 100644 --- a/include/common/ttokendef.h +++ b/include/common/ttokendef.h @@ -82,102 +82,103 @@ #define TK_SINGLE_STABLE 64 #define TK_STREAM_MODE 65 #define TK_RETENTIONS 66 -#define TK_FILE_FACTOR 67 -#define TK_NK_FLOAT 68 -#define TK_TABLE 69 -#define TK_NK_LP 70 -#define TK_NK_RP 71 -#define TK_STABLE 72 -#define TK_ADD 73 -#define TK_COLUMN 74 -#define TK_MODIFY 75 -#define TK_RENAME 76 -#define TK_TAG 77 -#define TK_SET 78 -#define TK_NK_EQ 79 -#define TK_USING 80 -#define TK_TAGS 81 -#define TK_NK_DOT 82 -#define TK_NK_COMMA 83 -#define TK_COMMENT 84 -#define TK_BOOL 85 -#define TK_TINYINT 86 -#define TK_SMALLINT 87 -#define TK_INT 88 -#define TK_INTEGER 89 -#define TK_BIGINT 90 -#define TK_FLOAT 91 -#define TK_DOUBLE 92 -#define TK_BINARY 93 -#define TK_TIMESTAMP 94 -#define TK_NCHAR 95 -#define TK_UNSIGNED 96 -#define TK_JSON 97 -#define TK_VARCHAR 98 -#define TK_MEDIUMBLOB 99 -#define TK_BLOB 100 -#define TK_VARBINARY 101 -#define TK_DECIMAL 102 -#define TK_SMA 103 -#define TK_ROLLUP 104 -#define TK_SHOW 105 -#define TK_DATABASES 106 -#define TK_TABLES 107 -#define TK_STABLES 108 -#define TK_MNODES 109 -#define TK_MODULES 110 -#define TK_QNODES 111 -#define TK_FUNCTIONS 112 -#define TK_INDEXES 113 -#define TK_FROM 114 -#define TK_LIKE 115 -#define TK_INDEX 116 -#define TK_FULLTEXT 117 -#define TK_FUNCTION 118 -#define TK_INTERVAL 119 -#define TK_TOPIC 120 -#define TK_AS 121 -#define TK_NK_BOOL 122 -#define TK_NK_VARIABLE 123 -#define TK_BETWEEN 124 -#define TK_IS 125 -#define TK_NULL 126 -#define TK_NK_LT 127 -#define TK_NK_GT 128 -#define TK_NK_LE 129 -#define TK_NK_GE 130 -#define TK_NK_NE 131 -#define TK_MATCH 132 -#define TK_NMATCH 133 -#define TK_IN 134 -#define TK_JOIN 135 -#define TK_INNER 136 -#define TK_SELECT 137 -#define TK_DISTINCT 138 -#define TK_WHERE 139 -#define TK_PARTITION 140 -#define TK_BY 141 -#define TK_SESSION 142 -#define TK_STATE_WINDOW 143 -#define TK_SLIDING 144 -#define TK_FILL 145 -#define TK_VALUE 146 -#define TK_NONE 147 -#define TK_PREV 148 -#define TK_LINEAR 149 -#define TK_NEXT 150 -#define TK_GROUP 151 -#define TK_HAVING 152 -#define TK_ORDER 153 -#define TK_SLIMIT 154 -#define TK_SOFFSET 155 -#define TK_LIMIT 156 -#define TK_OFFSET 157 -#define TK_ASC 158 -#define TK_DESC 159 -#define TK_NULLS 160 -#define TK_FIRST 161 -#define TK_LAST 162 +#define TK_TABLE 67 +#define TK_NK_LP 68 +#define TK_NK_RP 69 +#define TK_STABLE 70 +#define TK_ADD 71 +#define TK_COLUMN 72 +#define TK_MODIFY 73 +#define TK_RENAME 74 +#define TK_TAG 75 +#define TK_SET 76 +#define TK_NK_EQ 77 +#define TK_USING 78 +#define TK_TAGS 79 +#define TK_NK_DOT 80 +#define TK_NK_COMMA 81 +#define TK_COMMENT 82 +#define TK_BOOL 83 +#define TK_TINYINT 84 +#define TK_SMALLINT 85 +#define TK_INT 86 +#define TK_INTEGER 87 +#define TK_BIGINT 88 +#define TK_FLOAT 89 +#define TK_DOUBLE 90 +#define TK_BINARY 91 +#define TK_TIMESTAMP 92 +#define TK_NCHAR 93 +#define TK_UNSIGNED 94 +#define TK_JSON 95 +#define TK_VARCHAR 96 +#define TK_MEDIUMBLOB 97 +#define TK_BLOB 98 +#define TK_VARBINARY 99 +#define TK_DECIMAL 100 +#define TK_SMA 101 +#define TK_ROLLUP 102 +#define TK_FILE_FACTOR 103 +#define TK_NK_FLOAT 104 +#define TK_DELAY 105 +#define TK_SHOW 106 +#define TK_DATABASES 107 +#define TK_TABLES 108 +#define TK_STABLES 109 +#define TK_MNODES 110 +#define TK_MODULES 111 +#define TK_QNODES 112 +#define TK_FUNCTIONS 113 +#define TK_INDEXES 114 +#define TK_FROM 115 +#define TK_LIKE 116 +#define TK_INDEX 117 +#define TK_FULLTEXT 118 +#define TK_FUNCTION 119 +#define TK_INTERVAL 120 +#define TK_TOPIC 121 +#define TK_AS 122 +#define TK_NK_BOOL 123 +#define TK_NK_VARIABLE 124 +#define TK_BETWEEN 125 +#define TK_IS 126 +#define TK_NULL 127 +#define TK_NK_LT 128 +#define TK_NK_GT 129 +#define TK_NK_LE 130 +#define TK_NK_GE 131 +#define TK_NK_NE 132 +#define TK_MATCH 133 +#define TK_NMATCH 134 +#define TK_IN 135 +#define TK_JOIN 136 +#define TK_INNER 137 +#define TK_SELECT 138 +#define TK_DISTINCT 139 +#define TK_WHERE 140 +#define TK_PARTITION 141 +#define TK_BY 142 +#define TK_SESSION 143 +#define TK_STATE_WINDOW 144 +#define TK_SLIDING 145 +#define TK_FILL 146 +#define TK_VALUE 147 +#define TK_NONE 148 +#define TK_PREV 149 +#define TK_LINEAR 150 +#define TK_NEXT 151 +#define TK_GROUP 152 +#define TK_HAVING 153 +#define TK_ORDER 154 +#define TK_SLIMIT 155 +#define TK_SOFFSET 156 +#define TK_LIMIT 157 +#define TK_OFFSET 158 +#define TK_ASC 159 +#define TK_DESC 160 +#define TK_NULLS 161 +#define TK_FIRST 162 +#define TK_LAST 163 #define TK_NK_SPACE 300 #define TK_NK_COMMENT 301 diff --git a/include/libs/nodes/cmdnodes.h b/include/libs/nodes/cmdnodes.h index 48a3a9bda8b200cab6c46520be64b017fcd98c00..a03c496b4f71079992954a7919e30d737df7bdce 100644 --- a/include/libs/nodes/cmdnodes.h +++ b/include/libs/nodes/cmdnodes.h @@ -41,6 +41,7 @@ typedef struct SDatabaseOptions { int32_t numOfVgroups; int8_t singleStable; int8_t streamMode; + SNodeList* pRetentions; } SDatabaseOptions; typedef struct SCreateDatabaseStmt { @@ -73,6 +74,9 @@ typedef struct STableOptions { int32_t ttl; char comments[TSDB_STB_COMMENT_LEN]; SNodeList* pSma; + SNodeList* pFuncs; + float filesFactor; + int32_t delay; } STableOptions; typedef struct SColumnDefNode { diff --git a/include/util/tdef.h b/include/util/tdef.h index 6c5208ec00d4a7401e9dcbbc2e262b4db02f5d35..9ecb7784ed8691f2b483cbdfabaf7d5ed4ae3c4d 100644 --- a/include/util/tdef.h +++ b/include/util/tdef.h @@ -369,6 +369,14 @@ typedef enum ELogicConditionType { #define TSDB_MAX_DB_CACHE_LAST_ROW 3 #define TSDB_DEFAULT_CACHE_LAST_ROW 0 +#define TSDB_MIN_DB_FILE_FACTOR 0 +#define TSDB_MAX_DB_FILE_FACTOR 1 +#define TSDB_DEFAULT_DB_FILE_FACTOR 0.1 + +#define TSDB_MIN_DB_DELAY 1 +#define TSDB_MAX_DB_DELAY 10 +#define TSDB_DEFAULT_DB_DELAY 2 + #define TSDB_MAX_JOIN_TABLE_NUM 10 #define TSDB_MAX_UNION_CLAUSE 5 diff --git a/source/libs/parser/inc/parAst.h b/source/libs/parser/inc/parAst.h index 358edcb279f0ff7f7f328e7c86b6c5186a412885..0fe5df183d704e64e754021157318a6f1882bab5 100644 --- a/source/libs/parser/inc/parAst.h +++ b/source/libs/parser/inc/parAst.h @@ -53,7 +53,6 @@ typedef enum EDatabaseOptionType { DB_OPTION_SINGLE_STABLE, DB_OPTION_STREAM_MODE, DB_OPTION_RETENTIONS, - DB_OPTION_FILE_FACTOR, DB_OPTION_MAX } EDatabaseOptionType; @@ -63,6 +62,8 @@ typedef enum ETableOptionType { TABLE_OPTION_TTL, TABLE_OPTION_COMMENT, TABLE_OPTION_SMA, + TABLE_OPTION_FILE_FACTOR, + TABLE_OPTION_DELAY, TABLE_OPTION_MAX } ETableOptionType; diff --git a/source/libs/parser/inc/sql.y b/source/libs/parser/inc/sql.y index 529fbb55c8e65521d8d3c20d26c963628750009f..8f07d66a628730a432e267839035532991c442da 100644 --- a/source/libs/parser/inc/sql.y +++ b/source/libs/parser/inc/sql.y @@ -146,7 +146,6 @@ db_options(A) ::= db_options(B) VGROUPS NK_INTEGER(C). db_options(A) ::= db_options(B) SINGLE_STABLE NK_INTEGER(C). { A = setDatabaseOption(pCxt, B, DB_OPTION_SINGLE_STABLE, &C); } db_options(A) ::= db_options(B) STREAM_MODE NK_INTEGER(C). { A = setDatabaseOption(pCxt, B, DB_OPTION_STREAM_MODE, &C); } db_options(A) ::= db_options(B) RETENTIONS NK_STRING(C). { A = setDatabaseOption(pCxt, B, DB_OPTION_RETENTIONS, &C); } -db_options(A) ::= db_options(B) FILE_FACTOR NK_FLOAT(C). { A = setDatabaseOption(pCxt, B, DB_OPTION_FILE_FACTOR, &C); } alter_db_options(A) ::= alter_db_option(B). { A = createDefaultAlterDatabaseOptions(pCxt); A = setDatabaseOption(pCxt, A, B.type, &B.val); } alter_db_options(A) ::= alter_db_options(B) alter_db_option(C). { A = setDatabaseOption(pCxt, B, C.type, &C.val); } @@ -263,6 +262,8 @@ table_options(A) ::= table_options(B) KEEP NK_INTEGER(C). table_options(A) ::= table_options(B) TTL NK_INTEGER(C). { A = setTableOption(pCxt, B, TABLE_OPTION_TTL, &C); } table_options(A) ::= table_options(B) SMA NK_LP col_name_list(C) NK_RP. { A = setTableSmaOption(pCxt, B, C); } table_options(A) ::= table_options(B) ROLLUP NK_LP func_name_list(C) NK_RP. { A = setTableRollupOption(pCxt, B, C); } +table_options(A) ::= table_options(B) FILE_FACTOR NK_FLOAT(C). { A = setTableOption(pCxt, B, TABLE_OPTION_FILE_FACTOR, &C); } +table_options(A) ::= table_options(B) DELAY NK_INTEGER(C). { A = setTableOption(pCxt, B, TABLE_OPTION_DELAY, &C); } alter_table_options(A) ::= alter_table_option(B). { A = createDefaultAlterTableOptions(pCxt); A = setTableOption(pCxt, A, B.type, &B.val); } alter_table_options(A) ::= alter_table_options(B) alter_table_option(C). { A = setTableOption(pCxt, B, C.type, &C.val); } diff --git a/source/libs/parser/src/parAstCreater.c b/source/libs/parser/src/parAstCreater.c index a958a748e29090da0a2f7f9a982d298dff659112..c5a632482c19cac095423c189286b6ccf1fc1236 100644 --- a/source/libs/parser/src/parAstCreater.c +++ b/source/libs/parser/src/parAstCreater.c @@ -248,12 +248,37 @@ static SDatabaseOptions* setDbStreamMode(SAstCreateContext* pCxt, SDatabaseOptio } static SDatabaseOptions* setDbRetentions(SAstCreateContext* pCxt, SDatabaseOptions* pOptions, const SToken* pVal) { - // todo - return pOptions; -} + pOptions->pRetentions = nodesMakeList(); + if (NULL == pOptions->pRetentions) { + pCxt->valid = false; + snprintf(pCxt->pQueryCxt->pMsg, pCxt->pQueryCxt->msgLen, "Out of memory"); + return pOptions; + } + + char val[20] = {0}; + int32_t len = trimString(pVal->z, pVal->n, val, sizeof(val)); + char* pStart = val; + char* pEnd = val + len; + int32_t sepOrder = 1; + while (1) { + char* pPos = strchr(pStart, (0 == sepOrder % 2) ? ',' : ':'); + SToken t = { .type = TK_NK_VARIABLE, .z = pStart, .n = (NULL == pPos ? pEnd - pStart : pPos - pStart)}; + if (TSDB_CODE_SUCCESS != nodesListStrictAppend(pOptions->pRetentions, createDurationValueNode(pCxt, &t))) { + pCxt->valid = false; + snprintf(pCxt->pQueryCxt->pMsg, pCxt->pQueryCxt->msgLen, "Out of memory"); + return pOptions; + } + if (NULL == pPos) { + break; + } + pStart = pPos + 1; + } + + if (LIST_LENGTH(pOptions->pRetentions) % 2 != 0) { + snprintf(pCxt->pQueryCxt->pMsg, pCxt->pQueryCxt->msgLen, "invalid db option retentions: %s", val); + pCxt->valid = false; + } -static SDatabaseOptions* setDbFileFactor(SAstCreateContext* pCxt, SDatabaseOptions* pOptions, const SToken* pVal) { - // todo return pOptions; } @@ -276,7 +301,6 @@ static void initSetDatabaseOptionFp() { setDbOptionFuncs[DB_OPTION_SINGLE_STABLE] = setDbSingleStable; setDbOptionFuncs[DB_OPTION_STREAM_MODE] = setDbStreamMode; setDbOptionFuncs[DB_OPTION_RETENTIONS] = setDbRetentions; - setDbOptionFuncs[DB_OPTION_FILE_FACTOR] = setDbFileFactor; } static STableOptions* setTableKeep(SAstCreateContext* pCxt, STableOptions* pOptions, const SToken* pVal) { @@ -314,10 +338,36 @@ static STableOptions* setTableComment(SAstCreateContext* pCxt, STableOptions* pO return pOptions; } +static STableOptions* setTableFileFactor(SAstCreateContext* pCxt, STableOptions* pOptions, const SToken* pVal) { + double val = strtod(pVal->z, NULL); + if (val < TSDB_MIN_DB_FILE_FACTOR || val > TSDB_MAX_DB_FILE_FACTOR) { + snprintf(pCxt->pQueryCxt->pMsg, pCxt->pQueryCxt->msgLen, + "invalid table option file_factor: %f valid range: [%d, %d]", val, TSDB_MIN_DB_FILE_FACTOR, TSDB_MAX_DB_FILE_FACTOR); + pCxt->valid = false; + return pOptions; + } + pOptions->filesFactor = val; + return pOptions; +} + +static STableOptions* setTableDelay(SAstCreateContext* pCxt, STableOptions* pOptions, const SToken* pVal) { + int64_t val = strtol(pVal->z, NULL, 10); + if (val < TSDB_MIN_DB_DELAY || val > TSDB_MAX_DB_DELAY) { + snprintf(pCxt->pQueryCxt->pMsg, pCxt->pQueryCxt->msgLen, + "invalid table option delay: %"PRId64" valid range: [%d, %d]", val, TSDB_MIN_DB_DELAY, TSDB_MAX_DB_DELAY); + pCxt->valid = false; + return pOptions; + } + pOptions->delay = val; + return pOptions; +} + static void initSetTableOptionFp() { setTableOptionFuncs[TABLE_OPTION_KEEP] = setTableKeep; setTableOptionFuncs[TABLE_OPTION_TTL] = setTableTtl; setTableOptionFuncs[TABLE_OPTION_COMMENT] = setTableComment; + setTableOptionFuncs[TABLE_OPTION_FILE_FACTOR] = setTableFileFactor; + setTableOptionFuncs[TABLE_OPTION_DELAY] = setTableDelay; } void initAstCreateContext(SParseContext* pParseCxt, SAstCreateContext* pCxt) { @@ -906,6 +956,8 @@ SNode* createDefaultTableOptions(SAstCreateContext* pCxt) { CHECK_OUT_OF_MEM(pOptions); pOptions->keep = TSDB_DEFAULT_KEEP; pOptions->ttl = TSDB_DEFAULT_DB_TTL_OPTION; + pOptions->filesFactor = TSDB_DEFAULT_DB_FILE_FACTOR; + pOptions->delay = TSDB_DEFAULT_DB_DELAY; return (SNode*)pOptions; } @@ -914,6 +966,8 @@ SNode* createDefaultAlterTableOptions(SAstCreateContext* pCxt) { CHECK_OUT_OF_MEM(pOptions); pOptions->keep = -1; pOptions->ttl = -1; + pOptions->filesFactor = -1; + pOptions->delay = -1; return (SNode*)pOptions; } @@ -927,7 +981,12 @@ SNode* setTableSmaOption(SAstCreateContext* pCxt, SNode* pOptions, SNodeList* pS } SNode* setTableRollupOption(SAstCreateContext* pCxt, SNode* pOptions, SNodeList* pFuncs) { - // todo + if (1 != LIST_LENGTH(pFuncs)) { + snprintf(pCxt->pQueryCxt->pMsg, pCxt->pQueryCxt->msgLen, "invalid table option rollup: only one function is allowed"); + pCxt->valid = false; + return pOptions; + } + ((STableOptions*)pOptions)->pFuncs = pFuncs; return pOptions; } diff --git a/source/libs/parser/src/parTokenizer.c b/source/libs/parser/src/parTokenizer.c index 79651cd325fe6c9582ab875a6bc713689c8699cd..766e606823692e7df56c4901b7db6392af9fbac5 100644 --- a/source/libs/parser/src/parTokenizer.c +++ b/source/libs/parser/src/parTokenizer.c @@ -48,6 +48,7 @@ static SKeyword keywordTable[] = { {"DATABASE", TK_DATABASE}, {"DATABASES", TK_DATABASES}, {"DAYS", TK_DAYS}, + {"DELAY", TK_DELAY}, {"DESC", TK_DESC}, {"DISTINCT", TK_DISTINCT}, {"DNODE", TK_DNODE}, @@ -55,7 +56,7 @@ static SKeyword keywordTable[] = { {"DOUBLE", TK_DOUBLE}, {"DROP", TK_DROP}, {"EXISTS", TK_EXISTS}, - // {"FILE", TK_FILE}, + {"FILE_FACTOR", TK_FILE_FACTOR}, {"FILL", TK_FILL}, {"FLOAT", TK_FLOAT}, {"FROM", TK_FROM}, @@ -107,6 +108,8 @@ static SKeyword keywordTable[] = { {"QNODES", TK_QNODES}, {"QUORUM", TK_QUORUM}, {"REPLICA", TK_REPLICA}, + {"RETENTIONS", TK_RETENTIONS}, + {"ROLLUP", TK_ROLLUP}, {"SELECT", TK_SELECT}, {"SESSION", TK_SESSION}, {"SHOW", TK_SHOW}, diff --git a/source/libs/parser/src/parTranslater.c b/source/libs/parser/src/parTranslater.c index 60ee8be76d5e382ce2383f0fd119d2620cf6891c..6771eafa0905d49e847156d0d5db560ab0e345de 100644 --- a/source/libs/parser/src/parTranslater.c +++ b/source/libs/parser/src/parTranslater.c @@ -920,7 +920,35 @@ static int32_t translateSelect(STranslateContext* pCxt, SSelectStmt* pSelect) { return code; } -static void buildCreateDbReq(STranslateContext* pCxt, SCreateDatabaseStmt* pStmt, SCreateDbReq* pReq) { +static int32_t buildCreateDbRetentions(const SNodeList* pRetentions, SCreateDbReq* pReq) { + if (NULL != pRetentions) { + pReq->pRetensions = taosArrayInit(LIST_LENGTH(pRetentions) / 2, sizeof(SRetention)); + if (NULL == pReq->pRetensions) { + return TSDB_CODE_OUT_OF_MEMORY; + } + SValueNode* pFreq = NULL; + SValueNode* pKeep = NULL; + SNode* pNode = NULL; + int32_t index = 0; + FOREACH(pNode, pRetentions) { + if (0 == index % 2) { + pFreq = (SValueNode*)pNode; + } else { + pKeep = (SValueNode*)pNode; + SRetention retention = { + .freq = pFreq->datum.i, + .freqUnit = pFreq->unit, + .keep = pKeep->datum.i, + .keepUnit = pKeep->unit + }; + taosArrayPush(pReq->pRetensions, &retention); + } + } + } + return TSDB_CODE_SUCCESS; +} + +static int32_t buildCreateDbReq(STranslateContext* pCxt, SCreateDatabaseStmt* pStmt, SCreateDbReq* pReq) { SName name = {0}; tNameSetDbName(&name, pCxt->pParseCxt->acctId, pStmt->dbName, strlen(pStmt->dbName)); tNameGetFullDbName(&name, pReq->db); @@ -944,27 +972,45 @@ static void buildCreateDbReq(STranslateContext* pCxt, SCreateDatabaseStmt* pStmt pReq->cacheLastRow = pStmt->pOptions->cachelast; pReq->ignoreExist = pStmt->ignoreExists; pReq->streamMode = pStmt->pOptions->streamMode; - return; + return buildCreateDbRetentions(pStmt->pOptions->pRetentions, pReq); +} + +static int32_t checkCreateDatabase(STranslateContext* pCxt, SCreateDatabaseStmt* pStmt) { + if (NULL != pStmt->pOptions->pRetentions) { + SNode* pNode = NULL; + FOREACH(pNode, pStmt->pOptions->pRetentions) { + if (DEAL_RES_ERROR == translateValue(pCxt, (SValueNode*)pNode)) { + return pCxt->errCode; + } + } + } + return TSDB_CODE_SUCCESS; } static int32_t translateCreateDatabase(STranslateContext* pCxt, SCreateDatabaseStmt* pStmt) { SCreateDbReq createReq = {0}; - buildCreateDbReq(pCxt, pStmt, &createReq); - pCxt->pCmdMsg = taosMemoryMalloc(sizeof(SCmdMsgInfo)); - if (NULL == pCxt->pCmdMsg) { - return TSDB_CODE_OUT_OF_MEMORY; + int32_t code = checkCreateDatabase(pCxt, pStmt); + if (TSDB_CODE_SUCCESS == code) { + code = buildCreateDbReq(pCxt, pStmt, &createReq); } - pCxt->pCmdMsg->epSet = pCxt->pParseCxt->mgmtEpSet; - pCxt->pCmdMsg->msgType = TDMT_MND_CREATE_DB; - pCxt->pCmdMsg->msgLen = tSerializeSCreateDbReq(NULL, 0, &createReq); - pCxt->pCmdMsg->pMsg = taosMemoryMalloc(pCxt->pCmdMsg->msgLen); - if (NULL == pCxt->pCmdMsg->pMsg) { - return TSDB_CODE_OUT_OF_MEMORY; + + if (TSDB_CODE_SUCCESS == code) { + pCxt->pCmdMsg = taosMemoryMalloc(sizeof(SCmdMsgInfo)); + if (NULL == pCxt->pCmdMsg) { + return TSDB_CODE_OUT_OF_MEMORY; + } + pCxt->pCmdMsg->epSet = pCxt->pParseCxt->mgmtEpSet; + pCxt->pCmdMsg->msgType = TDMT_MND_CREATE_DB; + pCxt->pCmdMsg->msgLen = tSerializeSCreateDbReq(NULL, 0, &createReq); + pCxt->pCmdMsg->pMsg = taosMemoryMalloc(pCxt->pCmdMsg->msgLen); + if (NULL == pCxt->pCmdMsg->pMsg) { + return TSDB_CODE_OUT_OF_MEMORY; + } + tSerializeSCreateDbReq(pCxt->pCmdMsg->pMsg, pCxt->pCmdMsg->msgLen, &createReq); } - tSerializeSCreateDbReq(pCxt->pCmdMsg->pMsg, pCxt->pCmdMsg->msgLen, &createReq); - return TSDB_CODE_SUCCESS; + return code; } static int32_t translateDropDatabase(STranslateContext* pCxt, SDropDatabaseStmt* pStmt) { @@ -1035,7 +1081,7 @@ static int32_t calcTypeBytes(SDataType dt) { } } -static int32_t columnNodeToField(SNodeList* pList, SArray** pArray) { +static int32_t columnDefNodeToField(SNodeList* pList, SArray** pArray) { *pArray = taosArrayInit(LIST_LENGTH(pList), sizeof(SField)); SNode* pNode; FOREACH(pNode, pList) { @@ -1047,13 +1093,77 @@ static int32_t columnNodeToField(SNodeList* pList, SArray** pArray) { return TSDB_CODE_SUCCESS; } +static int32_t columnNodeToField(SNodeList* pList, SArray** pArray) { + if (NULL == pList) { + return TSDB_CODE_SUCCESS; + } + + *pArray = taosArrayInit(LIST_LENGTH(pList), sizeof(SField)); + SNode* pNode; + FOREACH(pNode, pList) { + SColumnNode* pCol = (SColumnNode*)pNode; + SField field = { .type = pCol->node.resType.type, .bytes = calcTypeBytes(pCol->node.resType) }; + strcpy(field.name, pCol->colName); + taosArrayPush(*pArray, &field); + } + return TSDB_CODE_SUCCESS; +} + +static const SColumnDefNode* findColDef(const SNodeList* pCols, const SColumnNode* pCol) { + SNode* pColDef = NULL; + FOREACH(pColDef, pCols) { + if (0 == strcmp(pCol->colName, ((SColumnDefNode*)pColDef)->colName)) { + return (SColumnDefNode*)pColDef; + } + } + return NULL; +} + +static int32_t checkCreateTable(STranslateContext* pCxt, SCreateTableStmt* pStmt) { + if (NULL != pStmt->pOptions->pSma) { + SNode* pNode = NULL; + FOREACH(pNode, pStmt->pOptions->pSma) { + SColumnNode* pSmaCol = (SColumnNode*)pNode; + const SColumnDefNode* pColDef = findColDef(pStmt->pCols, pSmaCol); + if (NULL == pColDef) { + return generateSyntaxErrMsg(&pCxt->msgBuf, TSDB_CODE_PAR_INVALID_COLUMN, pSmaCol->colName); + } + pSmaCol->node.resType = pColDef->dataType; + } + } + if (NULL != pStmt->pOptions->pFuncs) { + SFunctionNode* pFunc = nodesListGetNode(pStmt->pOptions->pFuncs, 0); + if (TSDB_CODE_SUCCESS != fmGetFuncInfo(pFunc->functionName, &pFunc->funcId, &pFunc->funcType)) { + return generateDealNodeErrMsg(pCxt, TSDB_CODE_PAR_INVALID_FUNTION, pFunc->functionName); + } + } + return TSDB_CODE_SUCCESS; +} + +static int32_t getAggregationMethod(SNodeList* pFuncs) { + if (NULL == pFuncs) { + return -1; + } + return ((SFunctionNode*)nodesListGetNode(pFuncs, 0))->funcId; +} + static int32_t translateCreateSuperTable(STranslateContext* pCxt, SCreateTableStmt* pStmt) { + int32_t code = checkCreateTable(pCxt, pStmt); + if (TSDB_CODE_SUCCESS != code) { + return code; + } + SMCreateStbReq createReq = {0}; createReq.igExists = pStmt->ignoreExists; - columnNodeToField(pStmt->pCols, &createReq.pColumns); - columnNodeToField(pStmt->pTags, &createReq.pTags); + createReq.aggregationMethod = getAggregationMethod(pStmt->pOptions->pFuncs); + createReq.xFilesFactor = pStmt->pOptions->filesFactor; + createReq.delay = pStmt->pOptions->delay; + columnDefNodeToField(pStmt->pCols, &createReq.pColumns); + columnDefNodeToField(pStmt->pTags, &createReq.pTags); + columnNodeToField(pStmt->pOptions->pSma, &createReq.pSmas); createReq.numOfColumns = LIST_LENGTH(pStmt->pCols); createReq.numOfTags = LIST_LENGTH(pStmt->pTags); + createReq.numOfSmas = LIST_LENGTH(pStmt->pOptions->pSma); SName tableName = { .type = TSDB_TABLE_NAME_T, .acctId = pCxt->pParseCxt->acctId }; strcpy(tableName.dbname, pStmt->dbName); diff --git a/source/libs/parser/src/sql.c b/source/libs/parser/src/sql.c index 451587c8bf1f42481b3947a5c07b3576a5ed7a84..b64eaee628e66710d6a95a5025865705f5ee9dad 100644 --- a/source/libs/parser/src/sql.c +++ b/source/libs/parser/src/sql.c @@ -73,7 +73,7 @@ ** which is ParseTOKENTYPE. The entry in the union ** for terminal symbols is called "yy0". ** YYSTACKDEPTH is the maximum depth of the parser's stack. If -** zero the stack is dynamically sized using taosMemoryRealloc() +** zero the stack is dynamically sized using realloc() ** ParseARG_SDECL A static variable declaration for the %extra_argument ** ParseARG_PDECL A parameter declaration for the %extra_argument ** ParseARG_PARAM Code to pass %extra_argument as a subroutine parameter @@ -99,24 +99,24 @@ #endif /************* Begin control #defines *****************************************/ #define YYCODETYPE unsigned short int -#define YYNOCODE 258 +#define YYNOCODE 259 #define YYACTIONTYPE unsigned short int #define ParseTOKENTYPE SToken typedef union { int yyinit; ParseTOKENTYPE yy0; - ENullOrder yy73; - SNodeList* yy136; - SNode* yy140; - EJoinType yy144; - SToken yy149; - EOrder yy158; - int32_t yy160; - SAlterOption yy233; - SDataType yy256; - EFillMode yy306; - EOperatorType yy320; - bool yy497; + SAlterOption yy11; + ENullOrder yy151; + EJoinType yy162; + SToken yy183; + bool yy215; + EOperatorType yy366; + SNode* yy378; + int32_t yy396; + EOrder yy400; + SNodeList* yy404; + EFillMode yy466; + SDataType yy504; } YYMINORTYPE; #ifndef YYSTACKDEPTH #define YYSTACKDEPTH 100 @@ -131,17 +131,17 @@ typedef union { #define ParseCTX_PARAM #define ParseCTX_FETCH #define ParseCTX_STORE -#define YYNSTATE 430 -#define YYNRULE 337 -#define YYNTOKEN 163 -#define YY_MAX_SHIFT 429 -#define YY_MIN_SHIFTREDUCE 662 -#define YY_MAX_SHIFTREDUCE 998 -#define YY_ERROR_ACTION 999 -#define YY_ACCEPT_ACTION 1000 -#define YY_NO_ACTION 1001 -#define YY_MIN_REDUCE 1002 -#define YY_MAX_REDUCE 1338 +#define YYNSTATE 431 +#define YYNRULE 338 +#define YYNTOKEN 164 +#define YY_MAX_SHIFT 430 +#define YY_MIN_SHIFTREDUCE 664 +#define YY_MAX_SHIFTREDUCE 1001 +#define YY_ERROR_ACTION 1002 +#define YY_ACCEPT_ACTION 1003 +#define YY_NO_ACTION 1004 +#define YY_MIN_REDUCE 1005 +#define YY_MAX_REDUCE 1342 /************* End control #defines *******************************************/ #define YY_NLOOKAHEAD ((int)(sizeof(yy_lookahead)/sizeof(yy_lookahead[0]))) @@ -208,398 +208,393 @@ typedef union { ** yy_default[] Default action for each state. ** *********** Begin parsing tables **********************************************/ -#define YY_ACTTAB_COUNT (1263) +#define YY_ACTTAB_COUNT (1230) static const YYACTIONTYPE yy_action[] = { - /* 0 */ 1045, 1204, 225, 43, 24, 170, 362, 1200, 1206, 1095, - /* 10 */ 250, 269, 89, 31, 29, 27, 26, 25, 20, 1204, - /* 20 */ 1101, 27, 26, 25, 1084, 1200, 1205, 1106, 31, 29, - /* 30 */ 27, 26, 25, 361, 1000, 78, 209, 869, 77, 76, - /* 40 */ 75, 74, 73, 72, 71, 70, 69, 1091, 211, 414, - /* 50 */ 413, 412, 411, 410, 409, 408, 407, 406, 405, 404, - /* 60 */ 403, 402, 401, 400, 399, 398, 397, 396, 1003, 105, - /* 70 */ 270, 1014, 881, 31, 29, 27, 26, 25, 1231, 132, - /* 80 */ 904, 349, 111, 249, 237, 346, 1216, 1180, 275, 78, - /* 90 */ 131, 22, 77, 76, 75, 74, 73, 72, 71, 70, - /* 100 */ 69, 31, 29, 27, 26, 25, 1231, 1317, 211, 291, - /* 110 */ 320, 286, 270, 346, 290, 44, 905, 289, 129, 287, - /* 120 */ 117, 345, 288, 348, 1315, 23, 232, 1192, 899, 900, - /* 130 */ 901, 902, 903, 907, 908, 909, 1082, 204, 1217, 1220, - /* 140 */ 904, 772, 385, 384, 383, 776, 382, 778, 779, 381, - /* 150 */ 781, 378, 109, 787, 375, 789, 790, 372, 369, 1151, - /* 160 */ 1216, 849, 128, 1144, 305, 224, 125, 43, 326, 189, - /* 170 */ 1149, 361, 1136, 30, 28, 941, 905, 847, 258, 242, - /* 180 */ 1231, 234, 395, 849, 1102, 23, 232, 346, 899, 900, - /* 190 */ 901, 902, 903, 907, 908, 909, 1204, 348, 361, 847, - /* 200 */ 896, 1192, 1200, 1205, 306, 362, 334, 848, 12, 118, - /* 210 */ 66, 61, 1217, 1220, 1256, 1216, 965, 279, 210, 1252, - /* 220 */ 1168, 10, 122, 121, 30, 28, 1106, 120, 1317, 848, - /* 230 */ 1317, 1, 234, 426, 849, 1231, 316, 963, 964, 966, - /* 240 */ 967, 117, 333, 117, 1216, 1315, 245, 1315, 10, 324, - /* 250 */ 847, 337, 348, 1171, 1173, 426, 1192, 349, 699, 12, - /* 260 */ 698, 850, 853, 1181, 1231, 362, 62, 1217, 1220, 1256, - /* 270 */ 66, 333, 283, 227, 1252, 112, 282, 285, 700, 330, - /* 280 */ 848, 348, 1, 850, 853, 1192, 1106, 166, 118, 9, - /* 290 */ 8, 59, 1216, 312, 1283, 62, 1217, 1220, 1256, 284, - /* 300 */ 92, 93, 227, 1252, 112, 1317, 426, 330, 1098, 106, - /* 310 */ 1073, 906, 1231, 31, 29, 27, 26, 25, 1316, 346, - /* 320 */ 21, 1216, 1315, 1284, 395, 1270, 90, 871, 92, 348, - /* 330 */ 910, 422, 421, 1192, 850, 853, 114, 1263, 1264, 870, - /* 340 */ 1268, 1231, 1267, 62, 1217, 1220, 1256, 334, 346, 118, - /* 350 */ 227, 1252, 1329, 698, 90, 1097, 1216, 867, 348, 917, - /* 360 */ 1231, 1290, 1192, 868, 163, 1263, 329, 346, 328, 277, - /* 370 */ 238, 1317, 62, 1217, 1220, 1256, 1231, 362, 104, 227, - /* 380 */ 1252, 1329, 1103, 346, 117, 1216, 1108, 388, 1315, 1025, - /* 390 */ 1313, 1093, 323, 348, 30, 28, 1192, 1192, 1106, 1024, - /* 400 */ 1270, 336, 234, 104, 849, 1231, 1083, 62, 1217, 1220, - /* 410 */ 1256, 1109, 346, 1151, 227, 1252, 1329, 1266, 362, 239, - /* 420 */ 847, 1151, 348, 359, 1149, 1274, 1192, 246, 165, 12, - /* 430 */ 1192, 334, 1149, 30, 28, 1015, 199, 1217, 1220, 1106, - /* 440 */ 1192, 234, 1216, 849, 194, 1023, 1022, 1021, 137, 196, - /* 450 */ 848, 135, 1, 1041, 319, 1317, 30, 28, 347, 847, - /* 460 */ 6, 195, 1231, 392, 234, 1216, 849, 391, 117, 346, - /* 470 */ 1020, 123, 1315, 1151, 118, 292, 426, 325, 321, 348, - /* 480 */ 1019, 1018, 847, 1192, 1172, 1231, 1192, 1192, 1192, 848, - /* 490 */ 393, 7, 346, 63, 1217, 1220, 1256, 1151, 872, 1089, - /* 500 */ 1255, 1252, 348, 1048, 850, 853, 1192, 948, 1150, 390, - /* 510 */ 389, 1192, 848, 869, 7, 426, 63, 1217, 1220, 1256, - /* 520 */ 244, 1192, 1192, 344, 1252, 30, 28, 303, 104, 30, - /* 530 */ 28, 64, 387, 234, 341, 849, 1108, 234, 426, 849, - /* 540 */ 301, 1216, 1270, 850, 853, 1002, 31, 29, 27, 26, - /* 550 */ 25, 847, 291, 936, 286, 847, 1017, 290, 118, 1265, - /* 560 */ 289, 1231, 287, 118, 1216, 288, 850, 853, 346, 87, - /* 570 */ 86, 85, 84, 83, 82, 81, 80, 79, 348, 867, - /* 580 */ 1036, 848, 1192, 7, 1231, 848, 251, 1, 1074, 263, - /* 590 */ 1016, 346, 107, 1217, 1220, 940, 429, 1192, 264, 151, - /* 600 */ 1216, 348, 294, 167, 362, 1192, 247, 426, 342, 360, - /* 610 */ 187, 426, 308, 88, 104, 63, 1217, 1220, 1256, 418, - /* 620 */ 1231, 186, 1108, 1253, 98, 1106, 1013, 346, 317, 335, - /* 630 */ 1330, 1192, 1034, 1012, 1011, 850, 853, 348, 362, 850, - /* 640 */ 853, 1192, 1145, 184, 233, 362, 60, 1010, 1009, 182, - /* 650 */ 248, 205, 1217, 1220, 297, 1008, 160, 1007, 1216, 1106, - /* 660 */ 1275, 936, 1232, 1216, 276, 262, 1106, 1192, 257, 256, - /* 670 */ 255, 254, 253, 338, 1192, 1192, 1006, 856, 1231, 139, - /* 680 */ 358, 1216, 138, 1231, 141, 346, 1216, 140, 1192, 1192, - /* 690 */ 346, 855, 994, 995, 311, 348, 1192, 147, 1192, 1192, - /* 700 */ 348, 1231, 313, 330, 1192, 331, 1231, 859, 346, 205, - /* 710 */ 1217, 1220, 1005, 346, 107, 1217, 1220, 1192, 348, 9, - /* 720 */ 8, 858, 1192, 348, 92, 231, 867, 1192, 1216, 939, - /* 730 */ 235, 1216, 205, 1217, 1220, 1286, 1216, 205, 1217, 1220, - /* 740 */ 31, 29, 27, 26, 25, 339, 330, 1170, 1231, 52, - /* 750 */ 90, 1231, 1331, 1192, 169, 346, 1231, 1081, 346, 332, - /* 760 */ 113, 1263, 1264, 346, 1268, 348, 1099, 92, 348, 1192, - /* 770 */ 2, 119, 1192, 348, 1216, 143, 260, 1192, 142, 203, - /* 780 */ 1217, 1220, 206, 1217, 1220, 962, 156, 197, 1217, 1220, - /* 790 */ 252, 259, 261, 90, 1231, 265, 1216, 41, 154, 881, - /* 800 */ 911, 346, 1216, 115, 1263, 1264, 875, 1268, 997, 998, - /* 810 */ 266, 348, 32, 267, 392, 1192, 1231, 124, 391, 874, - /* 820 */ 878, 58, 1231, 346, 127, 207, 1217, 1220, 1210, 346, - /* 830 */ 1216, 54, 32, 348, 842, 268, 1216, 1192, 271, 348, - /* 840 */ 1208, 393, 42, 1192, 278, 130, 32, 198, 1217, 1220, - /* 850 */ 1231, 873, 68, 208, 1217, 1220, 1231, 346, 175, 280, - /* 860 */ 390, 389, 223, 346, 1216, 1096, 354, 348, 181, 134, - /* 870 */ 173, 1192, 1092, 348, 765, 136, 100, 1192, 95, 101, - /* 880 */ 96, 1228, 1217, 1220, 1231, 1094, 98, 1227, 1217, 1220, - /* 890 */ 760, 346, 1216, 1090, 793, 797, 102, 803, 1216, 802, - /* 900 */ 310, 348, 41, 103, 146, 1192, 367, 96, 99, 97, - /* 910 */ 149, 98, 1231, 307, 309, 1226, 1217, 1220, 1231, 346, - /* 920 */ 96, 872, 318, 1297, 1287, 346, 352, 152, 853, 348, - /* 930 */ 315, 1296, 1216, 1192, 226, 348, 5, 159, 155, 1192, - /* 940 */ 1216, 322, 327, 214, 1217, 1220, 241, 240, 1277, 213, - /* 950 */ 1217, 1220, 1231, 314, 4, 161, 861, 936, 91, 346, - /* 960 */ 1231, 871, 110, 1271, 33, 162, 228, 346, 1216, 348, - /* 970 */ 1332, 340, 854, 1192, 296, 218, 343, 348, 17, 1238, - /* 980 */ 1179, 1192, 168, 215, 1217, 1220, 350, 1314, 1231, 304, - /* 990 */ 351, 212, 1217, 1220, 355, 346, 1178, 283, 356, 236, - /* 1000 */ 177, 282, 857, 145, 357, 348, 299, 179, 53, 1192, - /* 1010 */ 51, 293, 188, 219, 144, 217, 216, 190, 281, 202, - /* 1020 */ 1217, 1220, 1107, 365, 284, 185, 425, 200, 363, 201, - /* 1030 */ 192, 193, 1186, 825, 1163, 1162, 94, 1161, 1160, 40, - /* 1040 */ 1159, 1158, 39, 1157, 1156, 827, 1155, 1154, 1153, 1152, - /* 1050 */ 1047, 1185, 1176, 126, 1085, 711, 862, 853, 1046, 1044, - /* 1060 */ 272, 273, 274, 1033, 1032, 1029, 1087, 67, 133, 808, - /* 1070 */ 1086, 807, 1042, 1037, 740, 806, 1035, 739, 1028, 220, - /* 1080 */ 738, 1027, 221, 737, 222, 1184, 1183, 36, 1175, 150, - /* 1090 */ 300, 302, 3, 736, 735, 65, 45, 32, 14, 153, - /* 1100 */ 295, 37, 15, 158, 19, 298, 1208, 34, 11, 164, - /* 1110 */ 48, 8, 35, 16, 148, 897, 353, 1174, 180, 1001, - /* 1120 */ 1001, 1001, 1001, 1001, 1001, 1001, 1001, 1001, 1001, 1001, - /* 1130 */ 983, 982, 229, 987, 986, 230, 863, 1001, 1001, 1001, - /* 1140 */ 1001, 1001, 1001, 178, 1001, 961, 1001, 108, 1001, 157, - /* 1150 */ 1001, 955, 46, 1001, 954, 933, 1001, 47, 1001, 1001, - /* 1160 */ 932, 1001, 988, 1001, 1001, 1001, 1001, 1001, 1001, 366, - /* 1170 */ 879, 13, 116, 18, 243, 172, 959, 174, 176, 1001, - /* 1180 */ 171, 49, 50, 1001, 1207, 38, 370, 1001, 373, 794, - /* 1190 */ 54, 376, 771, 1001, 379, 183, 1001, 364, 799, 1001, - /* 1200 */ 1001, 1001, 368, 731, 791, 371, 1043, 1001, 788, 723, - /* 1210 */ 1001, 428, 423, 801, 374, 786, 800, 782, 1001, 1001, - /* 1220 */ 1001, 730, 377, 729, 728, 709, 780, 727, 380, 394, - /* 1230 */ 785, 726, 1031, 725, 724, 417, 722, 721, 1030, 1026, - /* 1240 */ 416, 720, 55, 56, 57, 415, 420, 732, 719, 424, - /* 1250 */ 1001, 851, 718, 717, 716, 386, 715, 784, 191, 783, - /* 1260 */ 714, 419, 427, + /* 0 */ 1235, 1220, 225, 1208, 1220, 349, 242, 346, 237, 1204, + /* 10 */ 1210, 1184, 31, 29, 27, 26, 25, 1097, 105, 1208, + /* 20 */ 1017, 1235, 362, 1208, 1235, 1204, 1209, 66, 346, 1204, + /* 30 */ 1209, 346, 320, 1235, 279, 361, 24, 170, 348, 362, + /* 40 */ 346, 348, 1196, 1108, 66, 1196, 361, 211, 1048, 250, + /* 50 */ 334, 285, 107, 1221, 1224, 61, 1221, 1224, 1260, 362, + /* 60 */ 1108, 194, 210, 1256, 269, 323, 196, 349, 283, 884, + /* 70 */ 109, 362, 282, 1185, 1321, 209, 1105, 907, 195, 43, + /* 80 */ 1108, 1148, 31, 29, 27, 26, 25, 117, 123, 335, + /* 90 */ 1334, 1319, 1108, 284, 10, 1099, 1104, 415, 414, 413, + /* 100 */ 412, 411, 410, 409, 408, 407, 406, 405, 404, 403, + /* 110 */ 402, 401, 400, 399, 398, 270, 908, 211, 31, 29, + /* 120 */ 27, 26, 25, 9, 8, 23, 232, 1006, 902, 903, + /* 130 */ 904, 905, 906, 910, 911, 912, 1196, 27, 26, 25, + /* 140 */ 31, 29, 27, 26, 25, 1003, 1028, 907, 78, 64, + /* 150 */ 870, 77, 76, 75, 74, 73, 72, 71, 70, 69, + /* 160 */ 319, 773, 385, 384, 383, 777, 382, 779, 780, 381, + /* 170 */ 782, 378, 1274, 788, 375, 790, 791, 372, 369, 872, + /* 180 */ 291, 118, 286, 325, 321, 290, 908, 1196, 289, 1271, + /* 190 */ 287, 920, 1220, 288, 249, 23, 232, 884, 902, 903, + /* 200 */ 904, 905, 906, 910, 911, 912, 31, 29, 27, 26, + /* 210 */ 25, 324, 1235, 106, 1075, 423, 422, 78, 1321, 333, + /* 220 */ 77, 76, 75, 74, 73, 72, 71, 70, 69, 348, + /* 230 */ 43, 117, 238, 1196, 968, 1319, 1321, 218, 118, 89, + /* 240 */ 104, 874, 1220, 62, 1221, 1224, 1260, 1103, 1110, 1320, + /* 250 */ 227, 1256, 112, 1319, 316, 966, 967, 969, 970, 283, + /* 260 */ 875, 330, 1235, 282, 166, 997, 998, 870, 118, 333, + /* 270 */ 312, 1287, 1220, 219, 251, 217, 216, 263, 281, 348, + /* 280 */ 245, 244, 92, 1196, 284, 362, 264, 1175, 1177, 104, + /* 290 */ 359, 1172, 1235, 62, 1221, 1224, 1260, 1110, 120, 346, + /* 300 */ 227, 1256, 112, 1279, 939, 361, 1108, 362, 90, 348, + /* 310 */ 1027, 700, 360, 1196, 701, 1220, 700, 332, 113, 1267, + /* 320 */ 1268, 1288, 1272, 62, 1221, 1224, 1260, 277, 1108, 330, + /* 330 */ 227, 1256, 1333, 6, 702, 1235, 1026, 30, 28, 241, + /* 340 */ 240, 1294, 346, 165, 1220, 234, 258, 852, 873, 864, + /* 350 */ 92, 1196, 348, 10, 262, 397, 1196, 257, 256, 255, + /* 360 */ 254, 253, 151, 850, 1235, 857, 62, 1221, 1224, 1260, + /* 370 */ 909, 346, 12, 227, 1256, 1333, 90, 1196, 362, 21, + /* 380 */ 1086, 348, 871, 184, 1317, 1196, 114, 1267, 1268, 913, + /* 390 */ 1272, 122, 121, 1, 1155, 62, 1221, 1224, 1260, 1108, + /* 400 */ 224, 1220, 227, 1256, 1333, 1153, 30, 28, 944, 1084, + /* 410 */ 30, 28, 189, 1278, 234, 1138, 852, 427, 234, 363, + /* 420 */ 852, 1235, 943, 118, 9, 8, 270, 939, 346, 851, + /* 430 */ 305, 860, 850, 1155, 951, 1025, 850, 1024, 348, 239, + /* 440 */ 872, 12, 1196, 1085, 1153, 12, 20, 334, 853, 856, + /* 450 */ 865, 856, 201, 1221, 1224, 397, 31, 29, 27, 26, + /* 460 */ 25, 104, 1, 118, 1023, 247, 1, 30, 28, 1111, + /* 470 */ 306, 1321, 1083, 104, 1155, 234, 1196, 852, 1196, 59, + /* 480 */ 246, 1110, 1274, 1220, 117, 1153, 427, 362, 1319, 93, + /* 490 */ 427, 388, 248, 850, 1321, 1155, 1100, 1022, 851, 1270, + /* 500 */ 394, 345, 851, 1235, 393, 1196, 1176, 117, 1108, 337, + /* 510 */ 346, 1319, 1220, 52, 1021, 1020, 1076, 853, 856, 1093, + /* 520 */ 348, 853, 856, 7, 1196, 395, 1019, 1016, 1015, 394, + /* 530 */ 1101, 1014, 1235, 393, 63, 1221, 1224, 1260, 1196, 346, + /* 540 */ 330, 1259, 1256, 1095, 392, 391, 390, 427, 389, 348, + /* 550 */ 30, 28, 347, 1196, 395, 1196, 1196, 942, 234, 851, + /* 560 */ 852, 92, 1013, 63, 1221, 1224, 1260, 1196, 1196, 1196, + /* 570 */ 344, 1256, 1196, 392, 391, 390, 850, 389, 853, 856, + /* 580 */ 334, 899, 1220, 308, 30, 28, 1012, 90, 1011, 1091, + /* 590 */ 1274, 1010, 234, 118, 852, 98, 1009, 163, 1267, 329, + /* 600 */ 852, 328, 1235, 1196, 1321, 1008, 7, 1269, 137, 346, + /* 610 */ 850, 135, 30, 28, 1155, 139, 850, 117, 138, 348, + /* 620 */ 234, 1319, 852, 1196, 1005, 1154, 303, 1196, 141, 1196, + /* 630 */ 427, 140, 1196, 63, 1221, 1224, 1260, 1196, 850, 301, + /* 640 */ 7, 1257, 851, 1044, 1000, 1001, 1196, 1039, 87, 86, + /* 650 */ 85, 84, 83, 82, 81, 80, 79, 1037, 430, 387, + /* 660 */ 336, 853, 856, 58, 427, 292, 1220, 341, 1, 294, + /* 670 */ 427, 143, 187, 54, 142, 88, 851, 965, 156, 297, + /* 680 */ 859, 419, 851, 186, 338, 1220, 1235, 914, 881, 41, + /* 690 */ 154, 1018, 427, 346, 167, 853, 856, 317, 1149, 32, + /* 700 */ 32, 853, 856, 348, 851, 1235, 60, 1196, 1214, 182, + /* 710 */ 233, 160, 346, 845, 276, 1220, 858, 205, 1221, 1224, + /* 720 */ 1212, 1220, 348, 853, 856, 32, 1196, 175, 1290, 313, + /* 730 */ 331, 354, 330, 1236, 1220, 1235, 205, 1221, 1224, 173, + /* 740 */ 358, 1235, 346, 95, 342, 169, 862, 2, 346, 870, + /* 750 */ 1174, 181, 348, 92, 1235, 252, 1196, 311, 348, 339, + /* 760 */ 147, 346, 1196, 96, 260, 766, 204, 1221, 1224, 761, + /* 770 */ 259, 348, 107, 1221, 1224, 1196, 119, 98, 231, 90, + /* 780 */ 1220, 41, 861, 794, 261, 205, 1221, 1224, 1220, 115, + /* 790 */ 1267, 1268, 22, 1272, 878, 367, 265, 326, 267, 798, + /* 800 */ 1235, 804, 31, 29, 27, 26, 25, 346, 1235, 266, + /* 810 */ 1335, 96, 124, 97, 803, 346, 1220, 348, 99, 877, + /* 820 */ 268, 1196, 1220, 271, 235, 348, 98, 127, 42, 1196, + /* 830 */ 96, 205, 1221, 1224, 130, 876, 1235, 278, 280, 203, + /* 840 */ 1221, 1224, 1235, 346, 1220, 68, 307, 1098, 223, 346, + /* 850 */ 134, 1094, 136, 348, 100, 146, 101, 1196, 1096, 348, + /* 860 */ 1092, 102, 103, 1196, 1235, 149, 875, 206, 1221, 1224, + /* 870 */ 309, 346, 1220, 199, 1221, 1224, 1301, 318, 1220, 352, + /* 880 */ 856, 348, 1300, 1291, 159, 1196, 310, 314, 5, 152, + /* 890 */ 1281, 1220, 1235, 315, 226, 207, 1221, 1224, 1235, 346, + /* 900 */ 155, 4, 322, 327, 939, 346, 91, 874, 33, 348, + /* 910 */ 161, 1235, 162, 1196, 1275, 348, 228, 343, 346, 1196, + /* 920 */ 1220, 340, 17, 200, 1221, 1224, 1220, 1242, 348, 208, + /* 930 */ 1221, 1224, 1196, 110, 1183, 350, 351, 355, 177, 1220, + /* 940 */ 1235, 1318, 1232, 1221, 1224, 1336, 1235, 346, 1220, 168, + /* 950 */ 1182, 236, 357, 346, 356, 179, 188, 348, 51, 1235, + /* 960 */ 53, 1196, 1109, 348, 1051, 365, 346, 1196, 1235, 190, + /* 970 */ 185, 1231, 1221, 1224, 426, 346, 348, 1230, 1221, 1224, + /* 980 */ 1196, 197, 198, 1220, 192, 348, 193, 1190, 828, 1196, + /* 990 */ 214, 1221, 1224, 132, 1167, 1166, 111, 94, 1165, 213, + /* 1000 */ 1221, 1224, 275, 1235, 131, 1164, 1163, 1162, 1161, 1160, + /* 1010 */ 346, 1220, 830, 291, 1159, 286, 1158, 1220, 290, 1157, + /* 1020 */ 348, 289, 1156, 287, 1196, 1050, 288, 44, 1189, 1180, + /* 1030 */ 129, 1235, 126, 1087, 215, 1221, 1224, 1235, 346, 713, + /* 1040 */ 1049, 1047, 296, 274, 346, 1036, 273, 1035, 348, 272, + /* 1050 */ 1032, 1089, 1196, 67, 348, 133, 811, 304, 1196, 810, + /* 1060 */ 1088, 809, 212, 1221, 1224, 741, 1045, 1040, 202, 1221, + /* 1070 */ 1224, 145, 740, 739, 299, 738, 220, 128, 221, 293, + /* 1080 */ 737, 125, 144, 295, 736, 1038, 222, 298, 1031, 1030, + /* 1090 */ 300, 302, 65, 1188, 1187, 36, 1179, 14, 45, 150, + /* 1100 */ 148, 3, 34, 15, 32, 40, 48, 37, 39, 11, + /* 1110 */ 8, 1212, 153, 158, 986, 985, 164, 964, 229, 990, + /* 1120 */ 108, 157, 989, 900, 958, 230, 46, 1178, 957, 47, + /* 1130 */ 1004, 866, 936, 353, 935, 1004, 1004, 1004, 1004, 1004, + /* 1140 */ 991, 178, 1046, 19, 882, 366, 1004, 13, 243, 1004, + /* 1150 */ 18, 35, 172, 116, 174, 16, 370, 373, 171, 962, + /* 1160 */ 176, 376, 1004, 49, 379, 50, 772, 800, 1034, 1033, + /* 1170 */ 806, 38, 1029, 802, 795, 792, 733, 54, 725, 368, + /* 1180 */ 1211, 183, 371, 364, 789, 374, 801, 732, 396, 783, + /* 1190 */ 377, 731, 421, 781, 711, 730, 380, 729, 55, 728, + /* 1200 */ 727, 56, 57, 726, 724, 723, 787, 786, 180, 722, + /* 1210 */ 785, 386, 721, 720, 719, 784, 718, 717, 716, 416, + /* 1220 */ 417, 420, 424, 425, 428, 418, 854, 191, 429, 805, }; static const YYCODETYPE yy_lookahead[] = { - /* 0 */ 0, 207, 190, 174, 221, 222, 172, 213, 214, 187, - /* 10 */ 172, 177, 183, 12, 13, 14, 15, 16, 2, 207, - /* 20 */ 191, 14, 15, 16, 0, 213, 214, 193, 12, 13, - /* 30 */ 14, 15, 16, 20, 163, 21, 198, 20, 24, 25, - /* 40 */ 26, 27, 28, 29, 30, 31, 32, 187, 47, 49, - /* 50 */ 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, - /* 60 */ 60, 61, 62, 63, 64, 65, 66, 67, 0, 165, - /* 70 */ 46, 167, 71, 12, 13, 14, 15, 16, 186, 33, - /* 80 */ 79, 203, 36, 212, 206, 193, 166, 209, 42, 21, - /* 90 */ 44, 2, 24, 25, 26, 27, 28, 29, 30, 31, - /* 100 */ 32, 12, 13, 14, 15, 16, 186, 236, 47, 49, - /* 110 */ 218, 51, 46, 193, 54, 69, 115, 57, 72, 59, - /* 120 */ 249, 47, 62, 203, 253, 124, 125, 207, 127, 128, - /* 130 */ 129, 130, 131, 132, 133, 134, 0, 217, 218, 219, - /* 140 */ 79, 85, 86, 87, 88, 89, 90, 91, 92, 93, - /* 150 */ 94, 95, 185, 97, 98, 99, 100, 101, 102, 186, - /* 160 */ 166, 22, 116, 196, 172, 192, 120, 174, 248, 179, - /* 170 */ 197, 20, 182, 12, 13, 14, 115, 38, 63, 190, - /* 180 */ 186, 20, 46, 22, 191, 124, 125, 193, 127, 128, - /* 190 */ 129, 130, 131, 132, 133, 134, 207, 203, 20, 38, - /* 200 */ 126, 207, 213, 214, 212, 172, 212, 68, 47, 137, - /* 210 */ 177, 217, 218, 219, 220, 166, 126, 184, 224, 225, - /* 220 */ 193, 70, 107, 108, 12, 13, 193, 200, 236, 68, - /* 230 */ 236, 70, 20, 94, 22, 186, 146, 147, 148, 149, - /* 240 */ 150, 249, 193, 249, 166, 253, 195, 253, 70, 20, - /* 250 */ 38, 3, 203, 202, 203, 94, 207, 203, 20, 47, - /* 260 */ 22, 122, 123, 209, 186, 172, 217, 218, 219, 220, - /* 270 */ 177, 193, 57, 224, 225, 226, 61, 184, 40, 172, - /* 280 */ 68, 203, 70, 122, 123, 207, 193, 238, 137, 1, - /* 290 */ 2, 171, 166, 244, 245, 217, 218, 219, 220, 84, - /* 300 */ 193, 181, 224, 225, 226, 236, 94, 172, 188, 175, - /* 310 */ 176, 115, 186, 12, 13, 14, 15, 16, 249, 193, - /* 320 */ 124, 166, 253, 245, 46, 215, 219, 20, 193, 203, - /* 330 */ 134, 169, 170, 207, 122, 123, 229, 230, 231, 20, - /* 340 */ 233, 186, 232, 217, 218, 219, 220, 212, 193, 137, - /* 350 */ 224, 225, 226, 22, 219, 166, 166, 20, 203, 71, - /* 360 */ 186, 235, 207, 20, 229, 230, 231, 193, 233, 38, - /* 370 */ 178, 236, 217, 218, 219, 220, 186, 172, 186, 224, - /* 380 */ 225, 226, 177, 193, 249, 166, 194, 81, 253, 166, - /* 390 */ 235, 187, 218, 203, 12, 13, 207, 207, 193, 166, - /* 400 */ 215, 153, 20, 186, 22, 186, 0, 217, 218, 219, - /* 410 */ 220, 194, 193, 186, 224, 225, 226, 232, 172, 192, - /* 420 */ 38, 186, 203, 177, 197, 235, 207, 192, 121, 47, - /* 430 */ 207, 212, 197, 12, 13, 167, 217, 218, 219, 193, - /* 440 */ 207, 20, 166, 22, 18, 166, 166, 166, 74, 23, - /* 450 */ 68, 77, 70, 0, 119, 236, 12, 13, 14, 38, - /* 460 */ 43, 35, 186, 57, 20, 166, 22, 61, 249, 193, - /* 470 */ 166, 45, 253, 186, 137, 22, 94, 142, 143, 203, - /* 480 */ 166, 166, 38, 207, 197, 186, 207, 207, 207, 68, - /* 490 */ 84, 70, 193, 217, 218, 219, 220, 186, 20, 187, - /* 500 */ 224, 225, 203, 0, 122, 123, 207, 14, 197, 103, - /* 510 */ 104, 207, 68, 20, 70, 94, 217, 218, 219, 220, - /* 520 */ 178, 207, 207, 224, 225, 12, 13, 21, 186, 12, - /* 530 */ 13, 105, 187, 20, 83, 22, 194, 20, 94, 22, - /* 540 */ 34, 166, 215, 122, 123, 0, 12, 13, 14, 15, - /* 550 */ 16, 38, 49, 136, 51, 38, 166, 54, 137, 232, - /* 560 */ 57, 186, 59, 137, 166, 62, 122, 123, 193, 24, - /* 570 */ 25, 26, 27, 28, 29, 30, 31, 32, 203, 20, - /* 580 */ 0, 68, 207, 70, 186, 68, 27, 70, 176, 30, - /* 590 */ 166, 193, 217, 218, 219, 4, 19, 207, 39, 121, - /* 600 */ 166, 203, 22, 256, 172, 207, 178, 94, 157, 177, - /* 610 */ 33, 94, 71, 36, 186, 217, 218, 219, 220, 42, - /* 620 */ 186, 44, 194, 225, 83, 193, 166, 193, 247, 254, - /* 630 */ 255, 207, 0, 166, 166, 122, 123, 203, 172, 122, - /* 640 */ 123, 207, 196, 177, 210, 172, 69, 166, 166, 72, - /* 650 */ 177, 217, 218, 219, 22, 166, 241, 166, 166, 193, - /* 660 */ 135, 136, 186, 166, 169, 106, 193, 207, 109, 110, - /* 670 */ 111, 112, 113, 83, 207, 207, 166, 38, 186, 74, - /* 680 */ 103, 166, 77, 186, 74, 193, 166, 77, 207, 207, - /* 690 */ 193, 38, 158, 159, 117, 203, 207, 120, 207, 207, - /* 700 */ 203, 186, 210, 172, 207, 234, 186, 68, 193, 217, - /* 710 */ 218, 219, 166, 193, 217, 218, 219, 207, 203, 1, - /* 720 */ 2, 68, 207, 203, 193, 210, 20, 207, 166, 138, - /* 730 */ 210, 166, 217, 218, 219, 216, 166, 217, 218, 219, - /* 740 */ 12, 13, 14, 15, 16, 155, 172, 172, 186, 171, - /* 750 */ 219, 186, 255, 207, 250, 193, 186, 0, 193, 228, - /* 760 */ 229, 230, 231, 193, 233, 203, 188, 193, 203, 207, - /* 770 */ 237, 114, 207, 203, 166, 74, 115, 207, 77, 217, - /* 780 */ 218, 219, 217, 218, 219, 71, 71, 217, 218, 219, - /* 790 */ 201, 199, 199, 219, 186, 172, 166, 83, 83, 71, - /* 800 */ 71, 193, 166, 229, 230, 231, 20, 233, 161, 162, - /* 810 */ 211, 203, 83, 193, 57, 207, 186, 174, 61, 20, - /* 820 */ 71, 70, 186, 193, 174, 217, 218, 219, 70, 193, - /* 830 */ 166, 80, 83, 203, 71, 204, 166, 207, 172, 203, - /* 840 */ 82, 84, 174, 207, 168, 174, 83, 217, 218, 219, - /* 850 */ 186, 20, 172, 217, 218, 219, 186, 193, 71, 186, - /* 860 */ 103, 104, 168, 193, 166, 186, 71, 203, 71, 186, - /* 870 */ 83, 207, 186, 203, 71, 186, 186, 207, 83, 186, - /* 880 */ 83, 217, 218, 219, 186, 186, 83, 217, 218, 219, - /* 890 */ 71, 193, 166, 186, 71, 71, 186, 71, 166, 71, - /* 900 */ 204, 203, 83, 186, 171, 207, 83, 83, 71, 83, - /* 910 */ 171, 83, 186, 211, 193, 217, 218, 219, 186, 193, - /* 920 */ 83, 20, 145, 246, 216, 193, 144, 208, 123, 203, - /* 930 */ 207, 246, 166, 207, 207, 203, 152, 242, 208, 207, - /* 940 */ 166, 207, 151, 217, 218, 219, 12, 13, 243, 217, - /* 950 */ 218, 219, 186, 140, 139, 239, 22, 136, 193, 193, - /* 960 */ 186, 20, 240, 215, 114, 227, 160, 193, 166, 203, - /* 970 */ 257, 154, 38, 207, 4, 35, 156, 203, 70, 223, - /* 980 */ 208, 207, 251, 217, 218, 219, 207, 252, 186, 19, - /* 990 */ 207, 217, 218, 219, 118, 193, 208, 57, 205, 207, - /* 1000 */ 193, 61, 68, 33, 204, 203, 36, 171, 70, 207, - /* 1010 */ 171, 41, 182, 73, 44, 75, 76, 172, 78, 217, - /* 1020 */ 218, 219, 193, 189, 84, 171, 168, 180, 94, 180, - /* 1030 */ 173, 164, 0, 82, 0, 0, 114, 0, 0, 69, - /* 1040 */ 0, 0, 72, 0, 0, 22, 0, 0, 0, 0, - /* 1050 */ 0, 0, 0, 43, 0, 48, 122, 123, 0, 0, - /* 1060 */ 38, 36, 43, 0, 0, 0, 0, 79, 77, 38, - /* 1070 */ 0, 38, 0, 0, 38, 22, 0, 38, 0, 22, - /* 1080 */ 38, 0, 22, 38, 22, 0, 0, 121, 0, 116, - /* 1090 */ 22, 22, 83, 38, 38, 20, 70, 83, 141, 71, - /* 1100 */ 39, 83, 141, 83, 83, 38, 82, 135, 141, 82, - /* 1110 */ 4, 2, 83, 83, 43, 126, 119, 0, 116, 258, - /* 1120 */ 258, 258, 258, 258, 258, 258, 258, 258, 258, 258, - /* 1130 */ 38, 38, 38, 38, 38, 38, 22, 258, 258, 258, - /* 1140 */ 258, 258, 258, 43, 258, 71, 258, 70, 258, 70, - /* 1150 */ 258, 71, 70, 258, 71, 71, 258, 70, 258, 258, - /* 1160 */ 71, 258, 71, 258, 258, 258, 258, 258, 258, 38, - /* 1170 */ 71, 70, 82, 70, 38, 71, 71, 70, 70, 258, - /* 1180 */ 82, 70, 70, 258, 82, 70, 38, 258, 38, 71, - /* 1190 */ 80, 38, 22, 258, 38, 82, 258, 81, 22, 258, - /* 1200 */ 258, 258, 70, 22, 71, 70, 0, 258, 71, 22, - /* 1210 */ 258, 20, 22, 38, 70, 96, 38, 71, 258, 258, - /* 1220 */ 258, 38, 70, 38, 38, 48, 71, 38, 70, 47, - /* 1230 */ 96, 38, 0, 38, 38, 43, 38, 38, 0, 0, - /* 1240 */ 36, 38, 70, 70, 70, 38, 37, 68, 38, 21, - /* 1250 */ 258, 22, 38, 38, 38, 84, 38, 96, 22, 96, - /* 1260 */ 38, 38, 21, 258, 258, 258, 258, 258, 258, 258, - /* 1270 */ 258, 258, 258, 258, 258, 258, 258, 258, 258, 258, - /* 1280 */ 258, 258, 258, 258, 258, 258, 258, 258, 258, 258, - /* 1290 */ 258, 258, 258, 258, 258, 258, 258, 258, 258, 258, - /* 1300 */ 258, 258, 258, 258, 258, 258, 258, 258, 258, 258, - /* 1310 */ 258, 258, 258, 258, 258, 258, 258, 258, 258, 258, - /* 1320 */ 258, 258, 258, 258, 258, 258, 258, 258, 258, 258, - /* 1330 */ 258, 258, 258, 258, 258, 258, 258, 258, 258, 258, - /* 1340 */ 258, 258, 258, 258, 258, 258, 258, 258, 258, 258, - /* 1350 */ 258, 258, 258, 258, 258, 258, 258, 258, 258, 258, - /* 1360 */ 258, 258, 258, 258, 258, 258, 258, 258, 258, 258, - /* 1370 */ 258, 258, 258, 258, 258, 258, 258, 258, 258, 258, - /* 1380 */ 258, 258, 258, 258, 258, 258, 258, 258, 258, 258, - /* 1390 */ 258, 258, 258, 258, 258, 258, 258, 258, 258, 258, - /* 1400 */ 258, 258, 258, 258, 258, 258, 258, 258, 258, 258, - /* 1410 */ 258, 258, 258, 258, 258, 258, 258, 258, 258, 258, - /* 1420 */ 258, 258, 258, 258, 258, 258, + /* 0 */ 187, 167, 191, 208, 167, 204, 191, 194, 207, 214, + /* 10 */ 215, 210, 12, 13, 14, 15, 16, 188, 166, 208, + /* 20 */ 168, 187, 173, 208, 187, 214, 215, 178, 194, 214, + /* 30 */ 215, 194, 219, 187, 185, 20, 222, 223, 204, 173, + /* 40 */ 194, 204, 208, 194, 178, 208, 20, 47, 0, 173, + /* 50 */ 213, 185, 218, 219, 220, 218, 219, 220, 221, 173, + /* 60 */ 194, 18, 225, 226, 178, 219, 23, 204, 57, 69, + /* 70 */ 186, 173, 61, 210, 237, 199, 178, 77, 35, 175, + /* 80 */ 194, 197, 12, 13, 14, 15, 16, 250, 45, 255, + /* 90 */ 256, 254, 194, 82, 68, 167, 192, 49, 50, 51, + /* 100 */ 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, + /* 110 */ 62, 63, 64, 65, 66, 46, 116, 47, 12, 13, + /* 120 */ 14, 15, 16, 1, 2, 125, 126, 0, 128, 129, + /* 130 */ 130, 131, 132, 133, 134, 135, 208, 14, 15, 16, + /* 140 */ 12, 13, 14, 15, 16, 164, 167, 77, 21, 106, + /* 150 */ 20, 24, 25, 26, 27, 28, 29, 30, 31, 32, + /* 160 */ 120, 83, 84, 85, 86, 87, 88, 89, 90, 91, + /* 170 */ 92, 93, 216, 95, 96, 97, 98, 99, 100, 20, + /* 180 */ 49, 138, 51, 143, 144, 54, 116, 208, 57, 233, + /* 190 */ 59, 69, 167, 62, 213, 125, 126, 69, 128, 129, + /* 200 */ 130, 131, 132, 133, 134, 135, 12, 13, 14, 15, + /* 210 */ 16, 20, 187, 176, 177, 170, 171, 21, 237, 194, + /* 220 */ 24, 25, 26, 27, 28, 29, 30, 31, 32, 204, + /* 230 */ 175, 250, 179, 208, 127, 254, 237, 35, 138, 184, + /* 240 */ 187, 20, 167, 218, 219, 220, 221, 192, 195, 250, + /* 250 */ 225, 226, 227, 254, 147, 148, 149, 150, 151, 57, + /* 260 */ 20, 173, 187, 61, 239, 159, 160, 20, 138, 194, + /* 270 */ 245, 246, 167, 71, 27, 73, 74, 30, 76, 204, + /* 280 */ 196, 179, 194, 208, 82, 173, 39, 203, 204, 187, + /* 290 */ 178, 194, 187, 218, 219, 220, 221, 195, 201, 194, + /* 300 */ 225, 226, 227, 136, 137, 20, 194, 173, 220, 204, + /* 310 */ 167, 22, 178, 208, 20, 167, 22, 229, 230, 231, + /* 320 */ 232, 246, 234, 218, 219, 220, 221, 38, 194, 173, + /* 330 */ 225, 226, 227, 43, 40, 187, 167, 12, 13, 12, + /* 340 */ 13, 236, 194, 122, 167, 20, 63, 22, 20, 22, + /* 350 */ 194, 208, 204, 68, 107, 46, 208, 110, 111, 112, + /* 360 */ 113, 114, 122, 38, 187, 38, 218, 219, 220, 221, + /* 370 */ 116, 194, 47, 225, 226, 227, 220, 208, 173, 125, + /* 380 */ 0, 204, 20, 178, 236, 208, 230, 231, 232, 135, + /* 390 */ 234, 108, 109, 68, 187, 218, 219, 220, 221, 194, + /* 400 */ 193, 167, 225, 226, 227, 198, 12, 13, 14, 0, + /* 410 */ 12, 13, 180, 236, 20, 183, 22, 92, 20, 92, + /* 420 */ 22, 187, 4, 138, 1, 2, 46, 137, 194, 104, + /* 430 */ 173, 104, 38, 187, 14, 167, 38, 167, 204, 193, + /* 440 */ 20, 47, 208, 0, 198, 47, 2, 213, 123, 124, + /* 450 */ 123, 124, 218, 219, 220, 46, 12, 13, 14, 15, + /* 460 */ 16, 187, 68, 138, 167, 179, 68, 12, 13, 195, + /* 470 */ 213, 237, 0, 187, 187, 20, 208, 22, 208, 172, + /* 480 */ 193, 195, 216, 167, 250, 198, 92, 173, 254, 182, + /* 490 */ 92, 79, 178, 38, 237, 187, 189, 167, 104, 233, + /* 500 */ 57, 47, 104, 187, 61, 208, 198, 250, 194, 3, + /* 510 */ 194, 254, 167, 172, 167, 167, 177, 123, 124, 188, + /* 520 */ 204, 123, 124, 68, 208, 82, 167, 167, 167, 57, + /* 530 */ 189, 167, 187, 61, 218, 219, 220, 221, 208, 194, + /* 540 */ 173, 225, 226, 188, 101, 102, 103, 92, 105, 204, + /* 550 */ 12, 13, 14, 208, 82, 208, 208, 139, 20, 104, + /* 560 */ 22, 194, 167, 218, 219, 220, 221, 208, 208, 208, + /* 570 */ 225, 226, 208, 101, 102, 103, 38, 105, 123, 124, + /* 580 */ 213, 127, 167, 69, 12, 13, 167, 220, 167, 188, + /* 590 */ 216, 167, 20, 138, 22, 81, 167, 230, 231, 232, + /* 600 */ 22, 234, 187, 208, 237, 167, 68, 233, 72, 194, + /* 610 */ 38, 75, 12, 13, 187, 72, 38, 250, 75, 204, + /* 620 */ 20, 254, 22, 208, 0, 198, 21, 208, 72, 208, + /* 630 */ 92, 75, 208, 218, 219, 220, 221, 208, 38, 34, + /* 640 */ 68, 226, 104, 0, 162, 163, 208, 0, 24, 25, + /* 650 */ 26, 27, 28, 29, 30, 31, 32, 0, 19, 188, + /* 660 */ 154, 123, 124, 68, 92, 22, 167, 81, 68, 22, + /* 670 */ 92, 72, 33, 78, 75, 36, 104, 69, 69, 22, + /* 680 */ 38, 42, 104, 44, 81, 167, 187, 69, 69, 81, + /* 690 */ 81, 168, 92, 194, 257, 123, 124, 248, 197, 81, + /* 700 */ 81, 123, 124, 204, 104, 187, 67, 208, 68, 70, + /* 710 */ 211, 242, 194, 69, 170, 167, 38, 218, 219, 220, + /* 720 */ 80, 167, 204, 123, 124, 81, 208, 69, 217, 211, + /* 730 */ 235, 69, 173, 187, 167, 187, 218, 219, 220, 81, + /* 740 */ 101, 187, 194, 81, 158, 251, 104, 238, 194, 20, + /* 750 */ 173, 69, 204, 194, 187, 202, 208, 118, 204, 156, + /* 760 */ 121, 194, 208, 81, 116, 69, 218, 219, 220, 69, + /* 770 */ 200, 204, 218, 219, 220, 208, 115, 81, 211, 220, + /* 780 */ 167, 81, 104, 69, 200, 218, 219, 220, 167, 230, + /* 790 */ 231, 232, 2, 234, 20, 81, 173, 249, 194, 69, + /* 800 */ 187, 69, 12, 13, 14, 15, 16, 194, 187, 212, + /* 810 */ 256, 81, 175, 81, 69, 194, 167, 204, 69, 20, + /* 820 */ 205, 208, 167, 173, 211, 204, 81, 175, 175, 208, + /* 830 */ 81, 218, 219, 220, 175, 20, 187, 169, 187, 218, + /* 840 */ 219, 220, 187, 194, 167, 173, 212, 187, 169, 194, + /* 850 */ 187, 187, 187, 204, 187, 172, 187, 208, 187, 204, + /* 860 */ 187, 187, 187, 208, 187, 172, 20, 218, 219, 220, + /* 870 */ 194, 194, 167, 218, 219, 220, 247, 146, 167, 145, + /* 880 */ 124, 204, 247, 217, 243, 208, 205, 141, 153, 209, + /* 890 */ 244, 167, 187, 208, 208, 218, 219, 220, 187, 194, + /* 900 */ 209, 140, 208, 152, 137, 194, 194, 20, 115, 204, + /* 910 */ 240, 187, 228, 208, 216, 204, 161, 157, 194, 208, + /* 920 */ 167, 155, 68, 218, 219, 220, 167, 224, 204, 218, + /* 930 */ 219, 220, 208, 241, 209, 208, 208, 119, 194, 167, + /* 940 */ 187, 253, 218, 219, 220, 258, 187, 194, 167, 252, + /* 950 */ 209, 208, 205, 194, 206, 172, 183, 204, 172, 187, + /* 960 */ 68, 208, 194, 204, 0, 190, 194, 208, 187, 173, + /* 970 */ 172, 218, 219, 220, 169, 194, 204, 218, 219, 220, + /* 980 */ 208, 181, 181, 167, 174, 204, 165, 0, 80, 208, + /* 990 */ 218, 219, 220, 33, 0, 0, 36, 115, 0, 218, + /* 1000 */ 219, 220, 42, 187, 44, 0, 0, 0, 0, 0, + /* 1010 */ 194, 167, 22, 49, 0, 51, 0, 167, 54, 0, + /* 1020 */ 204, 57, 0, 59, 208, 0, 62, 67, 0, 0, + /* 1030 */ 70, 187, 43, 0, 218, 219, 220, 187, 194, 48, + /* 1040 */ 0, 0, 4, 43, 194, 0, 36, 0, 204, 38, + /* 1050 */ 0, 0, 208, 77, 204, 75, 38, 19, 208, 38, + /* 1060 */ 0, 22, 218, 219, 220, 38, 0, 0, 218, 219, + /* 1070 */ 220, 33, 38, 38, 36, 38, 22, 117, 22, 41, + /* 1080 */ 38, 121, 44, 39, 38, 0, 22, 38, 0, 0, + /* 1090 */ 22, 22, 20, 0, 0, 122, 0, 142, 68, 117, + /* 1100 */ 43, 81, 136, 142, 81, 67, 4, 81, 70, 142, + /* 1110 */ 2, 80, 69, 81, 38, 38, 80, 69, 38, 38, + /* 1120 */ 68, 68, 38, 127, 69, 38, 68, 0, 69, 68, + /* 1130 */ 259, 22, 69, 120, 69, 259, 259, 259, 259, 259, + /* 1140 */ 69, 43, 0, 81, 69, 38, 259, 68, 38, 259, + /* 1150 */ 68, 81, 69, 80, 68, 81, 38, 38, 80, 69, + /* 1160 */ 68, 38, 259, 68, 38, 68, 22, 22, 0, 0, + /* 1170 */ 38, 68, 0, 38, 69, 69, 22, 78, 22, 68, + /* 1180 */ 80, 80, 68, 79, 69, 68, 38, 38, 47, 69, + /* 1190 */ 68, 38, 37, 69, 48, 38, 68, 38, 68, 38, + /* 1200 */ 38, 68, 68, 38, 38, 38, 94, 94, 117, 38, + /* 1210 */ 94, 82, 38, 38, 38, 94, 38, 38, 38, 38, + /* 1220 */ 36, 38, 22, 21, 21, 43, 22, 22, 20, 104, + /* 1230 */ 259, 259, 259, 259, 259, 259, 259, 259, 259, 259, + /* 1240 */ 259, 259, 259, 259, 259, 259, 259, 259, 259, 259, + /* 1250 */ 259, 259, 259, 259, 259, 259, 259, 259, 259, 259, + /* 1260 */ 259, 259, 259, 259, 259, 259, 259, 259, 259, 259, + /* 1270 */ 259, 259, 259, 259, 259, 259, 259, 259, 259, 259, + /* 1280 */ 259, 259, 259, 259, 259, 259, 259, 259, 259, 259, + /* 1290 */ 259, 259, 259, 259, 259, 259, 259, 259, 259, 259, + /* 1300 */ 259, 259, 259, 259, 259, 259, 259, 259, 259, 259, + /* 1310 */ 259, 259, 259, 259, 259, 259, 259, 259, 259, 259, + /* 1320 */ 259, 259, 259, 259, 259, 259, 259, 259, 259, 259, + /* 1330 */ 259, 259, 259, 259, 259, 259, 259, 259, 259, 259, + /* 1340 */ 259, 259, 259, 259, 259, 259, 259, 259, 259, 259, + /* 1350 */ 259, 259, 259, 259, 259, 259, 259, 259, 259, 259, + /* 1360 */ 259, 259, 259, 259, 259, 259, 259, 259, 259, 259, + /* 1370 */ 259, 259, 259, 259, 259, 259, 259, 259, 259, 259, + /* 1380 */ 259, 259, 259, 259, 259, 259, 259, 259, 259, 259, + /* 1390 */ 259, 259, 259, 259, }; -#define YY_SHIFT_COUNT (429) +#define YY_SHIFT_COUNT (430) #define YY_SHIFT_MIN (0) -#define YY_SHIFT_MAX (1241) +#define YY_SHIFT_MAX (1208) static const unsigned short int yy_shift_ofst[] = { - /* 0 */ 426, 212, 161, 382, 382, 382, 382, 421, 382, 382, - /* 10 */ 151, 513, 517, 444, 513, 513, 513, 513, 513, 513, - /* 20 */ 513, 513, 513, 513, 513, 513, 513, 513, 513, 513, - /* 30 */ 513, 513, 513, 178, 178, 178, 337, 934, 934, 13, - /* 40 */ 13, 934, 13, 13, 66, 17, 229, 229, 72, 319, - /* 50 */ 17, 13, 13, 17, 13, 17, 319, 17, 17, 13, - /* 60 */ 278, 1, 61, 61, 559, 14, 940, 139, 60, 139, - /* 70 */ 139, 139, 139, 139, 139, 139, 139, 139, 139, 139, - /* 80 */ 139, 139, 139, 139, 139, 139, 139, 139, 238, 24, - /* 90 */ 307, 307, 307, 136, 343, 319, 17, 17, 17, 306, - /* 100 */ 56, 56, 56, 56, 56, 68, 503, 534, 90, 215, - /* 110 */ 335, 331, 478, 525, 417, 525, 493, 248, 591, 706, - /* 120 */ 657, 661, 661, 706, 786, 66, 343, 799, 66, 66, - /* 130 */ 706, 66, 831, 17, 17, 17, 17, 17, 17, 17, - /* 140 */ 17, 17, 17, 17, 706, 831, 786, 278, 343, 799, - /* 150 */ 278, 901, 777, 782, 805, 777, 782, 805, 805, 784, - /* 160 */ 791, 813, 815, 821, 343, 941, 850, 806, 820, 817, - /* 170 */ 908, 17, 782, 805, 805, 782, 805, 876, 343, 799, - /* 180 */ 278, 306, 278, 343, 938, 706, 278, 831, 1263, 1263, - /* 190 */ 1263, 1263, 0, 545, 577, 46, 970, 16, 89, 728, - /* 200 */ 406, 757, 301, 301, 301, 301, 301, 301, 301, 115, - /* 210 */ 288, 196, 7, 7, 7, 7, 374, 605, 610, 701, - /* 220 */ 453, 580, 632, 506, 541, 714, 715, 718, 647, 590, - /* 230 */ 451, 729, 74, 749, 758, 763, 787, 795, 797, 803, - /* 240 */ 639, 653, 819, 823, 824, 826, 828, 837, 751, 1032, - /* 250 */ 951, 1034, 1035, 922, 1037, 1038, 1040, 1041, 1043, 1044, - /* 260 */ 1023, 1046, 1047, 1048, 1049, 1050, 1051, 1052, 1010, 1054, - /* 270 */ 1007, 1058, 1059, 1022, 1025, 1019, 1063, 1064, 1065, 1066, - /* 280 */ 988, 991, 1031, 1033, 1053, 1070, 1036, 1039, 1042, 1045, - /* 290 */ 1055, 1056, 1072, 1057, 1073, 1060, 1061, 1076, 1062, 1067, - /* 300 */ 1078, 1068, 1081, 1069, 1075, 1085, 1086, 966, 1088, 1026, - /* 310 */ 1071, 973, 1009, 1014, 957, 1028, 1018, 1074, 1077, 1079, - /* 320 */ 1080, 1082, 1083, 1020, 1024, 1087, 1021, 961, 1084, 1089, - /* 330 */ 1027, 972, 1029, 1090, 1091, 1030, 967, 1106, 1092, 1093, - /* 340 */ 1094, 1095, 1096, 1097, 1109, 989, 1098, 1099, 1101, 1103, - /* 350 */ 1104, 1105, 1107, 1108, 997, 1111, 1117, 1100, 1002, 1112, - /* 360 */ 1110, 1102, 1113, 1114, 1115, 1116, 1118, 1131, 1136, 1132, - /* 370 */ 1133, 1148, 1135, 1137, 1150, 1144, 1146, 1153, 1152, 1155, - /* 380 */ 1156, 1158, 1119, 1134, 1161, 1163, 1170, 1171, 1172, 1173, - /* 390 */ 1174, 1175, 1178, 1176, 1177, 1182, 1179, 1181, 1183, 1185, - /* 400 */ 1186, 1189, 1193, 1195, 1196, 1187, 1198, 1199, 1203, 1210, - /* 410 */ 1214, 1215, 1216, 1218, 1222, 1206, 1207, 1204, 1192, 1232, - /* 420 */ 1223, 1209, 1238, 1239, 1190, 1228, 1229, 1236, 1241, 1191, + /* 0 */ 43, 325, 394, 398, 398, 398, 398, 455, 398, 398, + /* 10 */ 285, 572, 600, 538, 572, 572, 572, 572, 572, 572, + /* 20 */ 572, 572, 572, 572, 572, 572, 572, 572, 572, 572, + /* 30 */ 572, 572, 572, 26, 26, 26, 130, 327, 327, 15, + /* 40 */ 15, 327, 15, 15, 69, 159, 191, 191, 100, 328, + /* 50 */ 159, 15, 15, 159, 15, 159, 328, 159, 159, 15, + /* 60 */ 309, 0, 70, 70, 247, 196, 202, 578, 131, 578, + /* 70 */ 578, 578, 578, 578, 578, 578, 578, 578, 578, 578, + /* 80 */ 578, 578, 578, 578, 578, 578, 578, 578, 294, 380, + /* 90 */ 221, 221, 221, 409, 362, 328, 159, 159, 159, 412, + /* 100 */ 78, 78, 78, 78, 78, 127, 964, 106, 107, 11, + /* 110 */ 40, 289, 240, 167, 290, 167, 420, 506, 418, 729, + /* 120 */ 661, 648, 648, 729, 774, 69, 362, 799, 69, 69, + /* 130 */ 729, 69, 815, 159, 159, 159, 159, 159, 159, 159, + /* 140 */ 159, 159, 159, 159, 729, 815, 774, 309, 362, 799, + /* 150 */ 309, 846, 731, 734, 756, 731, 734, 756, 756, 735, + /* 160 */ 751, 746, 761, 767, 362, 887, 793, 755, 760, 766, + /* 170 */ 854, 159, 734, 756, 756, 734, 756, 818, 362, 799, + /* 180 */ 309, 412, 309, 362, 892, 729, 309, 815, 1230, 1230, + /* 190 */ 1230, 1230, 48, 624, 639, 960, 1038, 443, 472, 444, + /* 200 */ 790, 128, 194, 194, 194, 194, 194, 194, 194, 283, + /* 210 */ 122, 254, 123, 123, 123, 123, 536, 543, 556, 599, + /* 220 */ 643, 647, 657, 605, 514, 608, 609, 423, 482, 603, + /* 230 */ 586, 618, 454, 619, 640, 644, 658, 662, 682, 696, + /* 240 */ 642, 678, 700, 714, 730, 732, 745, 749, 595, 987, + /* 250 */ 908, 994, 995, 882, 998, 1005, 1006, 1007, 1008, 1009, + /* 260 */ 990, 1014, 1016, 1019, 1022, 1025, 1028, 1029, 989, 1033, + /* 270 */ 991, 1040, 1041, 1011, 1010, 1000, 1045, 1047, 1050, 1051, + /* 280 */ 976, 980, 1018, 1021, 1039, 1060, 1027, 1034, 1035, 1037, + /* 290 */ 1042, 1046, 1066, 1054, 1067, 1056, 1044, 1085, 1064, 1049, + /* 300 */ 1088, 1068, 1089, 1069, 1072, 1093, 1094, 973, 1096, 1030, + /* 310 */ 1057, 982, 1020, 1023, 955, 1043, 1026, 1048, 1052, 1053, + /* 320 */ 1055, 1058, 1059, 1032, 1031, 1061, 1062, 961, 1063, 1065, + /* 330 */ 1036, 966, 1070, 1073, 1071, 1074, 967, 1102, 1076, 1077, + /* 340 */ 1080, 1081, 1084, 1087, 1108, 996, 1078, 1075, 1079, 1082, + /* 350 */ 1083, 1090, 1086, 1092, 1013, 1095, 1127, 1098, 1091, 1097, + /* 360 */ 1099, 1100, 1101, 1109, 1103, 1104, 1105, 1107, 1110, 1111, + /* 370 */ 1106, 1118, 1114, 1115, 1119, 1117, 1120, 1123, 1122, 1124, + /* 380 */ 1126, 1128, 1112, 1113, 1116, 1121, 1144, 1129, 1130, 1132, + /* 390 */ 1125, 1133, 1134, 1135, 1148, 1145, 1146, 1141, 1154, 1149, + /* 400 */ 1153, 1157, 1159, 1161, 1162, 1165, 1156, 1166, 1167, 1171, + /* 410 */ 1174, 1175, 1176, 1178, 1179, 1180, 1142, 1181, 1184, 1182, + /* 420 */ 1168, 1183, 1155, 1169, 1172, 1200, 1202, 1204, 1205, 1203, + /* 430 */ 1208, }; #define YY_REDUCE_COUNT (191) -#define YY_REDUCE_MIN (-217) -#define YY_REDUCE_MAX (867) +#define YY_REDUCE_MIN (-205) +#define YY_REDUCE_MAX (850) static const short yy_reduce_ofst[] = { - /* 0 */ -129, -6, 49, 78, 126, 155, 190, 219, 276, 299, - /* 10 */ 135, 375, 398, 434, 492, -80, 497, 515, 520, 562, - /* 20 */ 565, 570, 608, 630, 636, 664, 670, 698, 726, 732, - /* 30 */ 766, 774, 802, 531, 107, 574, -8, -188, -11, 33, - /* 40 */ 93, -206, -166, 205, -171, -27, -108, 174, 69, -122, - /* 50 */ 192, 246, 432, 227, 466, 342, 51, 235, 428, 473, - /* 60 */ 120, -217, -217, -217, -162, -96, -33, 189, 134, 223, - /* 70 */ 233, 279, 280, 281, 304, 314, 315, 390, 424, 460, - /* 80 */ 467, 468, 481, 482, 489, 491, 510, 546, 162, -7, - /* 90 */ 110, 185, 327, 578, 27, 54, 217, 287, 311, -10, - /* 100 */ -178, -140, 204, 312, 345, 268, 412, 347, 381, 446, - /* 110 */ 415, 495, 519, 471, 471, 471, 476, 504, 533, 575, - /* 120 */ 589, 592, 593, 623, 599, 643, 620, 631, 650, 668, - /* 130 */ 666, 671, 676, 673, 679, 683, 686, 689, 690, 693, - /* 140 */ 699, 707, 710, 717, 680, 694, 702, 733, 721, 696, - /* 150 */ 739, 708, 677, 719, 723, 685, 730, 727, 734, 705, - /* 160 */ 695, 722, 716, 471, 765, 748, 738, 713, 735, 731, - /* 170 */ 756, 476, 772, 779, 783, 788, 792, 793, 807, 800, - /* 180 */ 836, 830, 839, 829, 834, 845, 854, 858, 847, 849, - /* 190 */ 857, 867, + /* 0 */ -19, -163, 25, 75, 105, 148, 177, 234, 316, 345, + /* 10 */ 367, -166, 415, 499, 518, 548, 554, 567, 613, 621, + /* 20 */ 649, 655, 677, 705, 711, 724, 753, 759, 772, 781, + /* 30 */ 816, 844, 850, 88, 156, 559, 257, -189, -185, -151, + /* 40 */ -134, -205, -114, -102, 55, 207, -187, -154, -1, -199, + /* 50 */ 53, 112, 134, 246, 205, 102, 84, 287, 286, 314, + /* 60 */ 307, -186, -186, -186, -124, -148, -116, -72, 37, -21, + /* 70 */ 143, 169, 268, 270, 297, 330, 347, 348, 359, 360, + /* 80 */ 361, 364, 395, 419, 421, 424, 429, 438, 45, -96, + /* 90 */ -44, 266, 374, 341, 97, -137, 274, 308, 427, 232, + /* 100 */ -171, 331, 355, 401, 471, 523, 339, 437, 449, 501, + /* 110 */ 469, 544, 511, 495, 495, 495, 546, 494, 509, 577, + /* 120 */ 553, 570, 584, 623, 597, 637, 604, 615, 652, 653, + /* 130 */ 650, 659, 668, 651, 660, 663, 664, 665, 667, 669, + /* 140 */ 671, 673, 674, 675, 672, 679, 634, 683, 676, 681, + /* 150 */ 693, 666, 629, 680, 685, 635, 691, 686, 694, 646, + /* 160 */ 641, 692, 670, 495, 712, 698, 684, 687, 688, 697, + /* 170 */ 703, 546, 725, 727, 728, 741, 743, 748, 744, 747, + /* 180 */ 783, 773, 786, 768, 775, 796, 798, 805, 800, 801, + /* 190 */ 810, 821, }; static const YYACTIONTYPE yy_default[] = { - /* 0 */ 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, - /* 10 */ 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, - /* 20 */ 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, - /* 30 */ 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, - /* 40 */ 999, 999, 999, 999, 1052, 999, 999, 999, 999, 999, - /* 50 */ 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, - /* 60 */ 1050, 999, 1258, 999, 1164, 999, 999, 999, 999, 999, - /* 70 */ 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, - /* 80 */ 999, 999, 999, 999, 999, 999, 999, 999, 999, 1052, - /* 90 */ 1269, 1269, 1269, 1050, 999, 999, 999, 999, 999, 1135, - /* 100 */ 999, 999, 999, 999, 999, 999, 999, 1333, 999, 1088, - /* 110 */ 1293, 999, 1285, 1261, 1275, 1262, 999, 1318, 1278, 999, - /* 120 */ 1169, 1166, 1166, 999, 999, 1052, 999, 999, 1052, 1052, - /* 130 */ 999, 1052, 999, 999, 999, 999, 999, 999, 999, 999, - /* 140 */ 999, 999, 999, 999, 999, 999, 999, 1050, 999, 999, - /* 150 */ 1050, 999, 1300, 1298, 999, 1300, 1298, 999, 999, 1312, - /* 160 */ 1308, 1291, 1289, 1275, 999, 999, 999, 1336, 1324, 1320, - /* 170 */ 999, 999, 1298, 999, 999, 1298, 999, 1177, 999, 999, - /* 180 */ 1050, 999, 1050, 999, 1104, 999, 1050, 999, 1138, 1138, - /* 190 */ 1053, 1004, 999, 999, 999, 999, 999, 999, 999, 999, - /* 200 */ 999, 999, 1230, 1311, 1310, 1229, 1235, 1234, 1233, 999, - /* 210 */ 999, 999, 1224, 1225, 1223, 1222, 999, 999, 999, 999, - /* 220 */ 999, 999, 999, 999, 999, 999, 999, 1259, 999, 1321, - /* 230 */ 1325, 999, 999, 999, 1209, 999, 999, 999, 999, 999, - /* 240 */ 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, - /* 250 */ 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, - /* 260 */ 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, - /* 270 */ 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, - /* 280 */ 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, - /* 290 */ 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, - /* 300 */ 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, - /* 310 */ 999, 999, 1282, 1292, 999, 999, 999, 999, 999, 999, - /* 320 */ 999, 999, 999, 999, 1209, 999, 1309, 999, 1268, 1264, - /* 330 */ 999, 999, 1260, 999, 999, 1319, 999, 999, 999, 999, - /* 340 */ 999, 999, 999, 999, 1254, 999, 999, 999, 999, 999, - /* 350 */ 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, - /* 360 */ 999, 1208, 999, 999, 999, 999, 999, 999, 999, 1132, - /* 370 */ 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, - /* 380 */ 999, 999, 1117, 1115, 1114, 1113, 999, 1110, 999, 999, - /* 390 */ 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, - /* 400 */ 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, - /* 410 */ 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, - /* 420 */ 999, 999, 999, 999, 999, 999, 999, 999, 999, 999, + /* 0 */ 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, + /* 10 */ 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, + /* 20 */ 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, + /* 30 */ 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, + /* 40 */ 1002, 1002, 1002, 1002, 1055, 1002, 1002, 1002, 1002, 1002, + /* 50 */ 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, + /* 60 */ 1053, 1002, 1262, 1002, 1168, 1002, 1002, 1002, 1002, 1002, + /* 70 */ 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, + /* 80 */ 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1055, + /* 90 */ 1273, 1273, 1273, 1053, 1002, 1002, 1002, 1002, 1002, 1137, + /* 100 */ 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1337, 1002, 1090, + /* 110 */ 1297, 1002, 1289, 1265, 1279, 1266, 1002, 1322, 1282, 1002, + /* 120 */ 1173, 1170, 1170, 1002, 1002, 1055, 1002, 1002, 1055, 1055, + /* 130 */ 1002, 1055, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, + /* 140 */ 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1053, 1002, 1002, + /* 150 */ 1053, 1002, 1304, 1302, 1002, 1304, 1302, 1002, 1002, 1316, + /* 160 */ 1312, 1295, 1293, 1279, 1002, 1002, 1002, 1340, 1328, 1324, + /* 170 */ 1002, 1002, 1302, 1002, 1002, 1302, 1002, 1181, 1002, 1002, + /* 180 */ 1053, 1002, 1053, 1002, 1106, 1002, 1053, 1002, 1140, 1140, + /* 190 */ 1056, 1007, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, + /* 200 */ 1002, 1002, 1234, 1315, 1314, 1233, 1239, 1238, 1237, 1002, + /* 210 */ 1002, 1002, 1228, 1229, 1227, 1226, 1002, 1002, 1002, 1002, + /* 220 */ 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1263, 1002, 1325, + /* 230 */ 1329, 1002, 1002, 1002, 1213, 1002, 1002, 1002, 1002, 1002, + /* 240 */ 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, + /* 250 */ 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, + /* 260 */ 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, + /* 270 */ 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, + /* 280 */ 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, + /* 290 */ 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, + /* 300 */ 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, + /* 310 */ 1002, 1002, 1286, 1296, 1002, 1002, 1002, 1002, 1002, 1002, + /* 320 */ 1002, 1002, 1002, 1002, 1213, 1002, 1313, 1002, 1272, 1268, + /* 330 */ 1002, 1002, 1264, 1002, 1002, 1323, 1002, 1002, 1002, 1002, + /* 340 */ 1002, 1002, 1002, 1002, 1258, 1002, 1002, 1002, 1002, 1002, + /* 350 */ 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, + /* 360 */ 1002, 1212, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1134, + /* 370 */ 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, + /* 380 */ 1002, 1002, 1119, 1117, 1116, 1115, 1002, 1112, 1002, 1002, + /* 390 */ 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, + /* 400 */ 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, + /* 410 */ 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, + /* 420 */ 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, 1002, + /* 430 */ 1002, }; /********** End of lemon-generated parsing tables *****************************/ @@ -773,197 +768,198 @@ static const char *const yyTokenName[] = { /* 64 */ "SINGLE_STABLE", /* 65 */ "STREAM_MODE", /* 66 */ "RETENTIONS", - /* 67 */ "FILE_FACTOR", - /* 68 */ "NK_FLOAT", - /* 69 */ "TABLE", - /* 70 */ "NK_LP", - /* 71 */ "NK_RP", - /* 72 */ "STABLE", - /* 73 */ "ADD", - /* 74 */ "COLUMN", - /* 75 */ "MODIFY", - /* 76 */ "RENAME", - /* 77 */ "TAG", - /* 78 */ "SET", - /* 79 */ "NK_EQ", - /* 80 */ "USING", - /* 81 */ "TAGS", - /* 82 */ "NK_DOT", - /* 83 */ "NK_COMMA", - /* 84 */ "COMMENT", - /* 85 */ "BOOL", - /* 86 */ "TINYINT", - /* 87 */ "SMALLINT", - /* 88 */ "INT", - /* 89 */ "INTEGER", - /* 90 */ "BIGINT", - /* 91 */ "FLOAT", - /* 92 */ "DOUBLE", - /* 93 */ "BINARY", - /* 94 */ "TIMESTAMP", - /* 95 */ "NCHAR", - /* 96 */ "UNSIGNED", - /* 97 */ "JSON", - /* 98 */ "VARCHAR", - /* 99 */ "MEDIUMBLOB", - /* 100 */ "BLOB", - /* 101 */ "VARBINARY", - /* 102 */ "DECIMAL", - /* 103 */ "SMA", - /* 104 */ "ROLLUP", - /* 105 */ "SHOW", - /* 106 */ "DATABASES", - /* 107 */ "TABLES", - /* 108 */ "STABLES", - /* 109 */ "MNODES", - /* 110 */ "MODULES", - /* 111 */ "QNODES", - /* 112 */ "FUNCTIONS", - /* 113 */ "INDEXES", - /* 114 */ "FROM", - /* 115 */ "LIKE", - /* 116 */ "INDEX", - /* 117 */ "FULLTEXT", - /* 118 */ "FUNCTION", - /* 119 */ "INTERVAL", - /* 120 */ "TOPIC", - /* 121 */ "AS", - /* 122 */ "NK_BOOL", - /* 123 */ "NK_VARIABLE", - /* 124 */ "BETWEEN", - /* 125 */ "IS", - /* 126 */ "NULL", - /* 127 */ "NK_LT", - /* 128 */ "NK_GT", - /* 129 */ "NK_LE", - /* 130 */ "NK_GE", - /* 131 */ "NK_NE", - /* 132 */ "MATCH", - /* 133 */ "NMATCH", - /* 134 */ "IN", - /* 135 */ "JOIN", - /* 136 */ "INNER", - /* 137 */ "SELECT", - /* 138 */ "DISTINCT", - /* 139 */ "WHERE", - /* 140 */ "PARTITION", - /* 141 */ "BY", - /* 142 */ "SESSION", - /* 143 */ "STATE_WINDOW", - /* 144 */ "SLIDING", - /* 145 */ "FILL", - /* 146 */ "VALUE", - /* 147 */ "NONE", - /* 148 */ "PREV", - /* 149 */ "LINEAR", - /* 150 */ "NEXT", - /* 151 */ "GROUP", - /* 152 */ "HAVING", - /* 153 */ "ORDER", - /* 154 */ "SLIMIT", - /* 155 */ "SOFFSET", - /* 156 */ "LIMIT", - /* 157 */ "OFFSET", - /* 158 */ "ASC", - /* 159 */ "DESC", - /* 160 */ "NULLS", - /* 161 */ "FIRST", - /* 162 */ "LAST", - /* 163 */ "cmd", - /* 164 */ "account_options", - /* 165 */ "alter_account_options", - /* 166 */ "literal", - /* 167 */ "alter_account_option", - /* 168 */ "user_name", - /* 169 */ "dnode_endpoint", - /* 170 */ "dnode_host_name", - /* 171 */ "not_exists_opt", - /* 172 */ "db_name", - /* 173 */ "db_options", - /* 174 */ "exists_opt", - /* 175 */ "alter_db_options", - /* 176 */ "alter_db_option", - /* 177 */ "full_table_name", - /* 178 */ "column_def_list", - /* 179 */ "tags_def_opt", - /* 180 */ "table_options", - /* 181 */ "multi_create_clause", - /* 182 */ "tags_def", - /* 183 */ "multi_drop_clause", - /* 184 */ "alter_table_clause", - /* 185 */ "alter_table_options", - /* 186 */ "column_name", - /* 187 */ "type_name", - /* 188 */ "create_subtable_clause", - /* 189 */ "specific_tags_opt", - /* 190 */ "literal_list", - /* 191 */ "drop_table_clause", - /* 192 */ "col_name_list", - /* 193 */ "table_name", - /* 194 */ "column_def", - /* 195 */ "func_name_list", - /* 196 */ "alter_table_option", - /* 197 */ "col_name", - /* 198 */ "db_name_cond_opt", - /* 199 */ "like_pattern_opt", - /* 200 */ "table_name_cond", - /* 201 */ "from_db_opt", - /* 202 */ "func_name", - /* 203 */ "function_name", - /* 204 */ "index_name", - /* 205 */ "index_options", - /* 206 */ "func_list", - /* 207 */ "duration_literal", - /* 208 */ "sliding_opt", - /* 209 */ "func", - /* 210 */ "expression_list", - /* 211 */ "topic_name", - /* 212 */ "query_expression", - /* 213 */ "signed", - /* 214 */ "signed_literal", - /* 215 */ "table_alias", - /* 216 */ "column_alias", - /* 217 */ "expression", - /* 218 */ "column_reference", - /* 219 */ "subquery", - /* 220 */ "predicate", - /* 221 */ "compare_op", - /* 222 */ "in_op", - /* 223 */ "in_predicate_value", - /* 224 */ "boolean_value_expression", - /* 225 */ "boolean_primary", - /* 226 */ "common_expression", - /* 227 */ "from_clause", - /* 228 */ "table_reference_list", - /* 229 */ "table_reference", - /* 230 */ "table_primary", - /* 231 */ "joined_table", - /* 232 */ "alias_opt", - /* 233 */ "parenthesized_joined_table", - /* 234 */ "join_type", - /* 235 */ "search_condition", - /* 236 */ "query_specification", - /* 237 */ "set_quantifier_opt", - /* 238 */ "select_list", - /* 239 */ "where_clause_opt", - /* 240 */ "partition_by_clause_opt", - /* 241 */ "twindow_clause_opt", - /* 242 */ "group_by_clause_opt", - /* 243 */ "having_clause_opt", - /* 244 */ "select_sublist", - /* 245 */ "select_item", - /* 246 */ "fill_opt", - /* 247 */ "fill_mode", - /* 248 */ "group_by_list", - /* 249 */ "query_expression_body", - /* 250 */ "order_by_clause_opt", - /* 251 */ "slimit_clause_opt", - /* 252 */ "limit_clause_opt", - /* 253 */ "query_primary", - /* 254 */ "sort_specification_list", - /* 255 */ "sort_specification", - /* 256 */ "ordering_specification_opt", - /* 257 */ "null_ordering_opt", + /* 67 */ "TABLE", + /* 68 */ "NK_LP", + /* 69 */ "NK_RP", + /* 70 */ "STABLE", + /* 71 */ "ADD", + /* 72 */ "COLUMN", + /* 73 */ "MODIFY", + /* 74 */ "RENAME", + /* 75 */ "TAG", + /* 76 */ "SET", + /* 77 */ "NK_EQ", + /* 78 */ "USING", + /* 79 */ "TAGS", + /* 80 */ "NK_DOT", + /* 81 */ "NK_COMMA", + /* 82 */ "COMMENT", + /* 83 */ "BOOL", + /* 84 */ "TINYINT", + /* 85 */ "SMALLINT", + /* 86 */ "INT", + /* 87 */ "INTEGER", + /* 88 */ "BIGINT", + /* 89 */ "FLOAT", + /* 90 */ "DOUBLE", + /* 91 */ "BINARY", + /* 92 */ "TIMESTAMP", + /* 93 */ "NCHAR", + /* 94 */ "UNSIGNED", + /* 95 */ "JSON", + /* 96 */ "VARCHAR", + /* 97 */ "MEDIUMBLOB", + /* 98 */ "BLOB", + /* 99 */ "VARBINARY", + /* 100 */ "DECIMAL", + /* 101 */ "SMA", + /* 102 */ "ROLLUP", + /* 103 */ "FILE_FACTOR", + /* 104 */ "NK_FLOAT", + /* 105 */ "DELAY", + /* 106 */ "SHOW", + /* 107 */ "DATABASES", + /* 108 */ "TABLES", + /* 109 */ "STABLES", + /* 110 */ "MNODES", + /* 111 */ "MODULES", + /* 112 */ "QNODES", + /* 113 */ "FUNCTIONS", + /* 114 */ "INDEXES", + /* 115 */ "FROM", + /* 116 */ "LIKE", + /* 117 */ "INDEX", + /* 118 */ "FULLTEXT", + /* 119 */ "FUNCTION", + /* 120 */ "INTERVAL", + /* 121 */ "TOPIC", + /* 122 */ "AS", + /* 123 */ "NK_BOOL", + /* 124 */ "NK_VARIABLE", + /* 125 */ "BETWEEN", + /* 126 */ "IS", + /* 127 */ "NULL", + /* 128 */ "NK_LT", + /* 129 */ "NK_GT", + /* 130 */ "NK_LE", + /* 131 */ "NK_GE", + /* 132 */ "NK_NE", + /* 133 */ "MATCH", + /* 134 */ "NMATCH", + /* 135 */ "IN", + /* 136 */ "JOIN", + /* 137 */ "INNER", + /* 138 */ "SELECT", + /* 139 */ "DISTINCT", + /* 140 */ "WHERE", + /* 141 */ "PARTITION", + /* 142 */ "BY", + /* 143 */ "SESSION", + /* 144 */ "STATE_WINDOW", + /* 145 */ "SLIDING", + /* 146 */ "FILL", + /* 147 */ "VALUE", + /* 148 */ "NONE", + /* 149 */ "PREV", + /* 150 */ "LINEAR", + /* 151 */ "NEXT", + /* 152 */ "GROUP", + /* 153 */ "HAVING", + /* 154 */ "ORDER", + /* 155 */ "SLIMIT", + /* 156 */ "SOFFSET", + /* 157 */ "LIMIT", + /* 158 */ "OFFSET", + /* 159 */ "ASC", + /* 160 */ "DESC", + /* 161 */ "NULLS", + /* 162 */ "FIRST", + /* 163 */ "LAST", + /* 164 */ "cmd", + /* 165 */ "account_options", + /* 166 */ "alter_account_options", + /* 167 */ "literal", + /* 168 */ "alter_account_option", + /* 169 */ "user_name", + /* 170 */ "dnode_endpoint", + /* 171 */ "dnode_host_name", + /* 172 */ "not_exists_opt", + /* 173 */ "db_name", + /* 174 */ "db_options", + /* 175 */ "exists_opt", + /* 176 */ "alter_db_options", + /* 177 */ "alter_db_option", + /* 178 */ "full_table_name", + /* 179 */ "column_def_list", + /* 180 */ "tags_def_opt", + /* 181 */ "table_options", + /* 182 */ "multi_create_clause", + /* 183 */ "tags_def", + /* 184 */ "multi_drop_clause", + /* 185 */ "alter_table_clause", + /* 186 */ "alter_table_options", + /* 187 */ "column_name", + /* 188 */ "type_name", + /* 189 */ "create_subtable_clause", + /* 190 */ "specific_tags_opt", + /* 191 */ "literal_list", + /* 192 */ "drop_table_clause", + /* 193 */ "col_name_list", + /* 194 */ "table_name", + /* 195 */ "column_def", + /* 196 */ "func_name_list", + /* 197 */ "alter_table_option", + /* 198 */ "col_name", + /* 199 */ "db_name_cond_opt", + /* 200 */ "like_pattern_opt", + /* 201 */ "table_name_cond", + /* 202 */ "from_db_opt", + /* 203 */ "func_name", + /* 204 */ "function_name", + /* 205 */ "index_name", + /* 206 */ "index_options", + /* 207 */ "func_list", + /* 208 */ "duration_literal", + /* 209 */ "sliding_opt", + /* 210 */ "func", + /* 211 */ "expression_list", + /* 212 */ "topic_name", + /* 213 */ "query_expression", + /* 214 */ "signed", + /* 215 */ "signed_literal", + /* 216 */ "table_alias", + /* 217 */ "column_alias", + /* 218 */ "expression", + /* 219 */ "column_reference", + /* 220 */ "subquery", + /* 221 */ "predicate", + /* 222 */ "compare_op", + /* 223 */ "in_op", + /* 224 */ "in_predicate_value", + /* 225 */ "boolean_value_expression", + /* 226 */ "boolean_primary", + /* 227 */ "common_expression", + /* 228 */ "from_clause", + /* 229 */ "table_reference_list", + /* 230 */ "table_reference", + /* 231 */ "table_primary", + /* 232 */ "joined_table", + /* 233 */ "alias_opt", + /* 234 */ "parenthesized_joined_table", + /* 235 */ "join_type", + /* 236 */ "search_condition", + /* 237 */ "query_specification", + /* 238 */ "set_quantifier_opt", + /* 239 */ "select_list", + /* 240 */ "where_clause_opt", + /* 241 */ "partition_by_clause_opt", + /* 242 */ "twindow_clause_opt", + /* 243 */ "group_by_clause_opt", + /* 244 */ "having_clause_opt", + /* 245 */ "select_sublist", + /* 246 */ "select_item", + /* 247 */ "fill_opt", + /* 248 */ "fill_mode", + /* 249 */ "group_by_list", + /* 250 */ "query_expression_body", + /* 251 */ "order_by_clause_opt", + /* 252 */ "slimit_clause_opt", + /* 253 */ "limit_clause_opt", + /* 254 */ "query_primary", + /* 255 */ "sort_specification_list", + /* 256 */ "sort_specification", + /* 257 */ "ordering_specification_opt", + /* 258 */ "null_ordering_opt", }; #endif /* defined(YYCOVERAGE) || !defined(NDEBUG) */ @@ -1041,273 +1037,274 @@ static const char *const yyRuleName[] = { /* 67 */ "db_options ::= db_options SINGLE_STABLE NK_INTEGER", /* 68 */ "db_options ::= db_options STREAM_MODE NK_INTEGER", /* 69 */ "db_options ::= db_options RETENTIONS NK_STRING", - /* 70 */ "db_options ::= db_options FILE_FACTOR NK_FLOAT", - /* 71 */ "alter_db_options ::= alter_db_option", - /* 72 */ "alter_db_options ::= alter_db_options alter_db_option", - /* 73 */ "alter_db_option ::= BLOCKS NK_INTEGER", - /* 74 */ "alter_db_option ::= FSYNC NK_INTEGER", - /* 75 */ "alter_db_option ::= KEEP NK_INTEGER", - /* 76 */ "alter_db_option ::= WAL NK_INTEGER", - /* 77 */ "alter_db_option ::= QUORUM NK_INTEGER", - /* 78 */ "alter_db_option ::= CACHELAST NK_INTEGER", - /* 79 */ "cmd ::= CREATE TABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def_opt table_options", - /* 80 */ "cmd ::= CREATE TABLE multi_create_clause", - /* 81 */ "cmd ::= CREATE STABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def table_options", - /* 82 */ "cmd ::= DROP TABLE multi_drop_clause", - /* 83 */ "cmd ::= DROP STABLE exists_opt full_table_name", - /* 84 */ "cmd ::= ALTER TABLE alter_table_clause", - /* 85 */ "cmd ::= ALTER STABLE alter_table_clause", - /* 86 */ "alter_table_clause ::= full_table_name alter_table_options", - /* 87 */ "alter_table_clause ::= full_table_name ADD COLUMN column_name type_name", - /* 88 */ "alter_table_clause ::= full_table_name DROP COLUMN column_name", - /* 89 */ "alter_table_clause ::= full_table_name MODIFY COLUMN column_name type_name", - /* 90 */ "alter_table_clause ::= full_table_name RENAME COLUMN column_name column_name", - /* 91 */ "alter_table_clause ::= full_table_name ADD TAG column_name type_name", - /* 92 */ "alter_table_clause ::= full_table_name DROP TAG column_name", - /* 93 */ "alter_table_clause ::= full_table_name MODIFY TAG column_name type_name", - /* 94 */ "alter_table_clause ::= full_table_name RENAME TAG column_name column_name", - /* 95 */ "alter_table_clause ::= full_table_name SET TAG column_name NK_EQ literal", - /* 96 */ "multi_create_clause ::= create_subtable_clause", - /* 97 */ "multi_create_clause ::= multi_create_clause create_subtable_clause", - /* 98 */ "create_subtable_clause ::= not_exists_opt full_table_name USING full_table_name specific_tags_opt TAGS NK_LP literal_list NK_RP", - /* 99 */ "multi_drop_clause ::= drop_table_clause", - /* 100 */ "multi_drop_clause ::= multi_drop_clause drop_table_clause", - /* 101 */ "drop_table_clause ::= exists_opt full_table_name", - /* 102 */ "specific_tags_opt ::=", - /* 103 */ "specific_tags_opt ::= NK_LP col_name_list NK_RP", - /* 104 */ "full_table_name ::= table_name", - /* 105 */ "full_table_name ::= db_name NK_DOT table_name", - /* 106 */ "column_def_list ::= column_def", - /* 107 */ "column_def_list ::= column_def_list NK_COMMA column_def", - /* 108 */ "column_def ::= column_name type_name", - /* 109 */ "column_def ::= column_name type_name COMMENT NK_STRING", - /* 110 */ "type_name ::= BOOL", - /* 111 */ "type_name ::= TINYINT", - /* 112 */ "type_name ::= SMALLINT", - /* 113 */ "type_name ::= INT", - /* 114 */ "type_name ::= INTEGER", - /* 115 */ "type_name ::= BIGINT", - /* 116 */ "type_name ::= FLOAT", - /* 117 */ "type_name ::= DOUBLE", - /* 118 */ "type_name ::= BINARY NK_LP NK_INTEGER NK_RP", - /* 119 */ "type_name ::= TIMESTAMP", - /* 120 */ "type_name ::= NCHAR NK_LP NK_INTEGER NK_RP", - /* 121 */ "type_name ::= TINYINT UNSIGNED", - /* 122 */ "type_name ::= SMALLINT UNSIGNED", - /* 123 */ "type_name ::= INT UNSIGNED", - /* 124 */ "type_name ::= BIGINT UNSIGNED", - /* 125 */ "type_name ::= JSON", - /* 126 */ "type_name ::= VARCHAR NK_LP NK_INTEGER NK_RP", - /* 127 */ "type_name ::= MEDIUMBLOB", - /* 128 */ "type_name ::= BLOB", - /* 129 */ "type_name ::= VARBINARY NK_LP NK_INTEGER NK_RP", - /* 130 */ "type_name ::= DECIMAL", - /* 131 */ "type_name ::= DECIMAL NK_LP NK_INTEGER NK_RP", - /* 132 */ "type_name ::= DECIMAL NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP", - /* 133 */ "tags_def_opt ::=", - /* 134 */ "tags_def_opt ::= tags_def", - /* 135 */ "tags_def ::= TAGS NK_LP column_def_list NK_RP", - /* 136 */ "table_options ::=", - /* 137 */ "table_options ::= table_options COMMENT NK_STRING", - /* 138 */ "table_options ::= table_options KEEP NK_INTEGER", - /* 139 */ "table_options ::= table_options TTL NK_INTEGER", - /* 140 */ "table_options ::= table_options SMA NK_LP col_name_list NK_RP", - /* 141 */ "table_options ::= table_options ROLLUP NK_LP func_name_list NK_RP", - /* 142 */ "alter_table_options ::= alter_table_option", - /* 143 */ "alter_table_options ::= alter_table_options alter_table_option", - /* 144 */ "alter_table_option ::= COMMENT NK_STRING", - /* 145 */ "alter_table_option ::= KEEP NK_INTEGER", - /* 146 */ "alter_table_option ::= TTL NK_INTEGER", - /* 147 */ "col_name_list ::= col_name", - /* 148 */ "col_name_list ::= col_name_list NK_COMMA col_name", - /* 149 */ "col_name ::= column_name", - /* 150 */ "cmd ::= SHOW DNODES", - /* 151 */ "cmd ::= SHOW USERS", - /* 152 */ "cmd ::= SHOW DATABASES", - /* 153 */ "cmd ::= SHOW db_name_cond_opt TABLES like_pattern_opt", - /* 154 */ "cmd ::= SHOW db_name_cond_opt STABLES like_pattern_opt", - /* 155 */ "cmd ::= SHOW db_name_cond_opt VGROUPS", - /* 156 */ "cmd ::= SHOW MNODES", - /* 157 */ "cmd ::= SHOW MODULES", - /* 158 */ "cmd ::= SHOW QNODES", - /* 159 */ "cmd ::= SHOW FUNCTIONS", - /* 160 */ "cmd ::= SHOW INDEXES FROM table_name_cond from_db_opt", - /* 161 */ "cmd ::= SHOW STREAMS", - /* 162 */ "db_name_cond_opt ::=", - /* 163 */ "db_name_cond_opt ::= db_name NK_DOT", - /* 164 */ "like_pattern_opt ::=", - /* 165 */ "like_pattern_opt ::= LIKE NK_STRING", - /* 166 */ "table_name_cond ::= table_name", - /* 167 */ "from_db_opt ::=", - /* 168 */ "from_db_opt ::= FROM db_name", - /* 169 */ "func_name_list ::= func_name", - /* 170 */ "func_name_list ::= func_name_list NK_COMMA col_name", - /* 171 */ "func_name ::= function_name", - /* 172 */ "cmd ::= CREATE SMA INDEX not_exists_opt index_name ON table_name index_options", - /* 173 */ "cmd ::= CREATE FULLTEXT INDEX not_exists_opt index_name ON table_name NK_LP col_name_list NK_RP", - /* 174 */ "cmd ::= DROP INDEX exists_opt index_name ON table_name", - /* 175 */ "index_options ::=", - /* 176 */ "index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_RP sliding_opt", - /* 177 */ "index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt", - /* 178 */ "func_list ::= func", - /* 179 */ "func_list ::= func_list NK_COMMA func", - /* 180 */ "func ::= function_name NK_LP expression_list NK_RP", - /* 181 */ "cmd ::= CREATE TOPIC not_exists_opt topic_name AS query_expression", - /* 182 */ "cmd ::= CREATE TOPIC not_exists_opt topic_name AS db_name", - /* 183 */ "cmd ::= DROP TOPIC exists_opt topic_name", - /* 184 */ "cmd ::= query_expression", - /* 185 */ "literal ::= NK_INTEGER", - /* 186 */ "literal ::= NK_FLOAT", - /* 187 */ "literal ::= NK_STRING", - /* 188 */ "literal ::= NK_BOOL", - /* 189 */ "literal ::= TIMESTAMP NK_STRING", - /* 190 */ "literal ::= duration_literal", - /* 191 */ "duration_literal ::= NK_VARIABLE", - /* 192 */ "signed ::= NK_INTEGER", - /* 193 */ "signed ::= NK_PLUS NK_INTEGER", - /* 194 */ "signed ::= NK_MINUS NK_INTEGER", - /* 195 */ "signed ::= NK_FLOAT", - /* 196 */ "signed ::= NK_PLUS NK_FLOAT", - /* 197 */ "signed ::= NK_MINUS NK_FLOAT", - /* 198 */ "signed_literal ::= signed", - /* 199 */ "signed_literal ::= NK_STRING", - /* 200 */ "signed_literal ::= NK_BOOL", - /* 201 */ "signed_literal ::= TIMESTAMP NK_STRING", - /* 202 */ "signed_literal ::= duration_literal", - /* 203 */ "literal_list ::= signed_literal", - /* 204 */ "literal_list ::= literal_list NK_COMMA signed_literal", - /* 205 */ "db_name ::= NK_ID", - /* 206 */ "table_name ::= NK_ID", - /* 207 */ "column_name ::= NK_ID", - /* 208 */ "function_name ::= NK_ID", - /* 209 */ "table_alias ::= NK_ID", - /* 210 */ "column_alias ::= NK_ID", - /* 211 */ "user_name ::= NK_ID", - /* 212 */ "index_name ::= NK_ID", - /* 213 */ "topic_name ::= NK_ID", - /* 214 */ "expression ::= literal", - /* 215 */ "expression ::= column_reference", - /* 216 */ "expression ::= function_name NK_LP expression_list NK_RP", - /* 217 */ "expression ::= function_name NK_LP NK_STAR NK_RP", - /* 218 */ "expression ::= subquery", - /* 219 */ "expression ::= NK_LP expression NK_RP", - /* 220 */ "expression ::= NK_PLUS expression", - /* 221 */ "expression ::= NK_MINUS expression", - /* 222 */ "expression ::= expression NK_PLUS expression", - /* 223 */ "expression ::= expression NK_MINUS expression", - /* 224 */ "expression ::= expression NK_STAR expression", - /* 225 */ "expression ::= expression NK_SLASH expression", - /* 226 */ "expression ::= expression NK_REM expression", - /* 227 */ "expression_list ::= expression", - /* 228 */ "expression_list ::= expression_list NK_COMMA expression", - /* 229 */ "column_reference ::= column_name", - /* 230 */ "column_reference ::= table_name NK_DOT column_name", - /* 231 */ "predicate ::= expression compare_op expression", - /* 232 */ "predicate ::= expression BETWEEN expression AND expression", - /* 233 */ "predicate ::= expression NOT BETWEEN expression AND expression", - /* 234 */ "predicate ::= expression IS NULL", - /* 235 */ "predicate ::= expression IS NOT NULL", - /* 236 */ "predicate ::= expression in_op in_predicate_value", - /* 237 */ "compare_op ::= NK_LT", - /* 238 */ "compare_op ::= NK_GT", - /* 239 */ "compare_op ::= NK_LE", - /* 240 */ "compare_op ::= NK_GE", - /* 241 */ "compare_op ::= NK_NE", - /* 242 */ "compare_op ::= NK_EQ", - /* 243 */ "compare_op ::= LIKE", - /* 244 */ "compare_op ::= NOT LIKE", - /* 245 */ "compare_op ::= MATCH", - /* 246 */ "compare_op ::= NMATCH", - /* 247 */ "in_op ::= IN", - /* 248 */ "in_op ::= NOT IN", - /* 249 */ "in_predicate_value ::= NK_LP expression_list NK_RP", - /* 250 */ "boolean_value_expression ::= boolean_primary", - /* 251 */ "boolean_value_expression ::= NOT boolean_primary", - /* 252 */ "boolean_value_expression ::= boolean_value_expression OR boolean_value_expression", - /* 253 */ "boolean_value_expression ::= boolean_value_expression AND boolean_value_expression", - /* 254 */ "boolean_primary ::= predicate", - /* 255 */ "boolean_primary ::= NK_LP boolean_value_expression NK_RP", - /* 256 */ "common_expression ::= expression", - /* 257 */ "common_expression ::= boolean_value_expression", - /* 258 */ "from_clause ::= FROM table_reference_list", - /* 259 */ "table_reference_list ::= table_reference", - /* 260 */ "table_reference_list ::= table_reference_list NK_COMMA table_reference", - /* 261 */ "table_reference ::= table_primary", - /* 262 */ "table_reference ::= joined_table", - /* 263 */ "table_primary ::= table_name alias_opt", - /* 264 */ "table_primary ::= db_name NK_DOT table_name alias_opt", - /* 265 */ "table_primary ::= subquery alias_opt", - /* 266 */ "table_primary ::= parenthesized_joined_table", - /* 267 */ "alias_opt ::=", - /* 268 */ "alias_opt ::= table_alias", - /* 269 */ "alias_opt ::= AS table_alias", - /* 270 */ "parenthesized_joined_table ::= NK_LP joined_table NK_RP", - /* 271 */ "parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP", - /* 272 */ "joined_table ::= table_reference join_type JOIN table_reference ON search_condition", - /* 273 */ "join_type ::=", - /* 274 */ "join_type ::= INNER", - /* 275 */ "query_specification ::= SELECT set_quantifier_opt select_list from_clause where_clause_opt partition_by_clause_opt twindow_clause_opt group_by_clause_opt having_clause_opt", - /* 276 */ "set_quantifier_opt ::=", - /* 277 */ "set_quantifier_opt ::= DISTINCT", - /* 278 */ "set_quantifier_opt ::= ALL", - /* 279 */ "select_list ::= NK_STAR", - /* 280 */ "select_list ::= select_sublist", - /* 281 */ "select_sublist ::= select_item", - /* 282 */ "select_sublist ::= select_sublist NK_COMMA select_item", - /* 283 */ "select_item ::= common_expression", - /* 284 */ "select_item ::= common_expression column_alias", - /* 285 */ "select_item ::= common_expression AS column_alias", - /* 286 */ "select_item ::= table_name NK_DOT NK_STAR", - /* 287 */ "where_clause_opt ::=", - /* 288 */ "where_clause_opt ::= WHERE search_condition", - /* 289 */ "partition_by_clause_opt ::=", - /* 290 */ "partition_by_clause_opt ::= PARTITION BY expression_list", - /* 291 */ "twindow_clause_opt ::=", - /* 292 */ "twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA duration_literal NK_RP", - /* 293 */ "twindow_clause_opt ::= STATE_WINDOW NK_LP column_reference NK_RP", - /* 294 */ "twindow_clause_opt ::= INTERVAL NK_LP duration_literal NK_RP sliding_opt fill_opt", - /* 295 */ "twindow_clause_opt ::= INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt fill_opt", - /* 296 */ "sliding_opt ::=", - /* 297 */ "sliding_opt ::= SLIDING NK_LP duration_literal NK_RP", - /* 298 */ "fill_opt ::=", - /* 299 */ "fill_opt ::= FILL NK_LP fill_mode NK_RP", - /* 300 */ "fill_opt ::= FILL NK_LP VALUE NK_COMMA literal_list NK_RP", - /* 301 */ "fill_mode ::= NONE", - /* 302 */ "fill_mode ::= PREV", - /* 303 */ "fill_mode ::= NULL", - /* 304 */ "fill_mode ::= LINEAR", - /* 305 */ "fill_mode ::= NEXT", - /* 306 */ "group_by_clause_opt ::=", - /* 307 */ "group_by_clause_opt ::= GROUP BY group_by_list", - /* 308 */ "group_by_list ::= expression", - /* 309 */ "group_by_list ::= group_by_list NK_COMMA expression", - /* 310 */ "having_clause_opt ::=", - /* 311 */ "having_clause_opt ::= HAVING search_condition", - /* 312 */ "query_expression ::= query_expression_body order_by_clause_opt slimit_clause_opt limit_clause_opt", - /* 313 */ "query_expression_body ::= query_primary", - /* 314 */ "query_expression_body ::= query_expression_body UNION ALL query_expression_body", - /* 315 */ "query_primary ::= query_specification", - /* 316 */ "order_by_clause_opt ::=", - /* 317 */ "order_by_clause_opt ::= ORDER BY sort_specification_list", - /* 318 */ "slimit_clause_opt ::=", - /* 319 */ "slimit_clause_opt ::= SLIMIT NK_INTEGER", - /* 320 */ "slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER", - /* 321 */ "slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER", - /* 322 */ "limit_clause_opt ::=", - /* 323 */ "limit_clause_opt ::= LIMIT NK_INTEGER", - /* 324 */ "limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER", - /* 325 */ "limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER", - /* 326 */ "subquery ::= NK_LP query_expression NK_RP", - /* 327 */ "search_condition ::= common_expression", - /* 328 */ "sort_specification_list ::= sort_specification", - /* 329 */ "sort_specification_list ::= sort_specification_list NK_COMMA sort_specification", - /* 330 */ "sort_specification ::= expression ordering_specification_opt null_ordering_opt", - /* 331 */ "ordering_specification_opt ::=", - /* 332 */ "ordering_specification_opt ::= ASC", - /* 333 */ "ordering_specification_opt ::= DESC", - /* 334 */ "null_ordering_opt ::=", - /* 335 */ "null_ordering_opt ::= NULLS FIRST", - /* 336 */ "null_ordering_opt ::= NULLS LAST", + /* 70 */ "alter_db_options ::= alter_db_option", + /* 71 */ "alter_db_options ::= alter_db_options alter_db_option", + /* 72 */ "alter_db_option ::= BLOCKS NK_INTEGER", + /* 73 */ "alter_db_option ::= FSYNC NK_INTEGER", + /* 74 */ "alter_db_option ::= KEEP NK_INTEGER", + /* 75 */ "alter_db_option ::= WAL NK_INTEGER", + /* 76 */ "alter_db_option ::= QUORUM NK_INTEGER", + /* 77 */ "alter_db_option ::= CACHELAST NK_INTEGER", + /* 78 */ "cmd ::= CREATE TABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def_opt table_options", + /* 79 */ "cmd ::= CREATE TABLE multi_create_clause", + /* 80 */ "cmd ::= CREATE STABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def table_options", + /* 81 */ "cmd ::= DROP TABLE multi_drop_clause", + /* 82 */ "cmd ::= DROP STABLE exists_opt full_table_name", + /* 83 */ "cmd ::= ALTER TABLE alter_table_clause", + /* 84 */ "cmd ::= ALTER STABLE alter_table_clause", + /* 85 */ "alter_table_clause ::= full_table_name alter_table_options", + /* 86 */ "alter_table_clause ::= full_table_name ADD COLUMN column_name type_name", + /* 87 */ "alter_table_clause ::= full_table_name DROP COLUMN column_name", + /* 88 */ "alter_table_clause ::= full_table_name MODIFY COLUMN column_name type_name", + /* 89 */ "alter_table_clause ::= full_table_name RENAME COLUMN column_name column_name", + /* 90 */ "alter_table_clause ::= full_table_name ADD TAG column_name type_name", + /* 91 */ "alter_table_clause ::= full_table_name DROP TAG column_name", + /* 92 */ "alter_table_clause ::= full_table_name MODIFY TAG column_name type_name", + /* 93 */ "alter_table_clause ::= full_table_name RENAME TAG column_name column_name", + /* 94 */ "alter_table_clause ::= full_table_name SET TAG column_name NK_EQ literal", + /* 95 */ "multi_create_clause ::= create_subtable_clause", + /* 96 */ "multi_create_clause ::= multi_create_clause create_subtable_clause", + /* 97 */ "create_subtable_clause ::= not_exists_opt full_table_name USING full_table_name specific_tags_opt TAGS NK_LP literal_list NK_RP", + /* 98 */ "multi_drop_clause ::= drop_table_clause", + /* 99 */ "multi_drop_clause ::= multi_drop_clause drop_table_clause", + /* 100 */ "drop_table_clause ::= exists_opt full_table_name", + /* 101 */ "specific_tags_opt ::=", + /* 102 */ "specific_tags_opt ::= NK_LP col_name_list NK_RP", + /* 103 */ "full_table_name ::= table_name", + /* 104 */ "full_table_name ::= db_name NK_DOT table_name", + /* 105 */ "column_def_list ::= column_def", + /* 106 */ "column_def_list ::= column_def_list NK_COMMA column_def", + /* 107 */ "column_def ::= column_name type_name", + /* 108 */ "column_def ::= column_name type_name COMMENT NK_STRING", + /* 109 */ "type_name ::= BOOL", + /* 110 */ "type_name ::= TINYINT", + /* 111 */ "type_name ::= SMALLINT", + /* 112 */ "type_name ::= INT", + /* 113 */ "type_name ::= INTEGER", + /* 114 */ "type_name ::= BIGINT", + /* 115 */ "type_name ::= FLOAT", + /* 116 */ "type_name ::= DOUBLE", + /* 117 */ "type_name ::= BINARY NK_LP NK_INTEGER NK_RP", + /* 118 */ "type_name ::= TIMESTAMP", + /* 119 */ "type_name ::= NCHAR NK_LP NK_INTEGER NK_RP", + /* 120 */ "type_name ::= TINYINT UNSIGNED", + /* 121 */ "type_name ::= SMALLINT UNSIGNED", + /* 122 */ "type_name ::= INT UNSIGNED", + /* 123 */ "type_name ::= BIGINT UNSIGNED", + /* 124 */ "type_name ::= JSON", + /* 125 */ "type_name ::= VARCHAR NK_LP NK_INTEGER NK_RP", + /* 126 */ "type_name ::= MEDIUMBLOB", + /* 127 */ "type_name ::= BLOB", + /* 128 */ "type_name ::= VARBINARY NK_LP NK_INTEGER NK_RP", + /* 129 */ "type_name ::= DECIMAL", + /* 130 */ "type_name ::= DECIMAL NK_LP NK_INTEGER NK_RP", + /* 131 */ "type_name ::= DECIMAL NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP", + /* 132 */ "tags_def_opt ::=", + /* 133 */ "tags_def_opt ::= tags_def", + /* 134 */ "tags_def ::= TAGS NK_LP column_def_list NK_RP", + /* 135 */ "table_options ::=", + /* 136 */ "table_options ::= table_options COMMENT NK_STRING", + /* 137 */ "table_options ::= table_options KEEP NK_INTEGER", + /* 138 */ "table_options ::= table_options TTL NK_INTEGER", + /* 139 */ "table_options ::= table_options SMA NK_LP col_name_list NK_RP", + /* 140 */ "table_options ::= table_options ROLLUP NK_LP func_name_list NK_RP", + /* 141 */ "table_options ::= table_options FILE_FACTOR NK_FLOAT", + /* 142 */ "table_options ::= table_options DELAY NK_INTEGER", + /* 143 */ "alter_table_options ::= alter_table_option", + /* 144 */ "alter_table_options ::= alter_table_options alter_table_option", + /* 145 */ "alter_table_option ::= COMMENT NK_STRING", + /* 146 */ "alter_table_option ::= KEEP NK_INTEGER", + /* 147 */ "alter_table_option ::= TTL NK_INTEGER", + /* 148 */ "col_name_list ::= col_name", + /* 149 */ "col_name_list ::= col_name_list NK_COMMA col_name", + /* 150 */ "col_name ::= column_name", + /* 151 */ "cmd ::= SHOW DNODES", + /* 152 */ "cmd ::= SHOW USERS", + /* 153 */ "cmd ::= SHOW DATABASES", + /* 154 */ "cmd ::= SHOW db_name_cond_opt TABLES like_pattern_opt", + /* 155 */ "cmd ::= SHOW db_name_cond_opt STABLES like_pattern_opt", + /* 156 */ "cmd ::= SHOW db_name_cond_opt VGROUPS", + /* 157 */ "cmd ::= SHOW MNODES", + /* 158 */ "cmd ::= SHOW MODULES", + /* 159 */ "cmd ::= SHOW QNODES", + /* 160 */ "cmd ::= SHOW FUNCTIONS", + /* 161 */ "cmd ::= SHOW INDEXES FROM table_name_cond from_db_opt", + /* 162 */ "cmd ::= SHOW STREAMS", + /* 163 */ "db_name_cond_opt ::=", + /* 164 */ "db_name_cond_opt ::= db_name NK_DOT", + /* 165 */ "like_pattern_opt ::=", + /* 166 */ "like_pattern_opt ::= LIKE NK_STRING", + /* 167 */ "table_name_cond ::= table_name", + /* 168 */ "from_db_opt ::=", + /* 169 */ "from_db_opt ::= FROM db_name", + /* 170 */ "func_name_list ::= func_name", + /* 171 */ "func_name_list ::= func_name_list NK_COMMA col_name", + /* 172 */ "func_name ::= function_name", + /* 173 */ "cmd ::= CREATE SMA INDEX not_exists_opt index_name ON table_name index_options", + /* 174 */ "cmd ::= CREATE FULLTEXT INDEX not_exists_opt index_name ON table_name NK_LP col_name_list NK_RP", + /* 175 */ "cmd ::= DROP INDEX exists_opt index_name ON table_name", + /* 176 */ "index_options ::=", + /* 177 */ "index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_RP sliding_opt", + /* 178 */ "index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt", + /* 179 */ "func_list ::= func", + /* 180 */ "func_list ::= func_list NK_COMMA func", + /* 181 */ "func ::= function_name NK_LP expression_list NK_RP", + /* 182 */ "cmd ::= CREATE TOPIC not_exists_opt topic_name AS query_expression", + /* 183 */ "cmd ::= CREATE TOPIC not_exists_opt topic_name AS db_name", + /* 184 */ "cmd ::= DROP TOPIC exists_opt topic_name", + /* 185 */ "cmd ::= query_expression", + /* 186 */ "literal ::= NK_INTEGER", + /* 187 */ "literal ::= NK_FLOAT", + /* 188 */ "literal ::= NK_STRING", + /* 189 */ "literal ::= NK_BOOL", + /* 190 */ "literal ::= TIMESTAMP NK_STRING", + /* 191 */ "literal ::= duration_literal", + /* 192 */ "duration_literal ::= NK_VARIABLE", + /* 193 */ "signed ::= NK_INTEGER", + /* 194 */ "signed ::= NK_PLUS NK_INTEGER", + /* 195 */ "signed ::= NK_MINUS NK_INTEGER", + /* 196 */ "signed ::= NK_FLOAT", + /* 197 */ "signed ::= NK_PLUS NK_FLOAT", + /* 198 */ "signed ::= NK_MINUS NK_FLOAT", + /* 199 */ "signed_literal ::= signed", + /* 200 */ "signed_literal ::= NK_STRING", + /* 201 */ "signed_literal ::= NK_BOOL", + /* 202 */ "signed_literal ::= TIMESTAMP NK_STRING", + /* 203 */ "signed_literal ::= duration_literal", + /* 204 */ "literal_list ::= signed_literal", + /* 205 */ "literal_list ::= literal_list NK_COMMA signed_literal", + /* 206 */ "db_name ::= NK_ID", + /* 207 */ "table_name ::= NK_ID", + /* 208 */ "column_name ::= NK_ID", + /* 209 */ "function_name ::= NK_ID", + /* 210 */ "table_alias ::= NK_ID", + /* 211 */ "column_alias ::= NK_ID", + /* 212 */ "user_name ::= NK_ID", + /* 213 */ "index_name ::= NK_ID", + /* 214 */ "topic_name ::= NK_ID", + /* 215 */ "expression ::= literal", + /* 216 */ "expression ::= column_reference", + /* 217 */ "expression ::= function_name NK_LP expression_list NK_RP", + /* 218 */ "expression ::= function_name NK_LP NK_STAR NK_RP", + /* 219 */ "expression ::= subquery", + /* 220 */ "expression ::= NK_LP expression NK_RP", + /* 221 */ "expression ::= NK_PLUS expression", + /* 222 */ "expression ::= NK_MINUS expression", + /* 223 */ "expression ::= expression NK_PLUS expression", + /* 224 */ "expression ::= expression NK_MINUS expression", + /* 225 */ "expression ::= expression NK_STAR expression", + /* 226 */ "expression ::= expression NK_SLASH expression", + /* 227 */ "expression ::= expression NK_REM expression", + /* 228 */ "expression_list ::= expression", + /* 229 */ "expression_list ::= expression_list NK_COMMA expression", + /* 230 */ "column_reference ::= column_name", + /* 231 */ "column_reference ::= table_name NK_DOT column_name", + /* 232 */ "predicate ::= expression compare_op expression", + /* 233 */ "predicate ::= expression BETWEEN expression AND expression", + /* 234 */ "predicate ::= expression NOT BETWEEN expression AND expression", + /* 235 */ "predicate ::= expression IS NULL", + /* 236 */ "predicate ::= expression IS NOT NULL", + /* 237 */ "predicate ::= expression in_op in_predicate_value", + /* 238 */ "compare_op ::= NK_LT", + /* 239 */ "compare_op ::= NK_GT", + /* 240 */ "compare_op ::= NK_LE", + /* 241 */ "compare_op ::= NK_GE", + /* 242 */ "compare_op ::= NK_NE", + /* 243 */ "compare_op ::= NK_EQ", + /* 244 */ "compare_op ::= LIKE", + /* 245 */ "compare_op ::= NOT LIKE", + /* 246 */ "compare_op ::= MATCH", + /* 247 */ "compare_op ::= NMATCH", + /* 248 */ "in_op ::= IN", + /* 249 */ "in_op ::= NOT IN", + /* 250 */ "in_predicate_value ::= NK_LP expression_list NK_RP", + /* 251 */ "boolean_value_expression ::= boolean_primary", + /* 252 */ "boolean_value_expression ::= NOT boolean_primary", + /* 253 */ "boolean_value_expression ::= boolean_value_expression OR boolean_value_expression", + /* 254 */ "boolean_value_expression ::= boolean_value_expression AND boolean_value_expression", + /* 255 */ "boolean_primary ::= predicate", + /* 256 */ "boolean_primary ::= NK_LP boolean_value_expression NK_RP", + /* 257 */ "common_expression ::= expression", + /* 258 */ "common_expression ::= boolean_value_expression", + /* 259 */ "from_clause ::= FROM table_reference_list", + /* 260 */ "table_reference_list ::= table_reference", + /* 261 */ "table_reference_list ::= table_reference_list NK_COMMA table_reference", + /* 262 */ "table_reference ::= table_primary", + /* 263 */ "table_reference ::= joined_table", + /* 264 */ "table_primary ::= table_name alias_opt", + /* 265 */ "table_primary ::= db_name NK_DOT table_name alias_opt", + /* 266 */ "table_primary ::= subquery alias_opt", + /* 267 */ "table_primary ::= parenthesized_joined_table", + /* 268 */ "alias_opt ::=", + /* 269 */ "alias_opt ::= table_alias", + /* 270 */ "alias_opt ::= AS table_alias", + /* 271 */ "parenthesized_joined_table ::= NK_LP joined_table NK_RP", + /* 272 */ "parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP", + /* 273 */ "joined_table ::= table_reference join_type JOIN table_reference ON search_condition", + /* 274 */ "join_type ::=", + /* 275 */ "join_type ::= INNER", + /* 276 */ "query_specification ::= SELECT set_quantifier_opt select_list from_clause where_clause_opt partition_by_clause_opt twindow_clause_opt group_by_clause_opt having_clause_opt", + /* 277 */ "set_quantifier_opt ::=", + /* 278 */ "set_quantifier_opt ::= DISTINCT", + /* 279 */ "set_quantifier_opt ::= ALL", + /* 280 */ "select_list ::= NK_STAR", + /* 281 */ "select_list ::= select_sublist", + /* 282 */ "select_sublist ::= select_item", + /* 283 */ "select_sublist ::= select_sublist NK_COMMA select_item", + /* 284 */ "select_item ::= common_expression", + /* 285 */ "select_item ::= common_expression column_alias", + /* 286 */ "select_item ::= common_expression AS column_alias", + /* 287 */ "select_item ::= table_name NK_DOT NK_STAR", + /* 288 */ "where_clause_opt ::=", + /* 289 */ "where_clause_opt ::= WHERE search_condition", + /* 290 */ "partition_by_clause_opt ::=", + /* 291 */ "partition_by_clause_opt ::= PARTITION BY expression_list", + /* 292 */ "twindow_clause_opt ::=", + /* 293 */ "twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA duration_literal NK_RP", + /* 294 */ "twindow_clause_opt ::= STATE_WINDOW NK_LP column_reference NK_RP", + /* 295 */ "twindow_clause_opt ::= INTERVAL NK_LP duration_literal NK_RP sliding_opt fill_opt", + /* 296 */ "twindow_clause_opt ::= INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt fill_opt", + /* 297 */ "sliding_opt ::=", + /* 298 */ "sliding_opt ::= SLIDING NK_LP duration_literal NK_RP", + /* 299 */ "fill_opt ::=", + /* 300 */ "fill_opt ::= FILL NK_LP fill_mode NK_RP", + /* 301 */ "fill_opt ::= FILL NK_LP VALUE NK_COMMA literal_list NK_RP", + /* 302 */ "fill_mode ::= NONE", + /* 303 */ "fill_mode ::= PREV", + /* 304 */ "fill_mode ::= NULL", + /* 305 */ "fill_mode ::= LINEAR", + /* 306 */ "fill_mode ::= NEXT", + /* 307 */ "group_by_clause_opt ::=", + /* 308 */ "group_by_clause_opt ::= GROUP BY group_by_list", + /* 309 */ "group_by_list ::= expression", + /* 310 */ "group_by_list ::= group_by_list NK_COMMA expression", + /* 311 */ "having_clause_opt ::=", + /* 312 */ "having_clause_opt ::= HAVING search_condition", + /* 313 */ "query_expression ::= query_expression_body order_by_clause_opt slimit_clause_opt limit_clause_opt", + /* 314 */ "query_expression_body ::= query_primary", + /* 315 */ "query_expression_body ::= query_expression_body UNION ALL query_expression_body", + /* 316 */ "query_primary ::= query_specification", + /* 317 */ "order_by_clause_opt ::=", + /* 318 */ "order_by_clause_opt ::= ORDER BY sort_specification_list", + /* 319 */ "slimit_clause_opt ::=", + /* 320 */ "slimit_clause_opt ::= SLIMIT NK_INTEGER", + /* 321 */ "slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER", + /* 322 */ "slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER", + /* 323 */ "limit_clause_opt ::=", + /* 324 */ "limit_clause_opt ::= LIMIT NK_INTEGER", + /* 325 */ "limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER", + /* 326 */ "limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER", + /* 327 */ "subquery ::= NK_LP query_expression NK_RP", + /* 328 */ "search_condition ::= common_expression", + /* 329 */ "sort_specification_list ::= sort_specification", + /* 330 */ "sort_specification_list ::= sort_specification_list NK_COMMA sort_specification", + /* 331 */ "sort_specification ::= expression ordering_specification_opt null_ordering_opt", + /* 332 */ "ordering_specification_opt ::=", + /* 333 */ "ordering_specification_opt ::= ASC", + /* 334 */ "ordering_specification_opt ::= DESC", + /* 335 */ "null_ordering_opt ::=", + /* 336 */ "null_ordering_opt ::= NULLS FIRST", + /* 337 */ "null_ordering_opt ::= NULLS LAST", }; #endif /* NDEBUG */ @@ -1325,10 +1322,10 @@ static int yyGrowStack(yyParser *p){ newSize = p->yystksz*2 + 100; idx = p->yytos ? (int)(p->yytos - p->yystack) : 0; if( p->yystack==&p->yystk0 ){ - pNew = taosMemoryMalloc(newSize*sizeof(pNew[0])); + pNew = malloc(newSize*sizeof(pNew[0])); if( pNew ) pNew[0] = p->yystk0; }else{ - pNew = taosMemoryRealloc(p->yystack, newSize*sizeof(pNew[0])); + pNew = realloc(p->yystack, newSize*sizeof(pNew[0])); } if( pNew ){ p->yystack = pNew; @@ -1434,145 +1431,145 @@ static void yy_destructor( */ /********* Begin destructor definitions ***************************************/ /* Default NON-TERMINAL Destructor */ - case 163: /* cmd */ - case 166: /* literal */ - case 173: /* db_options */ - case 175: /* alter_db_options */ - case 177: /* full_table_name */ - case 180: /* table_options */ - case 184: /* alter_table_clause */ - case 185: /* alter_table_options */ - case 188: /* create_subtable_clause */ - case 191: /* drop_table_clause */ - case 194: /* column_def */ - case 197: /* col_name */ - case 198: /* db_name_cond_opt */ - case 199: /* like_pattern_opt */ - case 200: /* table_name_cond */ - case 201: /* from_db_opt */ - case 202: /* func_name */ - case 205: /* index_options */ - case 207: /* duration_literal */ - case 208: /* sliding_opt */ - case 209: /* func */ - case 212: /* query_expression */ - case 213: /* signed */ - case 214: /* signed_literal */ - case 217: /* expression */ - case 218: /* column_reference */ - case 219: /* subquery */ - case 220: /* predicate */ - case 223: /* in_predicate_value */ - case 224: /* boolean_value_expression */ - case 225: /* boolean_primary */ - case 226: /* common_expression */ - case 227: /* from_clause */ - case 228: /* table_reference_list */ - case 229: /* table_reference */ - case 230: /* table_primary */ - case 231: /* joined_table */ - case 233: /* parenthesized_joined_table */ - case 235: /* search_condition */ - case 236: /* query_specification */ - case 239: /* where_clause_opt */ - case 241: /* twindow_clause_opt */ - case 243: /* having_clause_opt */ - case 245: /* select_item */ - case 246: /* fill_opt */ - case 249: /* query_expression_body */ - case 251: /* slimit_clause_opt */ - case 252: /* limit_clause_opt */ - case 253: /* query_primary */ - case 255: /* sort_specification */ + case 164: /* cmd */ + case 167: /* literal */ + case 174: /* db_options */ + case 176: /* alter_db_options */ + case 178: /* full_table_name */ + case 181: /* table_options */ + case 185: /* alter_table_clause */ + case 186: /* alter_table_options */ + case 189: /* create_subtable_clause */ + case 192: /* drop_table_clause */ + case 195: /* column_def */ + case 198: /* col_name */ + case 199: /* db_name_cond_opt */ + case 200: /* like_pattern_opt */ + case 201: /* table_name_cond */ + case 202: /* from_db_opt */ + case 203: /* func_name */ + case 206: /* index_options */ + case 208: /* duration_literal */ + case 209: /* sliding_opt */ + case 210: /* func */ + case 213: /* query_expression */ + case 214: /* signed */ + case 215: /* signed_literal */ + case 218: /* expression */ + case 219: /* column_reference */ + case 220: /* subquery */ + case 221: /* predicate */ + case 224: /* in_predicate_value */ + case 225: /* boolean_value_expression */ + case 226: /* boolean_primary */ + case 227: /* common_expression */ + case 228: /* from_clause */ + case 229: /* table_reference_list */ + case 230: /* table_reference */ + case 231: /* table_primary */ + case 232: /* joined_table */ + case 234: /* parenthesized_joined_table */ + case 236: /* search_condition */ + case 237: /* query_specification */ + case 240: /* where_clause_opt */ + case 242: /* twindow_clause_opt */ + case 244: /* having_clause_opt */ + case 246: /* select_item */ + case 247: /* fill_opt */ + case 250: /* query_expression_body */ + case 252: /* slimit_clause_opt */ + case 253: /* limit_clause_opt */ + case 254: /* query_primary */ + case 256: /* sort_specification */ { - nodesDestroyNode((yypminor->yy140)); + nodesDestroyNode((yypminor->yy378)); } break; - case 164: /* account_options */ - case 165: /* alter_account_options */ - case 167: /* alter_account_option */ + case 165: /* account_options */ + case 166: /* alter_account_options */ + case 168: /* alter_account_option */ { } break; - case 168: /* user_name */ - case 169: /* dnode_endpoint */ - case 170: /* dnode_host_name */ - case 172: /* db_name */ - case 186: /* column_name */ - case 193: /* table_name */ - case 203: /* function_name */ - case 204: /* index_name */ - case 211: /* topic_name */ - case 215: /* table_alias */ - case 216: /* column_alias */ - case 232: /* alias_opt */ + case 169: /* user_name */ + case 170: /* dnode_endpoint */ + case 171: /* dnode_host_name */ + case 173: /* db_name */ + case 187: /* column_name */ + case 194: /* table_name */ + case 204: /* function_name */ + case 205: /* index_name */ + case 212: /* topic_name */ + case 216: /* table_alias */ + case 217: /* column_alias */ + case 233: /* alias_opt */ { } break; - case 171: /* not_exists_opt */ - case 174: /* exists_opt */ - case 237: /* set_quantifier_opt */ + case 172: /* not_exists_opt */ + case 175: /* exists_opt */ + case 238: /* set_quantifier_opt */ { } break; - case 176: /* alter_db_option */ - case 196: /* alter_table_option */ + case 177: /* alter_db_option */ + case 197: /* alter_table_option */ { } break; - case 178: /* column_def_list */ - case 179: /* tags_def_opt */ - case 181: /* multi_create_clause */ - case 182: /* tags_def */ - case 183: /* multi_drop_clause */ - case 189: /* specific_tags_opt */ - case 190: /* literal_list */ - case 192: /* col_name_list */ - case 195: /* func_name_list */ - case 206: /* func_list */ - case 210: /* expression_list */ - case 238: /* select_list */ - case 240: /* partition_by_clause_opt */ - case 242: /* group_by_clause_opt */ - case 244: /* select_sublist */ - case 248: /* group_by_list */ - case 250: /* order_by_clause_opt */ - case 254: /* sort_specification_list */ + case 179: /* column_def_list */ + case 180: /* tags_def_opt */ + case 182: /* multi_create_clause */ + case 183: /* tags_def */ + case 184: /* multi_drop_clause */ + case 190: /* specific_tags_opt */ + case 191: /* literal_list */ + case 193: /* col_name_list */ + case 196: /* func_name_list */ + case 207: /* func_list */ + case 211: /* expression_list */ + case 239: /* select_list */ + case 241: /* partition_by_clause_opt */ + case 243: /* group_by_clause_opt */ + case 245: /* select_sublist */ + case 249: /* group_by_list */ + case 251: /* order_by_clause_opt */ + case 255: /* sort_specification_list */ { - nodesDestroyList((yypminor->yy136)); + nodesDestroyList((yypminor->yy404)); } break; - case 187: /* type_name */ + case 188: /* type_name */ { } break; - case 221: /* compare_op */ - case 222: /* in_op */ + case 222: /* compare_op */ + case 223: /* in_op */ { } break; - case 234: /* join_type */ + case 235: /* join_type */ { } break; - case 247: /* fill_mode */ + case 248: /* fill_mode */ { } break; - case 256: /* ordering_specification_opt */ + case 257: /* ordering_specification_opt */ { } break; - case 257: /* null_ordering_opt */ + case 258: /* null_ordering_opt */ { } @@ -1610,7 +1607,7 @@ void ParseFinalize(void *p){ yyParser *pParser = (yyParser*)p; while( pParser->yytos>pParser->yystack ) yy_pop_parser_stack(pParser); #if YYSTACKDEPTH<=0 - if( pParser->yystack!=&pParser->yystk0 ) taosMemoryFree(pParser->yystack); + if( pParser->yystack!=&pParser->yystk0 ) free(pParser->yystack); #endif } @@ -1871,343 +1868,344 @@ static const struct { YYCODETYPE lhs; /* Symbol on the left-hand side of the rule */ signed char nrhs; /* Negative of the number of RHS symbols in the rule */ } yyRuleInfo[] = { - { 163, -6 }, /* (0) cmd ::= CREATE ACCOUNT NK_ID PASS NK_STRING account_options */ - { 163, -4 }, /* (1) cmd ::= ALTER ACCOUNT NK_ID alter_account_options */ - { 164, 0 }, /* (2) account_options ::= */ - { 164, -3 }, /* (3) account_options ::= account_options PPS literal */ - { 164, -3 }, /* (4) account_options ::= account_options TSERIES literal */ - { 164, -3 }, /* (5) account_options ::= account_options STORAGE literal */ - { 164, -3 }, /* (6) account_options ::= account_options STREAMS literal */ - { 164, -3 }, /* (7) account_options ::= account_options QTIME literal */ - { 164, -3 }, /* (8) account_options ::= account_options DBS literal */ - { 164, -3 }, /* (9) account_options ::= account_options USERS literal */ - { 164, -3 }, /* (10) account_options ::= account_options CONNS literal */ - { 164, -3 }, /* (11) account_options ::= account_options STATE literal */ - { 165, -1 }, /* (12) alter_account_options ::= alter_account_option */ - { 165, -2 }, /* (13) alter_account_options ::= alter_account_options alter_account_option */ - { 167, -2 }, /* (14) alter_account_option ::= PASS literal */ - { 167, -2 }, /* (15) alter_account_option ::= PPS literal */ - { 167, -2 }, /* (16) alter_account_option ::= TSERIES literal */ - { 167, -2 }, /* (17) alter_account_option ::= STORAGE literal */ - { 167, -2 }, /* (18) alter_account_option ::= STREAMS literal */ - { 167, -2 }, /* (19) alter_account_option ::= QTIME literal */ - { 167, -2 }, /* (20) alter_account_option ::= DBS literal */ - { 167, -2 }, /* (21) alter_account_option ::= USERS literal */ - { 167, -2 }, /* (22) alter_account_option ::= CONNS literal */ - { 167, -2 }, /* (23) alter_account_option ::= STATE literal */ - { 163, -5 }, /* (24) cmd ::= CREATE USER user_name PASS NK_STRING */ - { 163, -5 }, /* (25) cmd ::= ALTER USER user_name PASS NK_STRING */ - { 163, -5 }, /* (26) cmd ::= ALTER USER user_name PRIVILEGE NK_STRING */ - { 163, -3 }, /* (27) cmd ::= DROP USER user_name */ - { 163, -3 }, /* (28) cmd ::= CREATE DNODE dnode_endpoint */ - { 163, -5 }, /* (29) cmd ::= CREATE DNODE dnode_host_name PORT NK_INTEGER */ - { 163, -3 }, /* (30) cmd ::= DROP DNODE NK_INTEGER */ - { 163, -3 }, /* (31) cmd ::= DROP DNODE dnode_endpoint */ - { 163, -4 }, /* (32) cmd ::= ALTER DNODE NK_INTEGER NK_STRING */ - { 163, -5 }, /* (33) cmd ::= ALTER DNODE NK_INTEGER NK_STRING NK_STRING */ - { 163, -4 }, /* (34) cmd ::= ALTER ALL DNODES NK_STRING */ - { 163, -5 }, /* (35) cmd ::= ALTER ALL DNODES NK_STRING NK_STRING */ - { 169, -1 }, /* (36) dnode_endpoint ::= NK_STRING */ - { 170, -1 }, /* (37) dnode_host_name ::= NK_ID */ - { 170, -1 }, /* (38) dnode_host_name ::= NK_IPTOKEN */ - { 163, -3 }, /* (39) cmd ::= ALTER LOCAL NK_STRING */ - { 163, -4 }, /* (40) cmd ::= ALTER LOCAL NK_STRING NK_STRING */ - { 163, -5 }, /* (41) cmd ::= CREATE QNODE ON DNODE NK_INTEGER */ - { 163, -5 }, /* (42) cmd ::= DROP QNODE ON DNODE NK_INTEGER */ - { 163, -5 }, /* (43) cmd ::= CREATE DATABASE not_exists_opt db_name db_options */ - { 163, -4 }, /* (44) cmd ::= DROP DATABASE exists_opt db_name */ - { 163, -2 }, /* (45) cmd ::= USE db_name */ - { 163, -4 }, /* (46) cmd ::= ALTER DATABASE db_name alter_db_options */ - { 171, -3 }, /* (47) not_exists_opt ::= IF NOT EXISTS */ - { 171, 0 }, /* (48) not_exists_opt ::= */ - { 174, -2 }, /* (49) exists_opt ::= IF EXISTS */ - { 174, 0 }, /* (50) exists_opt ::= */ - { 173, 0 }, /* (51) db_options ::= */ - { 173, -3 }, /* (52) db_options ::= db_options BLOCKS NK_INTEGER */ - { 173, -3 }, /* (53) db_options ::= db_options CACHE NK_INTEGER */ - { 173, -3 }, /* (54) db_options ::= db_options CACHELAST NK_INTEGER */ - { 173, -3 }, /* (55) db_options ::= db_options COMP NK_INTEGER */ - { 173, -3 }, /* (56) db_options ::= db_options DAYS NK_INTEGER */ - { 173, -3 }, /* (57) db_options ::= db_options FSYNC NK_INTEGER */ - { 173, -3 }, /* (58) db_options ::= db_options MAXROWS NK_INTEGER */ - { 173, -3 }, /* (59) db_options ::= db_options MINROWS NK_INTEGER */ - { 173, -3 }, /* (60) db_options ::= db_options KEEP NK_INTEGER */ - { 173, -3 }, /* (61) db_options ::= db_options PRECISION NK_STRING */ - { 173, -3 }, /* (62) db_options ::= db_options QUORUM NK_INTEGER */ - { 173, -3 }, /* (63) db_options ::= db_options REPLICA NK_INTEGER */ - { 173, -3 }, /* (64) db_options ::= db_options TTL NK_INTEGER */ - { 173, -3 }, /* (65) db_options ::= db_options WAL NK_INTEGER */ - { 173, -3 }, /* (66) db_options ::= db_options VGROUPS NK_INTEGER */ - { 173, -3 }, /* (67) db_options ::= db_options SINGLE_STABLE NK_INTEGER */ - { 173, -3 }, /* (68) db_options ::= db_options STREAM_MODE NK_INTEGER */ - { 173, -3 }, /* (69) db_options ::= db_options RETENTIONS NK_STRING */ - { 173, -3 }, /* (70) db_options ::= db_options FILE_FACTOR NK_FLOAT */ - { 175, -1 }, /* (71) alter_db_options ::= alter_db_option */ - { 175, -2 }, /* (72) alter_db_options ::= alter_db_options alter_db_option */ - { 176, -2 }, /* (73) alter_db_option ::= BLOCKS NK_INTEGER */ - { 176, -2 }, /* (74) alter_db_option ::= FSYNC NK_INTEGER */ - { 176, -2 }, /* (75) alter_db_option ::= KEEP NK_INTEGER */ - { 176, -2 }, /* (76) alter_db_option ::= WAL NK_INTEGER */ - { 176, -2 }, /* (77) alter_db_option ::= QUORUM NK_INTEGER */ - { 176, -2 }, /* (78) alter_db_option ::= CACHELAST NK_INTEGER */ - { 163, -9 }, /* (79) cmd ::= CREATE TABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def_opt table_options */ - { 163, -3 }, /* (80) cmd ::= CREATE TABLE multi_create_clause */ - { 163, -9 }, /* (81) cmd ::= CREATE STABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def table_options */ - { 163, -3 }, /* (82) cmd ::= DROP TABLE multi_drop_clause */ - { 163, -4 }, /* (83) cmd ::= DROP STABLE exists_opt full_table_name */ - { 163, -3 }, /* (84) cmd ::= ALTER TABLE alter_table_clause */ - { 163, -3 }, /* (85) cmd ::= ALTER STABLE alter_table_clause */ - { 184, -2 }, /* (86) alter_table_clause ::= full_table_name alter_table_options */ - { 184, -5 }, /* (87) alter_table_clause ::= full_table_name ADD COLUMN column_name type_name */ - { 184, -4 }, /* (88) alter_table_clause ::= full_table_name DROP COLUMN column_name */ - { 184, -5 }, /* (89) alter_table_clause ::= full_table_name MODIFY COLUMN column_name type_name */ - { 184, -5 }, /* (90) alter_table_clause ::= full_table_name RENAME COLUMN column_name column_name */ - { 184, -5 }, /* (91) alter_table_clause ::= full_table_name ADD TAG column_name type_name */ - { 184, -4 }, /* (92) alter_table_clause ::= full_table_name DROP TAG column_name */ - { 184, -5 }, /* (93) alter_table_clause ::= full_table_name MODIFY TAG column_name type_name */ - { 184, -5 }, /* (94) alter_table_clause ::= full_table_name RENAME TAG column_name column_name */ - { 184, -6 }, /* (95) alter_table_clause ::= full_table_name SET TAG column_name NK_EQ literal */ - { 181, -1 }, /* (96) multi_create_clause ::= create_subtable_clause */ - { 181, -2 }, /* (97) multi_create_clause ::= multi_create_clause create_subtable_clause */ - { 188, -9 }, /* (98) create_subtable_clause ::= not_exists_opt full_table_name USING full_table_name specific_tags_opt TAGS NK_LP literal_list NK_RP */ - { 183, -1 }, /* (99) multi_drop_clause ::= drop_table_clause */ - { 183, -2 }, /* (100) multi_drop_clause ::= multi_drop_clause drop_table_clause */ - { 191, -2 }, /* (101) drop_table_clause ::= exists_opt full_table_name */ - { 189, 0 }, /* (102) specific_tags_opt ::= */ - { 189, -3 }, /* (103) specific_tags_opt ::= NK_LP col_name_list NK_RP */ - { 177, -1 }, /* (104) full_table_name ::= table_name */ - { 177, -3 }, /* (105) full_table_name ::= db_name NK_DOT table_name */ - { 178, -1 }, /* (106) column_def_list ::= column_def */ - { 178, -3 }, /* (107) column_def_list ::= column_def_list NK_COMMA column_def */ - { 194, -2 }, /* (108) column_def ::= column_name type_name */ - { 194, -4 }, /* (109) column_def ::= column_name type_name COMMENT NK_STRING */ - { 187, -1 }, /* (110) type_name ::= BOOL */ - { 187, -1 }, /* (111) type_name ::= TINYINT */ - { 187, -1 }, /* (112) type_name ::= SMALLINT */ - { 187, -1 }, /* (113) type_name ::= INT */ - { 187, -1 }, /* (114) type_name ::= INTEGER */ - { 187, -1 }, /* (115) type_name ::= BIGINT */ - { 187, -1 }, /* (116) type_name ::= FLOAT */ - { 187, -1 }, /* (117) type_name ::= DOUBLE */ - { 187, -4 }, /* (118) type_name ::= BINARY NK_LP NK_INTEGER NK_RP */ - { 187, -1 }, /* (119) type_name ::= TIMESTAMP */ - { 187, -4 }, /* (120) type_name ::= NCHAR NK_LP NK_INTEGER NK_RP */ - { 187, -2 }, /* (121) type_name ::= TINYINT UNSIGNED */ - { 187, -2 }, /* (122) type_name ::= SMALLINT UNSIGNED */ - { 187, -2 }, /* (123) type_name ::= INT UNSIGNED */ - { 187, -2 }, /* (124) type_name ::= BIGINT UNSIGNED */ - { 187, -1 }, /* (125) type_name ::= JSON */ - { 187, -4 }, /* (126) type_name ::= VARCHAR NK_LP NK_INTEGER NK_RP */ - { 187, -1 }, /* (127) type_name ::= MEDIUMBLOB */ - { 187, -1 }, /* (128) type_name ::= BLOB */ - { 187, -4 }, /* (129) type_name ::= VARBINARY NK_LP NK_INTEGER NK_RP */ - { 187, -1 }, /* (130) type_name ::= DECIMAL */ - { 187, -4 }, /* (131) type_name ::= DECIMAL NK_LP NK_INTEGER NK_RP */ - { 187, -6 }, /* (132) type_name ::= DECIMAL NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP */ - { 179, 0 }, /* (133) tags_def_opt ::= */ - { 179, -1 }, /* (134) tags_def_opt ::= tags_def */ - { 182, -4 }, /* (135) tags_def ::= TAGS NK_LP column_def_list NK_RP */ - { 180, 0 }, /* (136) table_options ::= */ - { 180, -3 }, /* (137) table_options ::= table_options COMMENT NK_STRING */ - { 180, -3 }, /* (138) table_options ::= table_options KEEP NK_INTEGER */ - { 180, -3 }, /* (139) table_options ::= table_options TTL NK_INTEGER */ - { 180, -5 }, /* (140) table_options ::= table_options SMA NK_LP col_name_list NK_RP */ - { 180, -5 }, /* (141) table_options ::= table_options ROLLUP NK_LP func_name_list NK_RP */ - { 185, -1 }, /* (142) alter_table_options ::= alter_table_option */ - { 185, -2 }, /* (143) alter_table_options ::= alter_table_options alter_table_option */ - { 196, -2 }, /* (144) alter_table_option ::= COMMENT NK_STRING */ - { 196, -2 }, /* (145) alter_table_option ::= KEEP NK_INTEGER */ - { 196, -2 }, /* (146) alter_table_option ::= TTL NK_INTEGER */ - { 192, -1 }, /* (147) col_name_list ::= col_name */ - { 192, -3 }, /* (148) col_name_list ::= col_name_list NK_COMMA col_name */ - { 197, -1 }, /* (149) col_name ::= column_name */ - { 163, -2 }, /* (150) cmd ::= SHOW DNODES */ - { 163, -2 }, /* (151) cmd ::= SHOW USERS */ - { 163, -2 }, /* (152) cmd ::= SHOW DATABASES */ - { 163, -4 }, /* (153) cmd ::= SHOW db_name_cond_opt TABLES like_pattern_opt */ - { 163, -4 }, /* (154) cmd ::= SHOW db_name_cond_opt STABLES like_pattern_opt */ - { 163, -3 }, /* (155) cmd ::= SHOW db_name_cond_opt VGROUPS */ - { 163, -2 }, /* (156) cmd ::= SHOW MNODES */ - { 163, -2 }, /* (157) cmd ::= SHOW MODULES */ - { 163, -2 }, /* (158) cmd ::= SHOW QNODES */ - { 163, -2 }, /* (159) cmd ::= SHOW FUNCTIONS */ - { 163, -5 }, /* (160) cmd ::= SHOW INDEXES FROM table_name_cond from_db_opt */ - { 163, -2 }, /* (161) cmd ::= SHOW STREAMS */ - { 198, 0 }, /* (162) db_name_cond_opt ::= */ - { 198, -2 }, /* (163) db_name_cond_opt ::= db_name NK_DOT */ - { 199, 0 }, /* (164) like_pattern_opt ::= */ - { 199, -2 }, /* (165) like_pattern_opt ::= LIKE NK_STRING */ - { 200, -1 }, /* (166) table_name_cond ::= table_name */ - { 201, 0 }, /* (167) from_db_opt ::= */ - { 201, -2 }, /* (168) from_db_opt ::= FROM db_name */ - { 195, -1 }, /* (169) func_name_list ::= func_name */ - { 195, -3 }, /* (170) func_name_list ::= func_name_list NK_COMMA col_name */ - { 202, -1 }, /* (171) func_name ::= function_name */ - { 163, -8 }, /* (172) cmd ::= CREATE SMA INDEX not_exists_opt index_name ON table_name index_options */ - { 163, -10 }, /* (173) cmd ::= CREATE FULLTEXT INDEX not_exists_opt index_name ON table_name NK_LP col_name_list NK_RP */ - { 163, -6 }, /* (174) cmd ::= DROP INDEX exists_opt index_name ON table_name */ - { 205, 0 }, /* (175) index_options ::= */ - { 205, -9 }, /* (176) index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_RP sliding_opt */ - { 205, -11 }, /* (177) index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt */ - { 206, -1 }, /* (178) func_list ::= func */ - { 206, -3 }, /* (179) func_list ::= func_list NK_COMMA func */ - { 209, -4 }, /* (180) func ::= function_name NK_LP expression_list NK_RP */ - { 163, -6 }, /* (181) cmd ::= CREATE TOPIC not_exists_opt topic_name AS query_expression */ - { 163, -6 }, /* (182) cmd ::= CREATE TOPIC not_exists_opt topic_name AS db_name */ - { 163, -4 }, /* (183) cmd ::= DROP TOPIC exists_opt topic_name */ - { 163, -1 }, /* (184) cmd ::= query_expression */ - { 166, -1 }, /* (185) literal ::= NK_INTEGER */ - { 166, -1 }, /* (186) literal ::= NK_FLOAT */ - { 166, -1 }, /* (187) literal ::= NK_STRING */ - { 166, -1 }, /* (188) literal ::= NK_BOOL */ - { 166, -2 }, /* (189) literal ::= TIMESTAMP NK_STRING */ - { 166, -1 }, /* (190) literal ::= duration_literal */ - { 207, -1 }, /* (191) duration_literal ::= NK_VARIABLE */ - { 213, -1 }, /* (192) signed ::= NK_INTEGER */ - { 213, -2 }, /* (193) signed ::= NK_PLUS NK_INTEGER */ - { 213, -2 }, /* (194) signed ::= NK_MINUS NK_INTEGER */ - { 213, -1 }, /* (195) signed ::= NK_FLOAT */ - { 213, -2 }, /* (196) signed ::= NK_PLUS NK_FLOAT */ - { 213, -2 }, /* (197) signed ::= NK_MINUS NK_FLOAT */ - { 214, -1 }, /* (198) signed_literal ::= signed */ - { 214, -1 }, /* (199) signed_literal ::= NK_STRING */ - { 214, -1 }, /* (200) signed_literal ::= NK_BOOL */ - { 214, -2 }, /* (201) signed_literal ::= TIMESTAMP NK_STRING */ - { 214, -1 }, /* (202) signed_literal ::= duration_literal */ - { 190, -1 }, /* (203) literal_list ::= signed_literal */ - { 190, -3 }, /* (204) literal_list ::= literal_list NK_COMMA signed_literal */ - { 172, -1 }, /* (205) db_name ::= NK_ID */ - { 193, -1 }, /* (206) table_name ::= NK_ID */ - { 186, -1 }, /* (207) column_name ::= NK_ID */ - { 203, -1 }, /* (208) function_name ::= NK_ID */ - { 215, -1 }, /* (209) table_alias ::= NK_ID */ - { 216, -1 }, /* (210) column_alias ::= NK_ID */ - { 168, -1 }, /* (211) user_name ::= NK_ID */ - { 204, -1 }, /* (212) index_name ::= NK_ID */ - { 211, -1 }, /* (213) topic_name ::= NK_ID */ - { 217, -1 }, /* (214) expression ::= literal */ - { 217, -1 }, /* (215) expression ::= column_reference */ - { 217, -4 }, /* (216) expression ::= function_name NK_LP expression_list NK_RP */ - { 217, -4 }, /* (217) expression ::= function_name NK_LP NK_STAR NK_RP */ - { 217, -1 }, /* (218) expression ::= subquery */ - { 217, -3 }, /* (219) expression ::= NK_LP expression NK_RP */ - { 217, -2 }, /* (220) expression ::= NK_PLUS expression */ - { 217, -2 }, /* (221) expression ::= NK_MINUS expression */ - { 217, -3 }, /* (222) expression ::= expression NK_PLUS expression */ - { 217, -3 }, /* (223) expression ::= expression NK_MINUS expression */ - { 217, -3 }, /* (224) expression ::= expression NK_STAR expression */ - { 217, -3 }, /* (225) expression ::= expression NK_SLASH expression */ - { 217, -3 }, /* (226) expression ::= expression NK_REM expression */ - { 210, -1 }, /* (227) expression_list ::= expression */ - { 210, -3 }, /* (228) expression_list ::= expression_list NK_COMMA expression */ - { 218, -1 }, /* (229) column_reference ::= column_name */ - { 218, -3 }, /* (230) column_reference ::= table_name NK_DOT column_name */ - { 220, -3 }, /* (231) predicate ::= expression compare_op expression */ - { 220, -5 }, /* (232) predicate ::= expression BETWEEN expression AND expression */ - { 220, -6 }, /* (233) predicate ::= expression NOT BETWEEN expression AND expression */ - { 220, -3 }, /* (234) predicate ::= expression IS NULL */ - { 220, -4 }, /* (235) predicate ::= expression IS NOT NULL */ - { 220, -3 }, /* (236) predicate ::= expression in_op in_predicate_value */ - { 221, -1 }, /* (237) compare_op ::= NK_LT */ - { 221, -1 }, /* (238) compare_op ::= NK_GT */ - { 221, -1 }, /* (239) compare_op ::= NK_LE */ - { 221, -1 }, /* (240) compare_op ::= NK_GE */ - { 221, -1 }, /* (241) compare_op ::= NK_NE */ - { 221, -1 }, /* (242) compare_op ::= NK_EQ */ - { 221, -1 }, /* (243) compare_op ::= LIKE */ - { 221, -2 }, /* (244) compare_op ::= NOT LIKE */ - { 221, -1 }, /* (245) compare_op ::= MATCH */ - { 221, -1 }, /* (246) compare_op ::= NMATCH */ - { 222, -1 }, /* (247) in_op ::= IN */ - { 222, -2 }, /* (248) in_op ::= NOT IN */ - { 223, -3 }, /* (249) in_predicate_value ::= NK_LP expression_list NK_RP */ - { 224, -1 }, /* (250) boolean_value_expression ::= boolean_primary */ - { 224, -2 }, /* (251) boolean_value_expression ::= NOT boolean_primary */ - { 224, -3 }, /* (252) boolean_value_expression ::= boolean_value_expression OR boolean_value_expression */ - { 224, -3 }, /* (253) boolean_value_expression ::= boolean_value_expression AND boolean_value_expression */ - { 225, -1 }, /* (254) boolean_primary ::= predicate */ - { 225, -3 }, /* (255) boolean_primary ::= NK_LP boolean_value_expression NK_RP */ - { 226, -1 }, /* (256) common_expression ::= expression */ - { 226, -1 }, /* (257) common_expression ::= boolean_value_expression */ - { 227, -2 }, /* (258) from_clause ::= FROM table_reference_list */ - { 228, -1 }, /* (259) table_reference_list ::= table_reference */ - { 228, -3 }, /* (260) table_reference_list ::= table_reference_list NK_COMMA table_reference */ - { 229, -1 }, /* (261) table_reference ::= table_primary */ - { 229, -1 }, /* (262) table_reference ::= joined_table */ - { 230, -2 }, /* (263) table_primary ::= table_name alias_opt */ - { 230, -4 }, /* (264) table_primary ::= db_name NK_DOT table_name alias_opt */ - { 230, -2 }, /* (265) table_primary ::= subquery alias_opt */ - { 230, -1 }, /* (266) table_primary ::= parenthesized_joined_table */ - { 232, 0 }, /* (267) alias_opt ::= */ - { 232, -1 }, /* (268) alias_opt ::= table_alias */ - { 232, -2 }, /* (269) alias_opt ::= AS table_alias */ - { 233, -3 }, /* (270) parenthesized_joined_table ::= NK_LP joined_table NK_RP */ - { 233, -3 }, /* (271) parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP */ - { 231, -6 }, /* (272) joined_table ::= table_reference join_type JOIN table_reference ON search_condition */ - { 234, 0 }, /* (273) join_type ::= */ - { 234, -1 }, /* (274) join_type ::= INNER */ - { 236, -9 }, /* (275) query_specification ::= SELECT set_quantifier_opt select_list from_clause where_clause_opt partition_by_clause_opt twindow_clause_opt group_by_clause_opt having_clause_opt */ - { 237, 0 }, /* (276) set_quantifier_opt ::= */ - { 237, -1 }, /* (277) set_quantifier_opt ::= DISTINCT */ - { 237, -1 }, /* (278) set_quantifier_opt ::= ALL */ - { 238, -1 }, /* (279) select_list ::= NK_STAR */ - { 238, -1 }, /* (280) select_list ::= select_sublist */ - { 244, -1 }, /* (281) select_sublist ::= select_item */ - { 244, -3 }, /* (282) select_sublist ::= select_sublist NK_COMMA select_item */ - { 245, -1 }, /* (283) select_item ::= common_expression */ - { 245, -2 }, /* (284) select_item ::= common_expression column_alias */ - { 245, -3 }, /* (285) select_item ::= common_expression AS column_alias */ - { 245, -3 }, /* (286) select_item ::= table_name NK_DOT NK_STAR */ - { 239, 0 }, /* (287) where_clause_opt ::= */ - { 239, -2 }, /* (288) where_clause_opt ::= WHERE search_condition */ - { 240, 0 }, /* (289) partition_by_clause_opt ::= */ - { 240, -3 }, /* (290) partition_by_clause_opt ::= PARTITION BY expression_list */ - { 241, 0 }, /* (291) twindow_clause_opt ::= */ - { 241, -6 }, /* (292) twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA duration_literal NK_RP */ - { 241, -4 }, /* (293) twindow_clause_opt ::= STATE_WINDOW NK_LP column_reference NK_RP */ - { 241, -6 }, /* (294) twindow_clause_opt ::= INTERVAL NK_LP duration_literal NK_RP sliding_opt fill_opt */ - { 241, -8 }, /* (295) twindow_clause_opt ::= INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt fill_opt */ - { 208, 0 }, /* (296) sliding_opt ::= */ - { 208, -4 }, /* (297) sliding_opt ::= SLIDING NK_LP duration_literal NK_RP */ - { 246, 0 }, /* (298) fill_opt ::= */ - { 246, -4 }, /* (299) fill_opt ::= FILL NK_LP fill_mode NK_RP */ - { 246, -6 }, /* (300) fill_opt ::= FILL NK_LP VALUE NK_COMMA literal_list NK_RP */ - { 247, -1 }, /* (301) fill_mode ::= NONE */ - { 247, -1 }, /* (302) fill_mode ::= PREV */ - { 247, -1 }, /* (303) fill_mode ::= NULL */ - { 247, -1 }, /* (304) fill_mode ::= LINEAR */ - { 247, -1 }, /* (305) fill_mode ::= NEXT */ - { 242, 0 }, /* (306) group_by_clause_opt ::= */ - { 242, -3 }, /* (307) group_by_clause_opt ::= GROUP BY group_by_list */ - { 248, -1 }, /* (308) group_by_list ::= expression */ - { 248, -3 }, /* (309) group_by_list ::= group_by_list NK_COMMA expression */ - { 243, 0 }, /* (310) having_clause_opt ::= */ - { 243, -2 }, /* (311) having_clause_opt ::= HAVING search_condition */ - { 212, -4 }, /* (312) query_expression ::= query_expression_body order_by_clause_opt slimit_clause_opt limit_clause_opt */ - { 249, -1 }, /* (313) query_expression_body ::= query_primary */ - { 249, -4 }, /* (314) query_expression_body ::= query_expression_body UNION ALL query_expression_body */ - { 253, -1 }, /* (315) query_primary ::= query_specification */ - { 250, 0 }, /* (316) order_by_clause_opt ::= */ - { 250, -3 }, /* (317) order_by_clause_opt ::= ORDER BY sort_specification_list */ - { 251, 0 }, /* (318) slimit_clause_opt ::= */ - { 251, -2 }, /* (319) slimit_clause_opt ::= SLIMIT NK_INTEGER */ - { 251, -4 }, /* (320) slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER */ - { 251, -4 }, /* (321) slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER */ - { 252, 0 }, /* (322) limit_clause_opt ::= */ - { 252, -2 }, /* (323) limit_clause_opt ::= LIMIT NK_INTEGER */ - { 252, -4 }, /* (324) limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER */ - { 252, -4 }, /* (325) limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER */ - { 219, -3 }, /* (326) subquery ::= NK_LP query_expression NK_RP */ - { 235, -1 }, /* (327) search_condition ::= common_expression */ - { 254, -1 }, /* (328) sort_specification_list ::= sort_specification */ - { 254, -3 }, /* (329) sort_specification_list ::= sort_specification_list NK_COMMA sort_specification */ - { 255, -3 }, /* (330) sort_specification ::= expression ordering_specification_opt null_ordering_opt */ - { 256, 0 }, /* (331) ordering_specification_opt ::= */ - { 256, -1 }, /* (332) ordering_specification_opt ::= ASC */ - { 256, -1 }, /* (333) ordering_specification_opt ::= DESC */ - { 257, 0 }, /* (334) null_ordering_opt ::= */ - { 257, -2 }, /* (335) null_ordering_opt ::= NULLS FIRST */ - { 257, -2 }, /* (336) null_ordering_opt ::= NULLS LAST */ + { 164, -6 }, /* (0) cmd ::= CREATE ACCOUNT NK_ID PASS NK_STRING account_options */ + { 164, -4 }, /* (1) cmd ::= ALTER ACCOUNT NK_ID alter_account_options */ + { 165, 0 }, /* (2) account_options ::= */ + { 165, -3 }, /* (3) account_options ::= account_options PPS literal */ + { 165, -3 }, /* (4) account_options ::= account_options TSERIES literal */ + { 165, -3 }, /* (5) account_options ::= account_options STORAGE literal */ + { 165, -3 }, /* (6) account_options ::= account_options STREAMS literal */ + { 165, -3 }, /* (7) account_options ::= account_options QTIME literal */ + { 165, -3 }, /* (8) account_options ::= account_options DBS literal */ + { 165, -3 }, /* (9) account_options ::= account_options USERS literal */ + { 165, -3 }, /* (10) account_options ::= account_options CONNS literal */ + { 165, -3 }, /* (11) account_options ::= account_options STATE literal */ + { 166, -1 }, /* (12) alter_account_options ::= alter_account_option */ + { 166, -2 }, /* (13) alter_account_options ::= alter_account_options alter_account_option */ + { 168, -2 }, /* (14) alter_account_option ::= PASS literal */ + { 168, -2 }, /* (15) alter_account_option ::= PPS literal */ + { 168, -2 }, /* (16) alter_account_option ::= TSERIES literal */ + { 168, -2 }, /* (17) alter_account_option ::= STORAGE literal */ + { 168, -2 }, /* (18) alter_account_option ::= STREAMS literal */ + { 168, -2 }, /* (19) alter_account_option ::= QTIME literal */ + { 168, -2 }, /* (20) alter_account_option ::= DBS literal */ + { 168, -2 }, /* (21) alter_account_option ::= USERS literal */ + { 168, -2 }, /* (22) alter_account_option ::= CONNS literal */ + { 168, -2 }, /* (23) alter_account_option ::= STATE literal */ + { 164, -5 }, /* (24) cmd ::= CREATE USER user_name PASS NK_STRING */ + { 164, -5 }, /* (25) cmd ::= ALTER USER user_name PASS NK_STRING */ + { 164, -5 }, /* (26) cmd ::= ALTER USER user_name PRIVILEGE NK_STRING */ + { 164, -3 }, /* (27) cmd ::= DROP USER user_name */ + { 164, -3 }, /* (28) cmd ::= CREATE DNODE dnode_endpoint */ + { 164, -5 }, /* (29) cmd ::= CREATE DNODE dnode_host_name PORT NK_INTEGER */ + { 164, -3 }, /* (30) cmd ::= DROP DNODE NK_INTEGER */ + { 164, -3 }, /* (31) cmd ::= DROP DNODE dnode_endpoint */ + { 164, -4 }, /* (32) cmd ::= ALTER DNODE NK_INTEGER NK_STRING */ + { 164, -5 }, /* (33) cmd ::= ALTER DNODE NK_INTEGER NK_STRING NK_STRING */ + { 164, -4 }, /* (34) cmd ::= ALTER ALL DNODES NK_STRING */ + { 164, -5 }, /* (35) cmd ::= ALTER ALL DNODES NK_STRING NK_STRING */ + { 170, -1 }, /* (36) dnode_endpoint ::= NK_STRING */ + { 171, -1 }, /* (37) dnode_host_name ::= NK_ID */ + { 171, -1 }, /* (38) dnode_host_name ::= NK_IPTOKEN */ + { 164, -3 }, /* (39) cmd ::= ALTER LOCAL NK_STRING */ + { 164, -4 }, /* (40) cmd ::= ALTER LOCAL NK_STRING NK_STRING */ + { 164, -5 }, /* (41) cmd ::= CREATE QNODE ON DNODE NK_INTEGER */ + { 164, -5 }, /* (42) cmd ::= DROP QNODE ON DNODE NK_INTEGER */ + { 164, -5 }, /* (43) cmd ::= CREATE DATABASE not_exists_opt db_name db_options */ + { 164, -4 }, /* (44) cmd ::= DROP DATABASE exists_opt db_name */ + { 164, -2 }, /* (45) cmd ::= USE db_name */ + { 164, -4 }, /* (46) cmd ::= ALTER DATABASE db_name alter_db_options */ + { 172, -3 }, /* (47) not_exists_opt ::= IF NOT EXISTS */ + { 172, 0 }, /* (48) not_exists_opt ::= */ + { 175, -2 }, /* (49) exists_opt ::= IF EXISTS */ + { 175, 0 }, /* (50) exists_opt ::= */ + { 174, 0 }, /* (51) db_options ::= */ + { 174, -3 }, /* (52) db_options ::= db_options BLOCKS NK_INTEGER */ + { 174, -3 }, /* (53) db_options ::= db_options CACHE NK_INTEGER */ + { 174, -3 }, /* (54) db_options ::= db_options CACHELAST NK_INTEGER */ + { 174, -3 }, /* (55) db_options ::= db_options COMP NK_INTEGER */ + { 174, -3 }, /* (56) db_options ::= db_options DAYS NK_INTEGER */ + { 174, -3 }, /* (57) db_options ::= db_options FSYNC NK_INTEGER */ + { 174, -3 }, /* (58) db_options ::= db_options MAXROWS NK_INTEGER */ + { 174, -3 }, /* (59) db_options ::= db_options MINROWS NK_INTEGER */ + { 174, -3 }, /* (60) db_options ::= db_options KEEP NK_INTEGER */ + { 174, -3 }, /* (61) db_options ::= db_options PRECISION NK_STRING */ + { 174, -3 }, /* (62) db_options ::= db_options QUORUM NK_INTEGER */ + { 174, -3 }, /* (63) db_options ::= db_options REPLICA NK_INTEGER */ + { 174, -3 }, /* (64) db_options ::= db_options TTL NK_INTEGER */ + { 174, -3 }, /* (65) db_options ::= db_options WAL NK_INTEGER */ + { 174, -3 }, /* (66) db_options ::= db_options VGROUPS NK_INTEGER */ + { 174, -3 }, /* (67) db_options ::= db_options SINGLE_STABLE NK_INTEGER */ + { 174, -3 }, /* (68) db_options ::= db_options STREAM_MODE NK_INTEGER */ + { 174, -3 }, /* (69) db_options ::= db_options RETENTIONS NK_STRING */ + { 176, -1 }, /* (70) alter_db_options ::= alter_db_option */ + { 176, -2 }, /* (71) alter_db_options ::= alter_db_options alter_db_option */ + { 177, -2 }, /* (72) alter_db_option ::= BLOCKS NK_INTEGER */ + { 177, -2 }, /* (73) alter_db_option ::= FSYNC NK_INTEGER */ + { 177, -2 }, /* (74) alter_db_option ::= KEEP NK_INTEGER */ + { 177, -2 }, /* (75) alter_db_option ::= WAL NK_INTEGER */ + { 177, -2 }, /* (76) alter_db_option ::= QUORUM NK_INTEGER */ + { 177, -2 }, /* (77) alter_db_option ::= CACHELAST NK_INTEGER */ + { 164, -9 }, /* (78) cmd ::= CREATE TABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def_opt table_options */ + { 164, -3 }, /* (79) cmd ::= CREATE TABLE multi_create_clause */ + { 164, -9 }, /* (80) cmd ::= CREATE STABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def table_options */ + { 164, -3 }, /* (81) cmd ::= DROP TABLE multi_drop_clause */ + { 164, -4 }, /* (82) cmd ::= DROP STABLE exists_opt full_table_name */ + { 164, -3 }, /* (83) cmd ::= ALTER TABLE alter_table_clause */ + { 164, -3 }, /* (84) cmd ::= ALTER STABLE alter_table_clause */ + { 185, -2 }, /* (85) alter_table_clause ::= full_table_name alter_table_options */ + { 185, -5 }, /* (86) alter_table_clause ::= full_table_name ADD COLUMN column_name type_name */ + { 185, -4 }, /* (87) alter_table_clause ::= full_table_name DROP COLUMN column_name */ + { 185, -5 }, /* (88) alter_table_clause ::= full_table_name MODIFY COLUMN column_name type_name */ + { 185, -5 }, /* (89) alter_table_clause ::= full_table_name RENAME COLUMN column_name column_name */ + { 185, -5 }, /* (90) alter_table_clause ::= full_table_name ADD TAG column_name type_name */ + { 185, -4 }, /* (91) alter_table_clause ::= full_table_name DROP TAG column_name */ + { 185, -5 }, /* (92) alter_table_clause ::= full_table_name MODIFY TAG column_name type_name */ + { 185, -5 }, /* (93) alter_table_clause ::= full_table_name RENAME TAG column_name column_name */ + { 185, -6 }, /* (94) alter_table_clause ::= full_table_name SET TAG column_name NK_EQ literal */ + { 182, -1 }, /* (95) multi_create_clause ::= create_subtable_clause */ + { 182, -2 }, /* (96) multi_create_clause ::= multi_create_clause create_subtable_clause */ + { 189, -9 }, /* (97) create_subtable_clause ::= not_exists_opt full_table_name USING full_table_name specific_tags_opt TAGS NK_LP literal_list NK_RP */ + { 184, -1 }, /* (98) multi_drop_clause ::= drop_table_clause */ + { 184, -2 }, /* (99) multi_drop_clause ::= multi_drop_clause drop_table_clause */ + { 192, -2 }, /* (100) drop_table_clause ::= exists_opt full_table_name */ + { 190, 0 }, /* (101) specific_tags_opt ::= */ + { 190, -3 }, /* (102) specific_tags_opt ::= NK_LP col_name_list NK_RP */ + { 178, -1 }, /* (103) full_table_name ::= table_name */ + { 178, -3 }, /* (104) full_table_name ::= db_name NK_DOT table_name */ + { 179, -1 }, /* (105) column_def_list ::= column_def */ + { 179, -3 }, /* (106) column_def_list ::= column_def_list NK_COMMA column_def */ + { 195, -2 }, /* (107) column_def ::= column_name type_name */ + { 195, -4 }, /* (108) column_def ::= column_name type_name COMMENT NK_STRING */ + { 188, -1 }, /* (109) type_name ::= BOOL */ + { 188, -1 }, /* (110) type_name ::= TINYINT */ + { 188, -1 }, /* (111) type_name ::= SMALLINT */ + { 188, -1 }, /* (112) type_name ::= INT */ + { 188, -1 }, /* (113) type_name ::= INTEGER */ + { 188, -1 }, /* (114) type_name ::= BIGINT */ + { 188, -1 }, /* (115) type_name ::= FLOAT */ + { 188, -1 }, /* (116) type_name ::= DOUBLE */ + { 188, -4 }, /* (117) type_name ::= BINARY NK_LP NK_INTEGER NK_RP */ + { 188, -1 }, /* (118) type_name ::= TIMESTAMP */ + { 188, -4 }, /* (119) type_name ::= NCHAR NK_LP NK_INTEGER NK_RP */ + { 188, -2 }, /* (120) type_name ::= TINYINT UNSIGNED */ + { 188, -2 }, /* (121) type_name ::= SMALLINT UNSIGNED */ + { 188, -2 }, /* (122) type_name ::= INT UNSIGNED */ + { 188, -2 }, /* (123) type_name ::= BIGINT UNSIGNED */ + { 188, -1 }, /* (124) type_name ::= JSON */ + { 188, -4 }, /* (125) type_name ::= VARCHAR NK_LP NK_INTEGER NK_RP */ + { 188, -1 }, /* (126) type_name ::= MEDIUMBLOB */ + { 188, -1 }, /* (127) type_name ::= BLOB */ + { 188, -4 }, /* (128) type_name ::= VARBINARY NK_LP NK_INTEGER NK_RP */ + { 188, -1 }, /* (129) type_name ::= DECIMAL */ + { 188, -4 }, /* (130) type_name ::= DECIMAL NK_LP NK_INTEGER NK_RP */ + { 188, -6 }, /* (131) type_name ::= DECIMAL NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP */ + { 180, 0 }, /* (132) tags_def_opt ::= */ + { 180, -1 }, /* (133) tags_def_opt ::= tags_def */ + { 183, -4 }, /* (134) tags_def ::= TAGS NK_LP column_def_list NK_RP */ + { 181, 0 }, /* (135) table_options ::= */ + { 181, -3 }, /* (136) table_options ::= table_options COMMENT NK_STRING */ + { 181, -3 }, /* (137) table_options ::= table_options KEEP NK_INTEGER */ + { 181, -3 }, /* (138) table_options ::= table_options TTL NK_INTEGER */ + { 181, -5 }, /* (139) table_options ::= table_options SMA NK_LP col_name_list NK_RP */ + { 181, -5 }, /* (140) table_options ::= table_options ROLLUP NK_LP func_name_list NK_RP */ + { 181, -3 }, /* (141) table_options ::= table_options FILE_FACTOR NK_FLOAT */ + { 181, -3 }, /* (142) table_options ::= table_options DELAY NK_INTEGER */ + { 186, -1 }, /* (143) alter_table_options ::= alter_table_option */ + { 186, -2 }, /* (144) alter_table_options ::= alter_table_options alter_table_option */ + { 197, -2 }, /* (145) alter_table_option ::= COMMENT NK_STRING */ + { 197, -2 }, /* (146) alter_table_option ::= KEEP NK_INTEGER */ + { 197, -2 }, /* (147) alter_table_option ::= TTL NK_INTEGER */ + { 193, -1 }, /* (148) col_name_list ::= col_name */ + { 193, -3 }, /* (149) col_name_list ::= col_name_list NK_COMMA col_name */ + { 198, -1 }, /* (150) col_name ::= column_name */ + { 164, -2 }, /* (151) cmd ::= SHOW DNODES */ + { 164, -2 }, /* (152) cmd ::= SHOW USERS */ + { 164, -2 }, /* (153) cmd ::= SHOW DATABASES */ + { 164, -4 }, /* (154) cmd ::= SHOW db_name_cond_opt TABLES like_pattern_opt */ + { 164, -4 }, /* (155) cmd ::= SHOW db_name_cond_opt STABLES like_pattern_opt */ + { 164, -3 }, /* (156) cmd ::= SHOW db_name_cond_opt VGROUPS */ + { 164, -2 }, /* (157) cmd ::= SHOW MNODES */ + { 164, -2 }, /* (158) cmd ::= SHOW MODULES */ + { 164, -2 }, /* (159) cmd ::= SHOW QNODES */ + { 164, -2 }, /* (160) cmd ::= SHOW FUNCTIONS */ + { 164, -5 }, /* (161) cmd ::= SHOW INDEXES FROM table_name_cond from_db_opt */ + { 164, -2 }, /* (162) cmd ::= SHOW STREAMS */ + { 199, 0 }, /* (163) db_name_cond_opt ::= */ + { 199, -2 }, /* (164) db_name_cond_opt ::= db_name NK_DOT */ + { 200, 0 }, /* (165) like_pattern_opt ::= */ + { 200, -2 }, /* (166) like_pattern_opt ::= LIKE NK_STRING */ + { 201, -1 }, /* (167) table_name_cond ::= table_name */ + { 202, 0 }, /* (168) from_db_opt ::= */ + { 202, -2 }, /* (169) from_db_opt ::= FROM db_name */ + { 196, -1 }, /* (170) func_name_list ::= func_name */ + { 196, -3 }, /* (171) func_name_list ::= func_name_list NK_COMMA col_name */ + { 203, -1 }, /* (172) func_name ::= function_name */ + { 164, -8 }, /* (173) cmd ::= CREATE SMA INDEX not_exists_opt index_name ON table_name index_options */ + { 164, -10 }, /* (174) cmd ::= CREATE FULLTEXT INDEX not_exists_opt index_name ON table_name NK_LP col_name_list NK_RP */ + { 164, -6 }, /* (175) cmd ::= DROP INDEX exists_opt index_name ON table_name */ + { 206, 0 }, /* (176) index_options ::= */ + { 206, -9 }, /* (177) index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_RP sliding_opt */ + { 206, -11 }, /* (178) index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt */ + { 207, -1 }, /* (179) func_list ::= func */ + { 207, -3 }, /* (180) func_list ::= func_list NK_COMMA func */ + { 210, -4 }, /* (181) func ::= function_name NK_LP expression_list NK_RP */ + { 164, -6 }, /* (182) cmd ::= CREATE TOPIC not_exists_opt topic_name AS query_expression */ + { 164, -6 }, /* (183) cmd ::= CREATE TOPIC not_exists_opt topic_name AS db_name */ + { 164, -4 }, /* (184) cmd ::= DROP TOPIC exists_opt topic_name */ + { 164, -1 }, /* (185) cmd ::= query_expression */ + { 167, -1 }, /* (186) literal ::= NK_INTEGER */ + { 167, -1 }, /* (187) literal ::= NK_FLOAT */ + { 167, -1 }, /* (188) literal ::= NK_STRING */ + { 167, -1 }, /* (189) literal ::= NK_BOOL */ + { 167, -2 }, /* (190) literal ::= TIMESTAMP NK_STRING */ + { 167, -1 }, /* (191) literal ::= duration_literal */ + { 208, -1 }, /* (192) duration_literal ::= NK_VARIABLE */ + { 214, -1 }, /* (193) signed ::= NK_INTEGER */ + { 214, -2 }, /* (194) signed ::= NK_PLUS NK_INTEGER */ + { 214, -2 }, /* (195) signed ::= NK_MINUS NK_INTEGER */ + { 214, -1 }, /* (196) signed ::= NK_FLOAT */ + { 214, -2 }, /* (197) signed ::= NK_PLUS NK_FLOAT */ + { 214, -2 }, /* (198) signed ::= NK_MINUS NK_FLOAT */ + { 215, -1 }, /* (199) signed_literal ::= signed */ + { 215, -1 }, /* (200) signed_literal ::= NK_STRING */ + { 215, -1 }, /* (201) signed_literal ::= NK_BOOL */ + { 215, -2 }, /* (202) signed_literal ::= TIMESTAMP NK_STRING */ + { 215, -1 }, /* (203) signed_literal ::= duration_literal */ + { 191, -1 }, /* (204) literal_list ::= signed_literal */ + { 191, -3 }, /* (205) literal_list ::= literal_list NK_COMMA signed_literal */ + { 173, -1 }, /* (206) db_name ::= NK_ID */ + { 194, -1 }, /* (207) table_name ::= NK_ID */ + { 187, -1 }, /* (208) column_name ::= NK_ID */ + { 204, -1 }, /* (209) function_name ::= NK_ID */ + { 216, -1 }, /* (210) table_alias ::= NK_ID */ + { 217, -1 }, /* (211) column_alias ::= NK_ID */ + { 169, -1 }, /* (212) user_name ::= NK_ID */ + { 205, -1 }, /* (213) index_name ::= NK_ID */ + { 212, -1 }, /* (214) topic_name ::= NK_ID */ + { 218, -1 }, /* (215) expression ::= literal */ + { 218, -1 }, /* (216) expression ::= column_reference */ + { 218, -4 }, /* (217) expression ::= function_name NK_LP expression_list NK_RP */ + { 218, -4 }, /* (218) expression ::= function_name NK_LP NK_STAR NK_RP */ + { 218, -1 }, /* (219) expression ::= subquery */ + { 218, -3 }, /* (220) expression ::= NK_LP expression NK_RP */ + { 218, -2 }, /* (221) expression ::= NK_PLUS expression */ + { 218, -2 }, /* (222) expression ::= NK_MINUS expression */ + { 218, -3 }, /* (223) expression ::= expression NK_PLUS expression */ + { 218, -3 }, /* (224) expression ::= expression NK_MINUS expression */ + { 218, -3 }, /* (225) expression ::= expression NK_STAR expression */ + { 218, -3 }, /* (226) expression ::= expression NK_SLASH expression */ + { 218, -3 }, /* (227) expression ::= expression NK_REM expression */ + { 211, -1 }, /* (228) expression_list ::= expression */ + { 211, -3 }, /* (229) expression_list ::= expression_list NK_COMMA expression */ + { 219, -1 }, /* (230) column_reference ::= column_name */ + { 219, -3 }, /* (231) column_reference ::= table_name NK_DOT column_name */ + { 221, -3 }, /* (232) predicate ::= expression compare_op expression */ + { 221, -5 }, /* (233) predicate ::= expression BETWEEN expression AND expression */ + { 221, -6 }, /* (234) predicate ::= expression NOT BETWEEN expression AND expression */ + { 221, -3 }, /* (235) predicate ::= expression IS NULL */ + { 221, -4 }, /* (236) predicate ::= expression IS NOT NULL */ + { 221, -3 }, /* (237) predicate ::= expression in_op in_predicate_value */ + { 222, -1 }, /* (238) compare_op ::= NK_LT */ + { 222, -1 }, /* (239) compare_op ::= NK_GT */ + { 222, -1 }, /* (240) compare_op ::= NK_LE */ + { 222, -1 }, /* (241) compare_op ::= NK_GE */ + { 222, -1 }, /* (242) compare_op ::= NK_NE */ + { 222, -1 }, /* (243) compare_op ::= NK_EQ */ + { 222, -1 }, /* (244) compare_op ::= LIKE */ + { 222, -2 }, /* (245) compare_op ::= NOT LIKE */ + { 222, -1 }, /* (246) compare_op ::= MATCH */ + { 222, -1 }, /* (247) compare_op ::= NMATCH */ + { 223, -1 }, /* (248) in_op ::= IN */ + { 223, -2 }, /* (249) in_op ::= NOT IN */ + { 224, -3 }, /* (250) in_predicate_value ::= NK_LP expression_list NK_RP */ + { 225, -1 }, /* (251) boolean_value_expression ::= boolean_primary */ + { 225, -2 }, /* (252) boolean_value_expression ::= NOT boolean_primary */ + { 225, -3 }, /* (253) boolean_value_expression ::= boolean_value_expression OR boolean_value_expression */ + { 225, -3 }, /* (254) boolean_value_expression ::= boolean_value_expression AND boolean_value_expression */ + { 226, -1 }, /* (255) boolean_primary ::= predicate */ + { 226, -3 }, /* (256) boolean_primary ::= NK_LP boolean_value_expression NK_RP */ + { 227, -1 }, /* (257) common_expression ::= expression */ + { 227, -1 }, /* (258) common_expression ::= boolean_value_expression */ + { 228, -2 }, /* (259) from_clause ::= FROM table_reference_list */ + { 229, -1 }, /* (260) table_reference_list ::= table_reference */ + { 229, -3 }, /* (261) table_reference_list ::= table_reference_list NK_COMMA table_reference */ + { 230, -1 }, /* (262) table_reference ::= table_primary */ + { 230, -1 }, /* (263) table_reference ::= joined_table */ + { 231, -2 }, /* (264) table_primary ::= table_name alias_opt */ + { 231, -4 }, /* (265) table_primary ::= db_name NK_DOT table_name alias_opt */ + { 231, -2 }, /* (266) table_primary ::= subquery alias_opt */ + { 231, -1 }, /* (267) table_primary ::= parenthesized_joined_table */ + { 233, 0 }, /* (268) alias_opt ::= */ + { 233, -1 }, /* (269) alias_opt ::= table_alias */ + { 233, -2 }, /* (270) alias_opt ::= AS table_alias */ + { 234, -3 }, /* (271) parenthesized_joined_table ::= NK_LP joined_table NK_RP */ + { 234, -3 }, /* (272) parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP */ + { 232, -6 }, /* (273) joined_table ::= table_reference join_type JOIN table_reference ON search_condition */ + { 235, 0 }, /* (274) join_type ::= */ + { 235, -1 }, /* (275) join_type ::= INNER */ + { 237, -9 }, /* (276) query_specification ::= SELECT set_quantifier_opt select_list from_clause where_clause_opt partition_by_clause_opt twindow_clause_opt group_by_clause_opt having_clause_opt */ + { 238, 0 }, /* (277) set_quantifier_opt ::= */ + { 238, -1 }, /* (278) set_quantifier_opt ::= DISTINCT */ + { 238, -1 }, /* (279) set_quantifier_opt ::= ALL */ + { 239, -1 }, /* (280) select_list ::= NK_STAR */ + { 239, -1 }, /* (281) select_list ::= select_sublist */ + { 245, -1 }, /* (282) select_sublist ::= select_item */ + { 245, -3 }, /* (283) select_sublist ::= select_sublist NK_COMMA select_item */ + { 246, -1 }, /* (284) select_item ::= common_expression */ + { 246, -2 }, /* (285) select_item ::= common_expression column_alias */ + { 246, -3 }, /* (286) select_item ::= common_expression AS column_alias */ + { 246, -3 }, /* (287) select_item ::= table_name NK_DOT NK_STAR */ + { 240, 0 }, /* (288) where_clause_opt ::= */ + { 240, -2 }, /* (289) where_clause_opt ::= WHERE search_condition */ + { 241, 0 }, /* (290) partition_by_clause_opt ::= */ + { 241, -3 }, /* (291) partition_by_clause_opt ::= PARTITION BY expression_list */ + { 242, 0 }, /* (292) twindow_clause_opt ::= */ + { 242, -6 }, /* (293) twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA duration_literal NK_RP */ + { 242, -4 }, /* (294) twindow_clause_opt ::= STATE_WINDOW NK_LP column_reference NK_RP */ + { 242, -6 }, /* (295) twindow_clause_opt ::= INTERVAL NK_LP duration_literal NK_RP sliding_opt fill_opt */ + { 242, -8 }, /* (296) twindow_clause_opt ::= INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt fill_opt */ + { 209, 0 }, /* (297) sliding_opt ::= */ + { 209, -4 }, /* (298) sliding_opt ::= SLIDING NK_LP duration_literal NK_RP */ + { 247, 0 }, /* (299) fill_opt ::= */ + { 247, -4 }, /* (300) fill_opt ::= FILL NK_LP fill_mode NK_RP */ + { 247, -6 }, /* (301) fill_opt ::= FILL NK_LP VALUE NK_COMMA literal_list NK_RP */ + { 248, -1 }, /* (302) fill_mode ::= NONE */ + { 248, -1 }, /* (303) fill_mode ::= PREV */ + { 248, -1 }, /* (304) fill_mode ::= NULL */ + { 248, -1 }, /* (305) fill_mode ::= LINEAR */ + { 248, -1 }, /* (306) fill_mode ::= NEXT */ + { 243, 0 }, /* (307) group_by_clause_opt ::= */ + { 243, -3 }, /* (308) group_by_clause_opt ::= GROUP BY group_by_list */ + { 249, -1 }, /* (309) group_by_list ::= expression */ + { 249, -3 }, /* (310) group_by_list ::= group_by_list NK_COMMA expression */ + { 244, 0 }, /* (311) having_clause_opt ::= */ + { 244, -2 }, /* (312) having_clause_opt ::= HAVING search_condition */ + { 213, -4 }, /* (313) query_expression ::= query_expression_body order_by_clause_opt slimit_clause_opt limit_clause_opt */ + { 250, -1 }, /* (314) query_expression_body ::= query_primary */ + { 250, -4 }, /* (315) query_expression_body ::= query_expression_body UNION ALL query_expression_body */ + { 254, -1 }, /* (316) query_primary ::= query_specification */ + { 251, 0 }, /* (317) order_by_clause_opt ::= */ + { 251, -3 }, /* (318) order_by_clause_opt ::= ORDER BY sort_specification_list */ + { 252, 0 }, /* (319) slimit_clause_opt ::= */ + { 252, -2 }, /* (320) slimit_clause_opt ::= SLIMIT NK_INTEGER */ + { 252, -4 }, /* (321) slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER */ + { 252, -4 }, /* (322) slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER */ + { 253, 0 }, /* (323) limit_clause_opt ::= */ + { 253, -2 }, /* (324) limit_clause_opt ::= LIMIT NK_INTEGER */ + { 253, -4 }, /* (325) limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER */ + { 253, -4 }, /* (326) limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER */ + { 220, -3 }, /* (327) subquery ::= NK_LP query_expression NK_RP */ + { 236, -1 }, /* (328) search_condition ::= common_expression */ + { 255, -1 }, /* (329) sort_specification_list ::= sort_specification */ + { 255, -3 }, /* (330) sort_specification_list ::= sort_specification_list NK_COMMA sort_specification */ + { 256, -3 }, /* (331) sort_specification ::= expression ordering_specification_opt null_ordering_opt */ + { 257, 0 }, /* (332) ordering_specification_opt ::= */ + { 257, -1 }, /* (333) ordering_specification_opt ::= ASC */ + { 257, -1 }, /* (334) ordering_specification_opt ::= DESC */ + { 258, 0 }, /* (335) null_ordering_opt ::= */ + { 258, -2 }, /* (336) null_ordering_opt ::= NULLS FIRST */ + { 258, -2 }, /* (337) null_ordering_opt ::= NULLS LAST */ }; static void yy_accept(yyParser*); /* Forward Declaration */ @@ -2296,11 +2294,11 @@ static YYACTIONTYPE yy_reduce( YYMINORTYPE yylhsminor; case 0: /* cmd ::= CREATE ACCOUNT NK_ID PASS NK_STRING account_options */ { pCxt->valid = false; generateSyntaxErrMsg(&pCxt->msgBuf, TSDB_CODE_PAR_EXPRIE_STATEMENT); } - yy_destructor(yypParser,164,&yymsp[0].minor); + yy_destructor(yypParser,165,&yymsp[0].minor); break; case 1: /* cmd ::= ALTER ACCOUNT NK_ID alter_account_options */ { pCxt->valid = false; generateSyntaxErrMsg(&pCxt->msgBuf, TSDB_CODE_PAR_EXPRIE_STATEMENT); } - yy_destructor(yypParser,165,&yymsp[0].minor); + yy_destructor(yypParser,166,&yymsp[0].minor); break; case 2: /* account_options ::= */ { } @@ -2314,20 +2312,20 @@ static YYACTIONTYPE yy_reduce( case 9: /* account_options ::= account_options USERS literal */ yytestcase(yyruleno==9); case 10: /* account_options ::= account_options CONNS literal */ yytestcase(yyruleno==10); case 11: /* account_options ::= account_options STATE literal */ yytestcase(yyruleno==11); -{ yy_destructor(yypParser,164,&yymsp[-2].minor); +{ yy_destructor(yypParser,165,&yymsp[-2].minor); { } - yy_destructor(yypParser,166,&yymsp[0].minor); + yy_destructor(yypParser,167,&yymsp[0].minor); } break; case 12: /* alter_account_options ::= alter_account_option */ -{ yy_destructor(yypParser,167,&yymsp[0].minor); +{ yy_destructor(yypParser,168,&yymsp[0].minor); { } } break; case 13: /* alter_account_options ::= alter_account_options alter_account_option */ -{ yy_destructor(yypParser,165,&yymsp[-1].minor); +{ yy_destructor(yypParser,166,&yymsp[-1].minor); { } - yy_destructor(yypParser,167,&yymsp[0].minor); + yy_destructor(yypParser,168,&yymsp[0].minor); } break; case 14: /* alter_account_option ::= PASS literal */ @@ -2341,31 +2339,31 @@ static YYACTIONTYPE yy_reduce( case 22: /* alter_account_option ::= CONNS literal */ yytestcase(yyruleno==22); case 23: /* alter_account_option ::= STATE literal */ yytestcase(yyruleno==23); { } - yy_destructor(yypParser,166,&yymsp[0].minor); + yy_destructor(yypParser,167,&yymsp[0].minor); break; case 24: /* cmd ::= CREATE USER user_name PASS NK_STRING */ -{ pCxt->pRootNode = createCreateUserStmt(pCxt, &yymsp[-2].minor.yy149, &yymsp[0].minor.yy0); } +{ pCxt->pRootNode = createCreateUserStmt(pCxt, &yymsp[-2].minor.yy183, &yymsp[0].minor.yy0); } break; case 25: /* cmd ::= ALTER USER user_name PASS NK_STRING */ -{ pCxt->pRootNode = createAlterUserStmt(pCxt, &yymsp[-2].minor.yy149, TSDB_ALTER_USER_PASSWD, &yymsp[0].minor.yy0); } +{ pCxt->pRootNode = createAlterUserStmt(pCxt, &yymsp[-2].minor.yy183, TSDB_ALTER_USER_PASSWD, &yymsp[0].minor.yy0); } break; case 26: /* cmd ::= ALTER USER user_name PRIVILEGE NK_STRING */ -{ pCxt->pRootNode = createAlterUserStmt(pCxt, &yymsp[-2].minor.yy149, TSDB_ALTER_USER_PRIVILEGES, &yymsp[0].minor.yy0); } +{ pCxt->pRootNode = createAlterUserStmt(pCxt, &yymsp[-2].minor.yy183, TSDB_ALTER_USER_PRIVILEGES, &yymsp[0].minor.yy0); } break; case 27: /* cmd ::= DROP USER user_name */ -{ pCxt->pRootNode = createDropUserStmt(pCxt, &yymsp[0].minor.yy149); } +{ pCxt->pRootNode = createDropUserStmt(pCxt, &yymsp[0].minor.yy183); } break; case 28: /* cmd ::= CREATE DNODE dnode_endpoint */ -{ pCxt->pRootNode = createCreateDnodeStmt(pCxt, &yymsp[0].minor.yy149, NULL); } +{ pCxt->pRootNode = createCreateDnodeStmt(pCxt, &yymsp[0].minor.yy183, NULL); } break; case 29: /* cmd ::= CREATE DNODE dnode_host_name PORT NK_INTEGER */ -{ pCxt->pRootNode = createCreateDnodeStmt(pCxt, &yymsp[-2].minor.yy149, &yymsp[0].minor.yy0); } +{ pCxt->pRootNode = createCreateDnodeStmt(pCxt, &yymsp[-2].minor.yy183, &yymsp[0].minor.yy0); } break; case 30: /* cmd ::= DROP DNODE NK_INTEGER */ { pCxt->pRootNode = createDropDnodeStmt(pCxt, &yymsp[0].minor.yy0); } break; case 31: /* cmd ::= DROP DNODE dnode_endpoint */ -{ pCxt->pRootNode = createDropDnodeStmt(pCxt, &yymsp[0].minor.yy149); } +{ pCxt->pRootNode = createDropDnodeStmt(pCxt, &yymsp[0].minor.yy183); } break; case 32: /* cmd ::= ALTER DNODE NK_INTEGER NK_STRING */ { pCxt->pRootNode = createAlterDnodeStmt(pCxt, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0, NULL); } @@ -2382,17 +2380,17 @@ static YYACTIONTYPE yy_reduce( case 36: /* dnode_endpoint ::= NK_STRING */ case 37: /* dnode_host_name ::= NK_ID */ yytestcase(yyruleno==37); case 38: /* dnode_host_name ::= NK_IPTOKEN */ yytestcase(yyruleno==38); - case 205: /* db_name ::= NK_ID */ yytestcase(yyruleno==205); - case 206: /* table_name ::= NK_ID */ yytestcase(yyruleno==206); - case 207: /* column_name ::= NK_ID */ yytestcase(yyruleno==207); - case 208: /* function_name ::= NK_ID */ yytestcase(yyruleno==208); - case 209: /* table_alias ::= NK_ID */ yytestcase(yyruleno==209); - case 210: /* column_alias ::= NK_ID */ yytestcase(yyruleno==210); - case 211: /* user_name ::= NK_ID */ yytestcase(yyruleno==211); - case 212: /* index_name ::= NK_ID */ yytestcase(yyruleno==212); - case 213: /* topic_name ::= NK_ID */ yytestcase(yyruleno==213); -{ yylhsminor.yy149 = yymsp[0].minor.yy0; } - yymsp[0].minor.yy149 = yylhsminor.yy149; + case 206: /* db_name ::= NK_ID */ yytestcase(yyruleno==206); + case 207: /* table_name ::= NK_ID */ yytestcase(yyruleno==207); + case 208: /* column_name ::= NK_ID */ yytestcase(yyruleno==208); + case 209: /* function_name ::= NK_ID */ yytestcase(yyruleno==209); + case 210: /* table_alias ::= NK_ID */ yytestcase(yyruleno==210); + case 211: /* column_alias ::= NK_ID */ yytestcase(yyruleno==211); + case 212: /* user_name ::= NK_ID */ yytestcase(yyruleno==212); + case 213: /* index_name ::= NK_ID */ yytestcase(yyruleno==213); + case 214: /* topic_name ::= NK_ID */ yytestcase(yyruleno==214); +{ yylhsminor.yy183 = yymsp[0].minor.yy0; } + yymsp[0].minor.yy183 = yylhsminor.yy183; break; case 39: /* cmd ::= ALTER LOCAL NK_STRING */ { pCxt->pRootNode = createAlterLocalStmt(pCxt, &yymsp[0].minor.yy0, NULL); } @@ -2407,922 +2405,926 @@ static YYACTIONTYPE yy_reduce( { pCxt->pRootNode = createDropQnodeStmt(pCxt, &yymsp[0].minor.yy0); } break; case 43: /* cmd ::= CREATE DATABASE not_exists_opt db_name db_options */ -{ pCxt->pRootNode = createCreateDatabaseStmt(pCxt, yymsp[-2].minor.yy497, &yymsp[-1].minor.yy149, yymsp[0].minor.yy140); } +{ pCxt->pRootNode = createCreateDatabaseStmt(pCxt, yymsp[-2].minor.yy215, &yymsp[-1].minor.yy183, yymsp[0].minor.yy378); } break; case 44: /* cmd ::= DROP DATABASE exists_opt db_name */ -{ pCxt->pRootNode = createDropDatabaseStmt(pCxt, yymsp[-1].minor.yy497, &yymsp[0].minor.yy149); } +{ pCxt->pRootNode = createDropDatabaseStmt(pCxt, yymsp[-1].minor.yy215, &yymsp[0].minor.yy183); } break; case 45: /* cmd ::= USE db_name */ -{ pCxt->pRootNode = createUseDatabaseStmt(pCxt, &yymsp[0].minor.yy149); } +{ pCxt->pRootNode = createUseDatabaseStmt(pCxt, &yymsp[0].minor.yy183); } break; case 46: /* cmd ::= ALTER DATABASE db_name alter_db_options */ -{ pCxt->pRootNode = createAlterDatabaseStmt(pCxt, &yymsp[-1].minor.yy149, yymsp[0].minor.yy140); } +{ pCxt->pRootNode = createAlterDatabaseStmt(pCxt, &yymsp[-1].minor.yy183, yymsp[0].minor.yy378); } break; case 47: /* not_exists_opt ::= IF NOT EXISTS */ -{ yymsp[-2].minor.yy497 = true; } +{ yymsp[-2].minor.yy215 = true; } break; case 48: /* not_exists_opt ::= */ case 50: /* exists_opt ::= */ yytestcase(yyruleno==50); - case 276: /* set_quantifier_opt ::= */ yytestcase(yyruleno==276); -{ yymsp[1].minor.yy497 = false; } + case 277: /* set_quantifier_opt ::= */ yytestcase(yyruleno==277); +{ yymsp[1].minor.yy215 = false; } break; case 49: /* exists_opt ::= IF EXISTS */ -{ yymsp[-1].minor.yy497 = true; } +{ yymsp[-1].minor.yy215 = true; } break; case 51: /* db_options ::= */ -{ yymsp[1].minor.yy140 = createDefaultDatabaseOptions(pCxt); } +{ yymsp[1].minor.yy378 = createDefaultDatabaseOptions(pCxt); } break; case 52: /* db_options ::= db_options BLOCKS NK_INTEGER */ -{ yylhsminor.yy140 = setDatabaseOption(pCxt, yymsp[-2].minor.yy140, DB_OPTION_BLOCKS, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; +{ yylhsminor.yy378 = setDatabaseOption(pCxt, yymsp[-2].minor.yy378, DB_OPTION_BLOCKS, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; case 53: /* db_options ::= db_options CACHE NK_INTEGER */ -{ yylhsminor.yy140 = setDatabaseOption(pCxt, yymsp[-2].minor.yy140, DB_OPTION_CACHE, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; +{ yylhsminor.yy378 = setDatabaseOption(pCxt, yymsp[-2].minor.yy378, DB_OPTION_CACHE, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; case 54: /* db_options ::= db_options CACHELAST NK_INTEGER */ -{ yylhsminor.yy140 = setDatabaseOption(pCxt, yymsp[-2].minor.yy140, DB_OPTION_CACHELAST, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; +{ yylhsminor.yy378 = setDatabaseOption(pCxt, yymsp[-2].minor.yy378, DB_OPTION_CACHELAST, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; case 55: /* db_options ::= db_options COMP NK_INTEGER */ -{ yylhsminor.yy140 = setDatabaseOption(pCxt, yymsp[-2].minor.yy140, DB_OPTION_COMP, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; +{ yylhsminor.yy378 = setDatabaseOption(pCxt, yymsp[-2].minor.yy378, DB_OPTION_COMP, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; case 56: /* db_options ::= db_options DAYS NK_INTEGER */ -{ yylhsminor.yy140 = setDatabaseOption(pCxt, yymsp[-2].minor.yy140, DB_OPTION_DAYS, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; +{ yylhsminor.yy378 = setDatabaseOption(pCxt, yymsp[-2].minor.yy378, DB_OPTION_DAYS, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; case 57: /* db_options ::= db_options FSYNC NK_INTEGER */ -{ yylhsminor.yy140 = setDatabaseOption(pCxt, yymsp[-2].minor.yy140, DB_OPTION_FSYNC, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; +{ yylhsminor.yy378 = setDatabaseOption(pCxt, yymsp[-2].minor.yy378, DB_OPTION_FSYNC, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; case 58: /* db_options ::= db_options MAXROWS NK_INTEGER */ -{ yylhsminor.yy140 = setDatabaseOption(pCxt, yymsp[-2].minor.yy140, DB_OPTION_MAXROWS, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; +{ yylhsminor.yy378 = setDatabaseOption(pCxt, yymsp[-2].minor.yy378, DB_OPTION_MAXROWS, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; case 59: /* db_options ::= db_options MINROWS NK_INTEGER */ -{ yylhsminor.yy140 = setDatabaseOption(pCxt, yymsp[-2].minor.yy140, DB_OPTION_MINROWS, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; +{ yylhsminor.yy378 = setDatabaseOption(pCxt, yymsp[-2].minor.yy378, DB_OPTION_MINROWS, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; case 60: /* db_options ::= db_options KEEP NK_INTEGER */ -{ yylhsminor.yy140 = setDatabaseOption(pCxt, yymsp[-2].minor.yy140, DB_OPTION_KEEP, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; +{ yylhsminor.yy378 = setDatabaseOption(pCxt, yymsp[-2].minor.yy378, DB_OPTION_KEEP, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; case 61: /* db_options ::= db_options PRECISION NK_STRING */ -{ yylhsminor.yy140 = setDatabaseOption(pCxt, yymsp[-2].minor.yy140, DB_OPTION_PRECISION, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; +{ yylhsminor.yy378 = setDatabaseOption(pCxt, yymsp[-2].minor.yy378, DB_OPTION_PRECISION, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; case 62: /* db_options ::= db_options QUORUM NK_INTEGER */ -{ yylhsminor.yy140 = setDatabaseOption(pCxt, yymsp[-2].minor.yy140, DB_OPTION_QUORUM, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; +{ yylhsminor.yy378 = setDatabaseOption(pCxt, yymsp[-2].minor.yy378, DB_OPTION_QUORUM, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; case 63: /* db_options ::= db_options REPLICA NK_INTEGER */ -{ yylhsminor.yy140 = setDatabaseOption(pCxt, yymsp[-2].minor.yy140, DB_OPTION_REPLICA, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; +{ yylhsminor.yy378 = setDatabaseOption(pCxt, yymsp[-2].minor.yy378, DB_OPTION_REPLICA, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; case 64: /* db_options ::= db_options TTL NK_INTEGER */ -{ yylhsminor.yy140 = setDatabaseOption(pCxt, yymsp[-2].minor.yy140, DB_OPTION_TTL, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; +{ yylhsminor.yy378 = setDatabaseOption(pCxt, yymsp[-2].minor.yy378, DB_OPTION_TTL, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; case 65: /* db_options ::= db_options WAL NK_INTEGER */ -{ yylhsminor.yy140 = setDatabaseOption(pCxt, yymsp[-2].minor.yy140, DB_OPTION_WAL, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; +{ yylhsminor.yy378 = setDatabaseOption(pCxt, yymsp[-2].minor.yy378, DB_OPTION_WAL, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; case 66: /* db_options ::= db_options VGROUPS NK_INTEGER */ -{ yylhsminor.yy140 = setDatabaseOption(pCxt, yymsp[-2].minor.yy140, DB_OPTION_VGROUPS, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; +{ yylhsminor.yy378 = setDatabaseOption(pCxt, yymsp[-2].minor.yy378, DB_OPTION_VGROUPS, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; case 67: /* db_options ::= db_options SINGLE_STABLE NK_INTEGER */ -{ yylhsminor.yy140 = setDatabaseOption(pCxt, yymsp[-2].minor.yy140, DB_OPTION_SINGLE_STABLE, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; +{ yylhsminor.yy378 = setDatabaseOption(pCxt, yymsp[-2].minor.yy378, DB_OPTION_SINGLE_STABLE, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; case 68: /* db_options ::= db_options STREAM_MODE NK_INTEGER */ -{ yylhsminor.yy140 = setDatabaseOption(pCxt, yymsp[-2].minor.yy140, DB_OPTION_STREAM_MODE, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; +{ yylhsminor.yy378 = setDatabaseOption(pCxt, yymsp[-2].minor.yy378, DB_OPTION_STREAM_MODE, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; case 69: /* db_options ::= db_options RETENTIONS NK_STRING */ -{ yylhsminor.yy140 = setDatabaseOption(pCxt, yymsp[-2].minor.yy140, DB_OPTION_RETENTIONS, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; +{ yylhsminor.yy378 = setDatabaseOption(pCxt, yymsp[-2].minor.yy378, DB_OPTION_RETENTIONS, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; + break; + case 70: /* alter_db_options ::= alter_db_option */ +{ yylhsminor.yy378 = createDefaultAlterDatabaseOptions(pCxt); yylhsminor.yy378 = setDatabaseOption(pCxt, yylhsminor.yy378, yymsp[0].minor.yy11.type, &yymsp[0].minor.yy11.val); } + yymsp[0].minor.yy378 = yylhsminor.yy378; break; - case 70: /* db_options ::= db_options FILE_FACTOR NK_FLOAT */ -{ yylhsminor.yy140 = setDatabaseOption(pCxt, yymsp[-2].minor.yy140, DB_OPTION_FILE_FACTOR, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; + case 71: /* alter_db_options ::= alter_db_options alter_db_option */ +{ yylhsminor.yy378 = setDatabaseOption(pCxt, yymsp[-1].minor.yy378, yymsp[0].minor.yy11.type, &yymsp[0].minor.yy11.val); } + yymsp[-1].minor.yy378 = yylhsminor.yy378; break; - case 71: /* alter_db_options ::= alter_db_option */ -{ yylhsminor.yy140 = createDefaultAlterDatabaseOptions(pCxt); yylhsminor.yy140 = setDatabaseOption(pCxt, yylhsminor.yy140, yymsp[0].minor.yy233.type, &yymsp[0].minor.yy233.val); } - yymsp[0].minor.yy140 = yylhsminor.yy140; + case 72: /* alter_db_option ::= BLOCKS NK_INTEGER */ +{ yymsp[-1].minor.yy11.type = DB_OPTION_BLOCKS; yymsp[-1].minor.yy11.val = yymsp[0].minor.yy0; } break; - case 72: /* alter_db_options ::= alter_db_options alter_db_option */ -{ yylhsminor.yy140 = setDatabaseOption(pCxt, yymsp[-1].minor.yy140, yymsp[0].minor.yy233.type, &yymsp[0].minor.yy233.val); } - yymsp[-1].minor.yy140 = yylhsminor.yy140; + case 73: /* alter_db_option ::= FSYNC NK_INTEGER */ +{ yymsp[-1].minor.yy11.type = DB_OPTION_FSYNC; yymsp[-1].minor.yy11.val = yymsp[0].minor.yy0; } + break; + case 74: /* alter_db_option ::= KEEP NK_INTEGER */ +{ yymsp[-1].minor.yy11.type = DB_OPTION_KEEP; yymsp[-1].minor.yy11.val = yymsp[0].minor.yy0; } + break; + case 75: /* alter_db_option ::= WAL NK_INTEGER */ +{ yymsp[-1].minor.yy11.type = DB_OPTION_WAL; yymsp[-1].minor.yy11.val = yymsp[0].minor.yy0; } break; - case 73: /* alter_db_option ::= BLOCKS NK_INTEGER */ -{ yymsp[-1].minor.yy233.type = DB_OPTION_BLOCKS; yymsp[-1].minor.yy233.val = yymsp[0].minor.yy0; } + case 76: /* alter_db_option ::= QUORUM NK_INTEGER */ +{ yymsp[-1].minor.yy11.type = DB_OPTION_QUORUM; yymsp[-1].minor.yy11.val = yymsp[0].minor.yy0; } break; - case 74: /* alter_db_option ::= FSYNC NK_INTEGER */ -{ yymsp[-1].minor.yy233.type = DB_OPTION_FSYNC; yymsp[-1].minor.yy233.val = yymsp[0].minor.yy0; } - break; - case 75: /* alter_db_option ::= KEEP NK_INTEGER */ -{ yymsp[-1].minor.yy233.type = DB_OPTION_KEEP; yymsp[-1].minor.yy233.val = yymsp[0].minor.yy0; } - break; - case 76: /* alter_db_option ::= WAL NK_INTEGER */ -{ yymsp[-1].minor.yy233.type = DB_OPTION_WAL; yymsp[-1].minor.yy233.val = yymsp[0].minor.yy0; } + case 77: /* alter_db_option ::= CACHELAST NK_INTEGER */ +{ yymsp[-1].minor.yy11.type = DB_OPTION_CACHELAST; yymsp[-1].minor.yy11.val = yymsp[0].minor.yy0; } + break; + case 78: /* cmd ::= CREATE TABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def_opt table_options */ + case 80: /* cmd ::= CREATE STABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def table_options */ yytestcase(yyruleno==80); +{ pCxt->pRootNode = createCreateTableStmt(pCxt, yymsp[-6].minor.yy215, yymsp[-5].minor.yy378, yymsp[-3].minor.yy404, yymsp[-1].minor.yy404, yymsp[0].minor.yy378); } + break; + case 79: /* cmd ::= CREATE TABLE multi_create_clause */ +{ pCxt->pRootNode = createCreateMultiTableStmt(pCxt, yymsp[0].minor.yy404); } + break; + case 81: /* cmd ::= DROP TABLE multi_drop_clause */ +{ pCxt->pRootNode = createDropTableStmt(pCxt, yymsp[0].minor.yy404); } + break; + case 82: /* cmd ::= DROP STABLE exists_opt full_table_name */ +{ pCxt->pRootNode = createDropSuperTableStmt(pCxt, yymsp[-1].minor.yy215, yymsp[0].minor.yy378); } + break; + case 83: /* cmd ::= ALTER TABLE alter_table_clause */ + case 84: /* cmd ::= ALTER STABLE alter_table_clause */ yytestcase(yyruleno==84); + case 185: /* cmd ::= query_expression */ yytestcase(yyruleno==185); +{ pCxt->pRootNode = yymsp[0].minor.yy378; } + break; + case 85: /* alter_table_clause ::= full_table_name alter_table_options */ +{ yylhsminor.yy378 = createAlterTableOption(pCxt, yymsp[-1].minor.yy378, yymsp[0].minor.yy378); } + yymsp[-1].minor.yy378 = yylhsminor.yy378; + break; + case 86: /* alter_table_clause ::= full_table_name ADD COLUMN column_name type_name */ +{ yylhsminor.yy378 = createAlterTableAddModifyCol(pCxt, yymsp[-4].minor.yy378, TSDB_ALTER_TABLE_ADD_COLUMN, &yymsp[-1].minor.yy183, yymsp[0].minor.yy504); } + yymsp[-4].minor.yy378 = yylhsminor.yy378; + break; + case 87: /* alter_table_clause ::= full_table_name DROP COLUMN column_name */ +{ yylhsminor.yy378 = createAlterTableDropCol(pCxt, yymsp[-3].minor.yy378, TSDB_ALTER_TABLE_DROP_COLUMN, &yymsp[0].minor.yy183); } + yymsp[-3].minor.yy378 = yylhsminor.yy378; + break; + case 88: /* alter_table_clause ::= full_table_name MODIFY COLUMN column_name type_name */ +{ yylhsminor.yy378 = createAlterTableAddModifyCol(pCxt, yymsp[-4].minor.yy378, TSDB_ALTER_TABLE_UPDATE_COLUMN_BYTES, &yymsp[-1].minor.yy183, yymsp[0].minor.yy504); } + yymsp[-4].minor.yy378 = yylhsminor.yy378; + break; + case 89: /* alter_table_clause ::= full_table_name RENAME COLUMN column_name column_name */ +{ yylhsminor.yy378 = createAlterTableRenameCol(pCxt, yymsp[-4].minor.yy378, TSDB_ALTER_TABLE_UPDATE_COLUMN_NAME, &yymsp[-1].minor.yy183, &yymsp[0].minor.yy183); } + yymsp[-4].minor.yy378 = yylhsminor.yy378; break; - case 77: /* alter_db_option ::= QUORUM NK_INTEGER */ -{ yymsp[-1].minor.yy233.type = DB_OPTION_QUORUM; yymsp[-1].minor.yy233.val = yymsp[0].minor.yy0; } + case 90: /* alter_table_clause ::= full_table_name ADD TAG column_name type_name */ +{ yylhsminor.yy378 = createAlterTableAddModifyCol(pCxt, yymsp[-4].minor.yy378, TSDB_ALTER_TABLE_ADD_TAG, &yymsp[-1].minor.yy183, yymsp[0].minor.yy504); } + yymsp[-4].minor.yy378 = yylhsminor.yy378; break; - case 78: /* alter_db_option ::= CACHELAST NK_INTEGER */ -{ yymsp[-1].minor.yy233.type = DB_OPTION_CACHELAST; yymsp[-1].minor.yy233.val = yymsp[0].minor.yy0; } - break; - case 79: /* cmd ::= CREATE TABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def_opt table_options */ - case 81: /* cmd ::= CREATE STABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def table_options */ yytestcase(yyruleno==81); -{ pCxt->pRootNode = createCreateTableStmt(pCxt, yymsp[-6].minor.yy497, yymsp[-5].minor.yy140, yymsp[-3].minor.yy136, yymsp[-1].minor.yy136, yymsp[0].minor.yy140); } - break; - case 80: /* cmd ::= CREATE TABLE multi_create_clause */ -{ pCxt->pRootNode = createCreateMultiTableStmt(pCxt, yymsp[0].minor.yy136); } - break; - case 82: /* cmd ::= DROP TABLE multi_drop_clause */ -{ pCxt->pRootNode = createDropTableStmt(pCxt, yymsp[0].minor.yy136); } - break; - case 83: /* cmd ::= DROP STABLE exists_opt full_table_name */ -{ pCxt->pRootNode = createDropSuperTableStmt(pCxt, yymsp[-1].minor.yy497, yymsp[0].minor.yy140); } - break; - case 84: /* cmd ::= ALTER TABLE alter_table_clause */ - case 85: /* cmd ::= ALTER STABLE alter_table_clause */ yytestcase(yyruleno==85); - case 184: /* cmd ::= query_expression */ yytestcase(yyruleno==184); -{ pCxt->pRootNode = yymsp[0].minor.yy140; } - break; - case 86: /* alter_table_clause ::= full_table_name alter_table_options */ -{ yylhsminor.yy140 = createAlterTableOption(pCxt, yymsp[-1].minor.yy140, yymsp[0].minor.yy140); } - yymsp[-1].minor.yy140 = yylhsminor.yy140; - break; - case 87: /* alter_table_clause ::= full_table_name ADD COLUMN column_name type_name */ -{ yylhsminor.yy140 = createAlterTableAddModifyCol(pCxt, yymsp[-4].minor.yy140, TSDB_ALTER_TABLE_ADD_COLUMN, &yymsp[-1].minor.yy149, yymsp[0].minor.yy256); } - yymsp[-4].minor.yy140 = yylhsminor.yy140; - break; - case 88: /* alter_table_clause ::= full_table_name DROP COLUMN column_name */ -{ yylhsminor.yy140 = createAlterTableDropCol(pCxt, yymsp[-3].minor.yy140, TSDB_ALTER_TABLE_DROP_COLUMN, &yymsp[0].minor.yy149); } - yymsp[-3].minor.yy140 = yylhsminor.yy140; - break; - case 89: /* alter_table_clause ::= full_table_name MODIFY COLUMN column_name type_name */ -{ yylhsminor.yy140 = createAlterTableAddModifyCol(pCxt, yymsp[-4].minor.yy140, TSDB_ALTER_TABLE_UPDATE_COLUMN_BYTES, &yymsp[-1].minor.yy149, yymsp[0].minor.yy256); } - yymsp[-4].minor.yy140 = yylhsminor.yy140; - break; - case 90: /* alter_table_clause ::= full_table_name RENAME COLUMN column_name column_name */ -{ yylhsminor.yy140 = createAlterTableRenameCol(pCxt, yymsp[-4].minor.yy140, TSDB_ALTER_TABLE_UPDATE_COLUMN_NAME, &yymsp[-1].minor.yy149, &yymsp[0].minor.yy149); } - yymsp[-4].minor.yy140 = yylhsminor.yy140; + case 91: /* alter_table_clause ::= full_table_name DROP TAG column_name */ +{ yylhsminor.yy378 = createAlterTableDropCol(pCxt, yymsp[-3].minor.yy378, TSDB_ALTER_TABLE_DROP_TAG, &yymsp[0].minor.yy183); } + yymsp[-3].minor.yy378 = yylhsminor.yy378; break; - case 91: /* alter_table_clause ::= full_table_name ADD TAG column_name type_name */ -{ yylhsminor.yy140 = createAlterTableAddModifyCol(pCxt, yymsp[-4].minor.yy140, TSDB_ALTER_TABLE_ADD_TAG, &yymsp[-1].minor.yy149, yymsp[0].minor.yy256); } - yymsp[-4].minor.yy140 = yylhsminor.yy140; + case 92: /* alter_table_clause ::= full_table_name MODIFY TAG column_name type_name */ +{ yylhsminor.yy378 = createAlterTableAddModifyCol(pCxt, yymsp[-4].minor.yy378, TSDB_ALTER_TABLE_UPDATE_TAG_BYTES, &yymsp[-1].minor.yy183, yymsp[0].minor.yy504); } + yymsp[-4].minor.yy378 = yylhsminor.yy378; break; - case 92: /* alter_table_clause ::= full_table_name DROP TAG column_name */ -{ yylhsminor.yy140 = createAlterTableDropCol(pCxt, yymsp[-3].minor.yy140, TSDB_ALTER_TABLE_DROP_TAG, &yymsp[0].minor.yy149); } - yymsp[-3].minor.yy140 = yylhsminor.yy140; + case 93: /* alter_table_clause ::= full_table_name RENAME TAG column_name column_name */ +{ yylhsminor.yy378 = createAlterTableRenameCol(pCxt, yymsp[-4].minor.yy378, TSDB_ALTER_TABLE_UPDATE_TAG_NAME, &yymsp[-1].minor.yy183, &yymsp[0].minor.yy183); } + yymsp[-4].minor.yy378 = yylhsminor.yy378; break; - case 93: /* alter_table_clause ::= full_table_name MODIFY TAG column_name type_name */ -{ yylhsminor.yy140 = createAlterTableAddModifyCol(pCxt, yymsp[-4].minor.yy140, TSDB_ALTER_TABLE_UPDATE_TAG_BYTES, &yymsp[-1].minor.yy149, yymsp[0].minor.yy256); } - yymsp[-4].minor.yy140 = yylhsminor.yy140; + case 94: /* alter_table_clause ::= full_table_name SET TAG column_name NK_EQ literal */ +{ yylhsminor.yy378 = createAlterTableSetTag(pCxt, yymsp[-5].minor.yy378, &yymsp[-2].minor.yy183, yymsp[0].minor.yy378); } + yymsp[-5].minor.yy378 = yylhsminor.yy378; break; - case 94: /* alter_table_clause ::= full_table_name RENAME TAG column_name column_name */ -{ yylhsminor.yy140 = createAlterTableRenameCol(pCxt, yymsp[-4].minor.yy140, TSDB_ALTER_TABLE_UPDATE_TAG_NAME, &yymsp[-1].minor.yy149, &yymsp[0].minor.yy149); } - yymsp[-4].minor.yy140 = yylhsminor.yy140; + case 95: /* multi_create_clause ::= create_subtable_clause */ + case 98: /* multi_drop_clause ::= drop_table_clause */ yytestcase(yyruleno==98); + case 105: /* column_def_list ::= column_def */ yytestcase(yyruleno==105); + case 148: /* col_name_list ::= col_name */ yytestcase(yyruleno==148); + case 170: /* func_name_list ::= func_name */ yytestcase(yyruleno==170); + case 179: /* func_list ::= func */ yytestcase(yyruleno==179); + case 204: /* literal_list ::= signed_literal */ yytestcase(yyruleno==204); + case 282: /* select_sublist ::= select_item */ yytestcase(yyruleno==282); + case 329: /* sort_specification_list ::= sort_specification */ yytestcase(yyruleno==329); +{ yylhsminor.yy404 = createNodeList(pCxt, yymsp[0].minor.yy378); } + yymsp[0].minor.yy404 = yylhsminor.yy404; break; - case 95: /* alter_table_clause ::= full_table_name SET TAG column_name NK_EQ literal */ -{ yylhsminor.yy140 = createAlterTableSetTag(pCxt, yymsp[-5].minor.yy140, &yymsp[-2].minor.yy149, yymsp[0].minor.yy140); } - yymsp[-5].minor.yy140 = yylhsminor.yy140; + case 96: /* multi_create_clause ::= multi_create_clause create_subtable_clause */ + case 99: /* multi_drop_clause ::= multi_drop_clause drop_table_clause */ yytestcase(yyruleno==99); +{ yylhsminor.yy404 = addNodeToList(pCxt, yymsp[-1].minor.yy404, yymsp[0].minor.yy378); } + yymsp[-1].minor.yy404 = yylhsminor.yy404; break; - case 96: /* multi_create_clause ::= create_subtable_clause */ - case 99: /* multi_drop_clause ::= drop_table_clause */ yytestcase(yyruleno==99); - case 106: /* column_def_list ::= column_def */ yytestcase(yyruleno==106); - case 147: /* col_name_list ::= col_name */ yytestcase(yyruleno==147); - case 169: /* func_name_list ::= func_name */ yytestcase(yyruleno==169); - case 178: /* func_list ::= func */ yytestcase(yyruleno==178); - case 203: /* literal_list ::= signed_literal */ yytestcase(yyruleno==203); - case 281: /* select_sublist ::= select_item */ yytestcase(yyruleno==281); - case 328: /* sort_specification_list ::= sort_specification */ yytestcase(yyruleno==328); -{ yylhsminor.yy136 = createNodeList(pCxt, yymsp[0].minor.yy140); } - yymsp[0].minor.yy136 = yylhsminor.yy136; + case 97: /* create_subtable_clause ::= not_exists_opt full_table_name USING full_table_name specific_tags_opt TAGS NK_LP literal_list NK_RP */ +{ yylhsminor.yy378 = createCreateSubTableClause(pCxt, yymsp[-8].minor.yy215, yymsp[-7].minor.yy378, yymsp[-5].minor.yy378, yymsp[-4].minor.yy404, yymsp[-1].minor.yy404); } + yymsp[-8].minor.yy378 = yylhsminor.yy378; break; - case 97: /* multi_create_clause ::= multi_create_clause create_subtable_clause */ - case 100: /* multi_drop_clause ::= multi_drop_clause drop_table_clause */ yytestcase(yyruleno==100); -{ yylhsminor.yy136 = addNodeToList(pCxt, yymsp[-1].minor.yy136, yymsp[0].minor.yy140); } - yymsp[-1].minor.yy136 = yylhsminor.yy136; + case 100: /* drop_table_clause ::= exists_opt full_table_name */ +{ yylhsminor.yy378 = createDropTableClause(pCxt, yymsp[-1].minor.yy215, yymsp[0].minor.yy378); } + yymsp[-1].minor.yy378 = yylhsminor.yy378; break; - case 98: /* create_subtable_clause ::= not_exists_opt full_table_name USING full_table_name specific_tags_opt TAGS NK_LP literal_list NK_RP */ -{ yylhsminor.yy140 = createCreateSubTableClause(pCxt, yymsp[-8].minor.yy497, yymsp[-7].minor.yy140, yymsp[-5].minor.yy140, yymsp[-4].minor.yy136, yymsp[-1].minor.yy136); } - yymsp[-8].minor.yy140 = yylhsminor.yy140; + case 101: /* specific_tags_opt ::= */ + case 132: /* tags_def_opt ::= */ yytestcase(yyruleno==132); + case 290: /* partition_by_clause_opt ::= */ yytestcase(yyruleno==290); + case 307: /* group_by_clause_opt ::= */ yytestcase(yyruleno==307); + case 317: /* order_by_clause_opt ::= */ yytestcase(yyruleno==317); +{ yymsp[1].minor.yy404 = NULL; } break; - case 101: /* drop_table_clause ::= exists_opt full_table_name */ -{ yylhsminor.yy140 = createDropTableClause(pCxt, yymsp[-1].minor.yy497, yymsp[0].minor.yy140); } - yymsp[-1].minor.yy140 = yylhsminor.yy140; + case 102: /* specific_tags_opt ::= NK_LP col_name_list NK_RP */ +{ yymsp[-2].minor.yy404 = yymsp[-1].minor.yy404; } break; - case 102: /* specific_tags_opt ::= */ - case 133: /* tags_def_opt ::= */ yytestcase(yyruleno==133); - case 289: /* partition_by_clause_opt ::= */ yytestcase(yyruleno==289); - case 306: /* group_by_clause_opt ::= */ yytestcase(yyruleno==306); - case 316: /* order_by_clause_opt ::= */ yytestcase(yyruleno==316); -{ yymsp[1].minor.yy136 = NULL; } + case 103: /* full_table_name ::= table_name */ +{ yylhsminor.yy378 = createRealTableNode(pCxt, NULL, &yymsp[0].minor.yy183, NULL); } + yymsp[0].minor.yy378 = yylhsminor.yy378; break; - case 103: /* specific_tags_opt ::= NK_LP col_name_list NK_RP */ -{ yymsp[-2].minor.yy136 = yymsp[-1].minor.yy136; } + case 104: /* full_table_name ::= db_name NK_DOT table_name */ +{ yylhsminor.yy378 = createRealTableNode(pCxt, &yymsp[-2].minor.yy183, &yymsp[0].minor.yy183, NULL); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; - case 104: /* full_table_name ::= table_name */ -{ yylhsminor.yy140 = createRealTableNode(pCxt, NULL, &yymsp[0].minor.yy149, NULL); } - yymsp[0].minor.yy140 = yylhsminor.yy140; + case 106: /* column_def_list ::= column_def_list NK_COMMA column_def */ + case 149: /* col_name_list ::= col_name_list NK_COMMA col_name */ yytestcase(yyruleno==149); + case 171: /* func_name_list ::= func_name_list NK_COMMA col_name */ yytestcase(yyruleno==171); + case 180: /* func_list ::= func_list NK_COMMA func */ yytestcase(yyruleno==180); + case 205: /* literal_list ::= literal_list NK_COMMA signed_literal */ yytestcase(yyruleno==205); + case 283: /* select_sublist ::= select_sublist NK_COMMA select_item */ yytestcase(yyruleno==283); + case 330: /* sort_specification_list ::= sort_specification_list NK_COMMA sort_specification */ yytestcase(yyruleno==330); +{ yylhsminor.yy404 = addNodeToList(pCxt, yymsp[-2].minor.yy404, yymsp[0].minor.yy378); } + yymsp[-2].minor.yy404 = yylhsminor.yy404; break; - case 105: /* full_table_name ::= db_name NK_DOT table_name */ -{ yylhsminor.yy140 = createRealTableNode(pCxt, &yymsp[-2].minor.yy149, &yymsp[0].minor.yy149, NULL); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; + case 107: /* column_def ::= column_name type_name */ +{ yylhsminor.yy378 = createColumnDefNode(pCxt, &yymsp[-1].minor.yy183, yymsp[0].minor.yy504, NULL); } + yymsp[-1].minor.yy378 = yylhsminor.yy378; break; - case 107: /* column_def_list ::= column_def_list NK_COMMA column_def */ - case 148: /* col_name_list ::= col_name_list NK_COMMA col_name */ yytestcase(yyruleno==148); - case 170: /* func_name_list ::= func_name_list NK_COMMA col_name */ yytestcase(yyruleno==170); - case 179: /* func_list ::= func_list NK_COMMA func */ yytestcase(yyruleno==179); - case 204: /* literal_list ::= literal_list NK_COMMA signed_literal */ yytestcase(yyruleno==204); - case 282: /* select_sublist ::= select_sublist NK_COMMA select_item */ yytestcase(yyruleno==282); - case 329: /* sort_specification_list ::= sort_specification_list NK_COMMA sort_specification */ yytestcase(yyruleno==329); -{ yylhsminor.yy136 = addNodeToList(pCxt, yymsp[-2].minor.yy136, yymsp[0].minor.yy140); } - yymsp[-2].minor.yy136 = yylhsminor.yy136; + case 108: /* column_def ::= column_name type_name COMMENT NK_STRING */ +{ yylhsminor.yy378 = createColumnDefNode(pCxt, &yymsp[-3].minor.yy183, yymsp[-2].minor.yy504, &yymsp[0].minor.yy0); } + yymsp[-3].minor.yy378 = yylhsminor.yy378; break; - case 108: /* column_def ::= column_name type_name */ -{ yylhsminor.yy140 = createColumnDefNode(pCxt, &yymsp[-1].minor.yy149, yymsp[0].minor.yy256, NULL); } - yymsp[-1].minor.yy140 = yylhsminor.yy140; + case 109: /* type_name ::= BOOL */ +{ yymsp[0].minor.yy504 = createDataType(TSDB_DATA_TYPE_BOOL); } break; - case 109: /* column_def ::= column_name type_name COMMENT NK_STRING */ -{ yylhsminor.yy140 = createColumnDefNode(pCxt, &yymsp[-3].minor.yy149, yymsp[-2].minor.yy256, &yymsp[0].minor.yy0); } - yymsp[-3].minor.yy140 = yylhsminor.yy140; + case 110: /* type_name ::= TINYINT */ +{ yymsp[0].minor.yy504 = createDataType(TSDB_DATA_TYPE_TINYINT); } break; - case 110: /* type_name ::= BOOL */ -{ yymsp[0].minor.yy256 = createDataType(TSDB_DATA_TYPE_BOOL); } + case 111: /* type_name ::= SMALLINT */ +{ yymsp[0].minor.yy504 = createDataType(TSDB_DATA_TYPE_SMALLINT); } break; - case 111: /* type_name ::= TINYINT */ -{ yymsp[0].minor.yy256 = createDataType(TSDB_DATA_TYPE_TINYINT); } + case 112: /* type_name ::= INT */ + case 113: /* type_name ::= INTEGER */ yytestcase(yyruleno==113); +{ yymsp[0].minor.yy504 = createDataType(TSDB_DATA_TYPE_INT); } break; - case 112: /* type_name ::= SMALLINT */ -{ yymsp[0].minor.yy256 = createDataType(TSDB_DATA_TYPE_SMALLINT); } + case 114: /* type_name ::= BIGINT */ +{ yymsp[0].minor.yy504 = createDataType(TSDB_DATA_TYPE_BIGINT); } break; - case 113: /* type_name ::= INT */ - case 114: /* type_name ::= INTEGER */ yytestcase(yyruleno==114); -{ yymsp[0].minor.yy256 = createDataType(TSDB_DATA_TYPE_INT); } + case 115: /* type_name ::= FLOAT */ +{ yymsp[0].minor.yy504 = createDataType(TSDB_DATA_TYPE_FLOAT); } break; - case 115: /* type_name ::= BIGINT */ -{ yymsp[0].minor.yy256 = createDataType(TSDB_DATA_TYPE_BIGINT); } + case 116: /* type_name ::= DOUBLE */ +{ yymsp[0].minor.yy504 = createDataType(TSDB_DATA_TYPE_DOUBLE); } break; - case 116: /* type_name ::= FLOAT */ -{ yymsp[0].minor.yy256 = createDataType(TSDB_DATA_TYPE_FLOAT); } + case 117: /* type_name ::= BINARY NK_LP NK_INTEGER NK_RP */ +{ yymsp[-3].minor.yy504 = createVarLenDataType(TSDB_DATA_TYPE_BINARY, &yymsp[-1].minor.yy0); } break; - case 117: /* type_name ::= DOUBLE */ -{ yymsp[0].minor.yy256 = createDataType(TSDB_DATA_TYPE_DOUBLE); } + case 118: /* type_name ::= TIMESTAMP */ +{ yymsp[0].minor.yy504 = createDataType(TSDB_DATA_TYPE_TIMESTAMP); } break; - case 118: /* type_name ::= BINARY NK_LP NK_INTEGER NK_RP */ -{ yymsp[-3].minor.yy256 = createVarLenDataType(TSDB_DATA_TYPE_BINARY, &yymsp[-1].minor.yy0); } + case 119: /* type_name ::= NCHAR NK_LP NK_INTEGER NK_RP */ +{ yymsp[-3].minor.yy504 = createVarLenDataType(TSDB_DATA_TYPE_NCHAR, &yymsp[-1].minor.yy0); } break; - case 119: /* type_name ::= TIMESTAMP */ -{ yymsp[0].minor.yy256 = createDataType(TSDB_DATA_TYPE_TIMESTAMP); } + case 120: /* type_name ::= TINYINT UNSIGNED */ +{ yymsp[-1].minor.yy504 = createDataType(TSDB_DATA_TYPE_UTINYINT); } break; - case 120: /* type_name ::= NCHAR NK_LP NK_INTEGER NK_RP */ -{ yymsp[-3].minor.yy256 = createVarLenDataType(TSDB_DATA_TYPE_NCHAR, &yymsp[-1].minor.yy0); } + case 121: /* type_name ::= SMALLINT UNSIGNED */ +{ yymsp[-1].minor.yy504 = createDataType(TSDB_DATA_TYPE_USMALLINT); } break; - case 121: /* type_name ::= TINYINT UNSIGNED */ -{ yymsp[-1].minor.yy256 = createDataType(TSDB_DATA_TYPE_UTINYINT); } + case 122: /* type_name ::= INT UNSIGNED */ +{ yymsp[-1].minor.yy504 = createDataType(TSDB_DATA_TYPE_UINT); } break; - case 122: /* type_name ::= SMALLINT UNSIGNED */ -{ yymsp[-1].minor.yy256 = createDataType(TSDB_DATA_TYPE_USMALLINT); } + case 123: /* type_name ::= BIGINT UNSIGNED */ +{ yymsp[-1].minor.yy504 = createDataType(TSDB_DATA_TYPE_UBIGINT); } break; - case 123: /* type_name ::= INT UNSIGNED */ -{ yymsp[-1].minor.yy256 = createDataType(TSDB_DATA_TYPE_UINT); } + case 124: /* type_name ::= JSON */ +{ yymsp[0].minor.yy504 = createDataType(TSDB_DATA_TYPE_JSON); } break; - case 124: /* type_name ::= BIGINT UNSIGNED */ -{ yymsp[-1].minor.yy256 = createDataType(TSDB_DATA_TYPE_UBIGINT); } + case 125: /* type_name ::= VARCHAR NK_LP NK_INTEGER NK_RP */ +{ yymsp[-3].minor.yy504 = createVarLenDataType(TSDB_DATA_TYPE_VARCHAR, &yymsp[-1].minor.yy0); } break; - case 125: /* type_name ::= JSON */ -{ yymsp[0].minor.yy256 = createDataType(TSDB_DATA_TYPE_JSON); } + case 126: /* type_name ::= MEDIUMBLOB */ +{ yymsp[0].minor.yy504 = createDataType(TSDB_DATA_TYPE_MEDIUMBLOB); } break; - case 126: /* type_name ::= VARCHAR NK_LP NK_INTEGER NK_RP */ -{ yymsp[-3].minor.yy256 = createVarLenDataType(TSDB_DATA_TYPE_VARCHAR, &yymsp[-1].minor.yy0); } + case 127: /* type_name ::= BLOB */ +{ yymsp[0].minor.yy504 = createDataType(TSDB_DATA_TYPE_BLOB); } break; - case 127: /* type_name ::= MEDIUMBLOB */ -{ yymsp[0].minor.yy256 = createDataType(TSDB_DATA_TYPE_MEDIUMBLOB); } + case 128: /* type_name ::= VARBINARY NK_LP NK_INTEGER NK_RP */ +{ yymsp[-3].minor.yy504 = createVarLenDataType(TSDB_DATA_TYPE_VARBINARY, &yymsp[-1].minor.yy0); } break; - case 128: /* type_name ::= BLOB */ -{ yymsp[0].minor.yy256 = createDataType(TSDB_DATA_TYPE_BLOB); } + case 129: /* type_name ::= DECIMAL */ +{ yymsp[0].minor.yy504 = createDataType(TSDB_DATA_TYPE_DECIMAL); } break; - case 129: /* type_name ::= VARBINARY NK_LP NK_INTEGER NK_RP */ -{ yymsp[-3].minor.yy256 = createVarLenDataType(TSDB_DATA_TYPE_VARBINARY, &yymsp[-1].minor.yy0); } + case 130: /* type_name ::= DECIMAL NK_LP NK_INTEGER NK_RP */ +{ yymsp[-3].minor.yy504 = createDataType(TSDB_DATA_TYPE_DECIMAL); } break; - case 130: /* type_name ::= DECIMAL */ -{ yymsp[0].minor.yy256 = createDataType(TSDB_DATA_TYPE_DECIMAL); } + case 131: /* type_name ::= DECIMAL NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP */ +{ yymsp[-5].minor.yy504 = createDataType(TSDB_DATA_TYPE_DECIMAL); } break; - case 131: /* type_name ::= DECIMAL NK_LP NK_INTEGER NK_RP */ -{ yymsp[-3].minor.yy256 = createDataType(TSDB_DATA_TYPE_DECIMAL); } + case 133: /* tags_def_opt ::= tags_def */ + case 281: /* select_list ::= select_sublist */ yytestcase(yyruleno==281); +{ yylhsminor.yy404 = yymsp[0].minor.yy404; } + yymsp[0].minor.yy404 = yylhsminor.yy404; break; - case 132: /* type_name ::= DECIMAL NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP */ -{ yymsp[-5].minor.yy256 = createDataType(TSDB_DATA_TYPE_DECIMAL); } + case 134: /* tags_def ::= TAGS NK_LP column_def_list NK_RP */ +{ yymsp[-3].minor.yy404 = yymsp[-1].minor.yy404; } break; - case 134: /* tags_def_opt ::= tags_def */ - case 280: /* select_list ::= select_sublist */ yytestcase(yyruleno==280); -{ yylhsminor.yy136 = yymsp[0].minor.yy136; } - yymsp[0].minor.yy136 = yylhsminor.yy136; + case 135: /* table_options ::= */ +{ yymsp[1].minor.yy378 = createDefaultTableOptions(pCxt); } break; - case 135: /* tags_def ::= TAGS NK_LP column_def_list NK_RP */ -{ yymsp[-3].minor.yy136 = yymsp[-1].minor.yy136; } + case 136: /* table_options ::= table_options COMMENT NK_STRING */ +{ yylhsminor.yy378 = setTableOption(pCxt, yymsp[-2].minor.yy378, TABLE_OPTION_COMMENT, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; - case 136: /* table_options ::= */ -{ yymsp[1].minor.yy140 = createDefaultTableOptions(pCxt); } + case 137: /* table_options ::= table_options KEEP NK_INTEGER */ +{ yylhsminor.yy378 = setTableOption(pCxt, yymsp[-2].minor.yy378, TABLE_OPTION_KEEP, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; - case 137: /* table_options ::= table_options COMMENT NK_STRING */ -{ yylhsminor.yy140 = setTableOption(pCxt, yymsp[-2].minor.yy140, TABLE_OPTION_COMMENT, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; + case 138: /* table_options ::= table_options TTL NK_INTEGER */ +{ yylhsminor.yy378 = setTableOption(pCxt, yymsp[-2].minor.yy378, TABLE_OPTION_TTL, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; - case 138: /* table_options ::= table_options KEEP NK_INTEGER */ -{ yylhsminor.yy140 = setTableOption(pCxt, yymsp[-2].minor.yy140, TABLE_OPTION_KEEP, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; + case 139: /* table_options ::= table_options SMA NK_LP col_name_list NK_RP */ +{ yylhsminor.yy378 = setTableSmaOption(pCxt, yymsp[-4].minor.yy378, yymsp[-1].minor.yy404); } + yymsp[-4].minor.yy378 = yylhsminor.yy378; break; - case 139: /* table_options ::= table_options TTL NK_INTEGER */ -{ yylhsminor.yy140 = setTableOption(pCxt, yymsp[-2].minor.yy140, TABLE_OPTION_TTL, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; + case 140: /* table_options ::= table_options ROLLUP NK_LP func_name_list NK_RP */ +{ yylhsminor.yy378 = setTableRollupOption(pCxt, yymsp[-4].minor.yy378, yymsp[-1].minor.yy404); } + yymsp[-4].minor.yy378 = yylhsminor.yy378; break; - case 140: /* table_options ::= table_options SMA NK_LP col_name_list NK_RP */ -{ yylhsminor.yy140 = setTableSmaOption(pCxt, yymsp[-4].minor.yy140, yymsp[-1].minor.yy136); } - yymsp[-4].minor.yy140 = yylhsminor.yy140; + case 141: /* table_options ::= table_options FILE_FACTOR NK_FLOAT */ +{ yylhsminor.yy378 = setTableOption(pCxt, yymsp[-2].minor.yy378, TABLE_OPTION_FILE_FACTOR, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; - case 141: /* table_options ::= table_options ROLLUP NK_LP func_name_list NK_RP */ -{ yylhsminor.yy140 = setTableRollupOption(pCxt, yymsp[-4].minor.yy140, yymsp[-1].minor.yy136); } - yymsp[-4].minor.yy140 = yylhsminor.yy140; + case 142: /* table_options ::= table_options DELAY NK_INTEGER */ +{ yylhsminor.yy378 = setTableOption(pCxt, yymsp[-2].minor.yy378, TABLE_OPTION_DELAY, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; - case 142: /* alter_table_options ::= alter_table_option */ -{ yylhsminor.yy140 = createDefaultAlterTableOptions(pCxt); yylhsminor.yy140 = setTableOption(pCxt, yylhsminor.yy140, yymsp[0].minor.yy233.type, &yymsp[0].minor.yy233.val); } - yymsp[0].minor.yy140 = yylhsminor.yy140; + case 143: /* alter_table_options ::= alter_table_option */ +{ yylhsminor.yy378 = createDefaultAlterTableOptions(pCxt); yylhsminor.yy378 = setTableOption(pCxt, yylhsminor.yy378, yymsp[0].minor.yy11.type, &yymsp[0].minor.yy11.val); } + yymsp[0].minor.yy378 = yylhsminor.yy378; break; - case 143: /* alter_table_options ::= alter_table_options alter_table_option */ -{ yylhsminor.yy140 = setTableOption(pCxt, yymsp[-1].minor.yy140, yymsp[0].minor.yy233.type, &yymsp[0].minor.yy233.val); } - yymsp[-1].minor.yy140 = yylhsminor.yy140; + case 144: /* alter_table_options ::= alter_table_options alter_table_option */ +{ yylhsminor.yy378 = setTableOption(pCxt, yymsp[-1].minor.yy378, yymsp[0].minor.yy11.type, &yymsp[0].minor.yy11.val); } + yymsp[-1].minor.yy378 = yylhsminor.yy378; break; - case 144: /* alter_table_option ::= COMMENT NK_STRING */ -{ yymsp[-1].minor.yy233.type = TABLE_OPTION_COMMENT; yymsp[-1].minor.yy233.val = yymsp[0].minor.yy0; } + case 145: /* alter_table_option ::= COMMENT NK_STRING */ +{ yymsp[-1].minor.yy11.type = TABLE_OPTION_COMMENT; yymsp[-1].minor.yy11.val = yymsp[0].minor.yy0; } break; - case 145: /* alter_table_option ::= KEEP NK_INTEGER */ -{ yymsp[-1].minor.yy233.type = TABLE_OPTION_KEEP; yymsp[-1].minor.yy233.val = yymsp[0].minor.yy0; } + case 146: /* alter_table_option ::= KEEP NK_INTEGER */ +{ yymsp[-1].minor.yy11.type = TABLE_OPTION_KEEP; yymsp[-1].minor.yy11.val = yymsp[0].minor.yy0; } break; - case 146: /* alter_table_option ::= TTL NK_INTEGER */ -{ yymsp[-1].minor.yy233.type = TABLE_OPTION_TTL; yymsp[-1].minor.yy233.val = yymsp[0].minor.yy0; } + case 147: /* alter_table_option ::= TTL NK_INTEGER */ +{ yymsp[-1].minor.yy11.type = TABLE_OPTION_TTL; yymsp[-1].minor.yy11.val = yymsp[0].minor.yy0; } break; - case 149: /* col_name ::= column_name */ -{ yylhsminor.yy140 = createColumnNode(pCxt, NULL, &yymsp[0].minor.yy149); } - yymsp[0].minor.yy140 = yylhsminor.yy140; + case 150: /* col_name ::= column_name */ +{ yylhsminor.yy378 = createColumnNode(pCxt, NULL, &yymsp[0].minor.yy183); } + yymsp[0].minor.yy378 = yylhsminor.yy378; break; - case 150: /* cmd ::= SHOW DNODES */ + case 151: /* cmd ::= SHOW DNODES */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_DNODES_STMT, NULL, NULL); } break; - case 151: /* cmd ::= SHOW USERS */ + case 152: /* cmd ::= SHOW USERS */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_USERS_STMT, NULL, NULL); } break; - case 152: /* cmd ::= SHOW DATABASES */ + case 153: /* cmd ::= SHOW DATABASES */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_DATABASES_STMT, NULL, NULL); } break; - case 153: /* cmd ::= SHOW db_name_cond_opt TABLES like_pattern_opt */ -{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_TABLES_STMT, yymsp[-2].minor.yy140, yymsp[0].minor.yy140); } + case 154: /* cmd ::= SHOW db_name_cond_opt TABLES like_pattern_opt */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_TABLES_STMT, yymsp[-2].minor.yy378, yymsp[0].minor.yy378); } break; - case 154: /* cmd ::= SHOW db_name_cond_opt STABLES like_pattern_opt */ -{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_STABLES_STMT, yymsp[-2].minor.yy140, yymsp[0].minor.yy140); } + case 155: /* cmd ::= SHOW db_name_cond_opt STABLES like_pattern_opt */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_STABLES_STMT, yymsp[-2].minor.yy378, yymsp[0].minor.yy378); } break; - case 155: /* cmd ::= SHOW db_name_cond_opt VGROUPS */ -{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_VGROUPS_STMT, yymsp[-1].minor.yy140, NULL); } + case 156: /* cmd ::= SHOW db_name_cond_opt VGROUPS */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_VGROUPS_STMT, yymsp[-1].minor.yy378, NULL); } break; - case 156: /* cmd ::= SHOW MNODES */ + case 157: /* cmd ::= SHOW MNODES */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_MNODES_STMT, NULL, NULL); } break; - case 157: /* cmd ::= SHOW MODULES */ + case 158: /* cmd ::= SHOW MODULES */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_MODULES_STMT, NULL, NULL); } break; - case 158: /* cmd ::= SHOW QNODES */ + case 159: /* cmd ::= SHOW QNODES */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_QNODES_STMT, NULL, NULL); } break; - case 159: /* cmd ::= SHOW FUNCTIONS */ + case 160: /* cmd ::= SHOW FUNCTIONS */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_FUNCTIONS_STMT, NULL, NULL); } break; - case 160: /* cmd ::= SHOW INDEXES FROM table_name_cond from_db_opt */ -{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_INDEXES_STMT, yymsp[-1].minor.yy140, yymsp[0].minor.yy140); } + case 161: /* cmd ::= SHOW INDEXES FROM table_name_cond from_db_opt */ +{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_INDEXES_STMT, yymsp[-1].minor.yy378, yymsp[0].minor.yy378); } break; - case 161: /* cmd ::= SHOW STREAMS */ + case 162: /* cmd ::= SHOW STREAMS */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_STREAMS_STMT, NULL, NULL); } break; - case 162: /* db_name_cond_opt ::= */ - case 167: /* from_db_opt ::= */ yytestcase(yyruleno==167); -{ yymsp[1].minor.yy140 = createDefaultDatabaseCondValue(pCxt); } - break; - case 163: /* db_name_cond_opt ::= db_name NK_DOT */ -{ yylhsminor.yy140 = createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[-1].minor.yy149); } - yymsp[-1].minor.yy140 = yylhsminor.yy140; - break; - case 164: /* like_pattern_opt ::= */ - case 175: /* index_options ::= */ yytestcase(yyruleno==175); - case 287: /* where_clause_opt ::= */ yytestcase(yyruleno==287); - case 291: /* twindow_clause_opt ::= */ yytestcase(yyruleno==291); - case 296: /* sliding_opt ::= */ yytestcase(yyruleno==296); - case 298: /* fill_opt ::= */ yytestcase(yyruleno==298); - case 310: /* having_clause_opt ::= */ yytestcase(yyruleno==310); - case 318: /* slimit_clause_opt ::= */ yytestcase(yyruleno==318); - case 322: /* limit_clause_opt ::= */ yytestcase(yyruleno==322); -{ yymsp[1].minor.yy140 = NULL; } - break; - case 165: /* like_pattern_opt ::= LIKE NK_STRING */ -{ yymsp[-1].minor.yy140 = createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0); } - break; - case 166: /* table_name_cond ::= table_name */ -{ yylhsminor.yy140 = createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy149); } - yymsp[0].minor.yy140 = yylhsminor.yy140; - break; - case 168: /* from_db_opt ::= FROM db_name */ -{ yymsp[-1].minor.yy140 = createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy149); } - break; - case 171: /* func_name ::= function_name */ -{ yylhsminor.yy140 = createFunctionNode(pCxt, &yymsp[0].minor.yy149, NULL); } - yymsp[0].minor.yy140 = yylhsminor.yy140; - break; - case 172: /* cmd ::= CREATE SMA INDEX not_exists_opt index_name ON table_name index_options */ -{ pCxt->pRootNode = createCreateIndexStmt(pCxt, INDEX_TYPE_SMA, yymsp[-4].minor.yy497, &yymsp[-3].minor.yy149, &yymsp[-1].minor.yy149, NULL, yymsp[0].minor.yy140); } - break; - case 173: /* cmd ::= CREATE FULLTEXT INDEX not_exists_opt index_name ON table_name NK_LP col_name_list NK_RP */ -{ pCxt->pRootNode = createCreateIndexStmt(pCxt, INDEX_TYPE_FULLTEXT, yymsp[-6].minor.yy497, &yymsp[-5].minor.yy149, &yymsp[-3].minor.yy149, yymsp[-1].minor.yy136, NULL); } - break; - case 174: /* cmd ::= DROP INDEX exists_opt index_name ON table_name */ -{ pCxt->pRootNode = createDropIndexStmt(pCxt, yymsp[-3].minor.yy497, &yymsp[-2].minor.yy149, &yymsp[0].minor.yy149); } - break; - case 176: /* index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_RP sliding_opt */ -{ yymsp[-8].minor.yy140 = createIndexOption(pCxt, yymsp[-6].minor.yy136, releaseRawExprNode(pCxt, yymsp[-2].minor.yy140), NULL, yymsp[0].minor.yy140); } - break; - case 177: /* index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt */ -{ yymsp[-10].minor.yy140 = createIndexOption(pCxt, yymsp[-8].minor.yy136, releaseRawExprNode(pCxt, yymsp[-4].minor.yy140), releaseRawExprNode(pCxt, yymsp[-2].minor.yy140), yymsp[0].minor.yy140); } - break; - case 180: /* func ::= function_name NK_LP expression_list NK_RP */ -{ yylhsminor.yy140 = createFunctionNode(pCxt, &yymsp[-3].minor.yy149, yymsp[-1].minor.yy136); } - yymsp[-3].minor.yy140 = yylhsminor.yy140; - break; - case 181: /* cmd ::= CREATE TOPIC not_exists_opt topic_name AS query_expression */ -{ pCxt->pRootNode = createCreateTopicStmt(pCxt, yymsp[-3].minor.yy497, &yymsp[-2].minor.yy149, yymsp[0].minor.yy140, NULL); } - break; - case 182: /* cmd ::= CREATE TOPIC not_exists_opt topic_name AS db_name */ -{ pCxt->pRootNode = createCreateTopicStmt(pCxt, yymsp[-3].minor.yy497, &yymsp[-2].minor.yy149, NULL, &yymsp[0].minor.yy149); } - break; - case 183: /* cmd ::= DROP TOPIC exists_opt topic_name */ -{ pCxt->pRootNode = createDropTopicStmt(pCxt, yymsp[-1].minor.yy497, &yymsp[0].minor.yy149); } - break; - case 185: /* literal ::= NK_INTEGER */ -{ yylhsminor.yy140 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0)); } - yymsp[0].minor.yy140 = yylhsminor.yy140; - break; - case 186: /* literal ::= NK_FLOAT */ -{ yylhsminor.yy140 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &yymsp[0].minor.yy0)); } - yymsp[0].minor.yy140 = yylhsminor.yy140; - break; - case 187: /* literal ::= NK_STRING */ -{ yylhsminor.yy140 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0)); } - yymsp[0].minor.yy140 = yylhsminor.yy140; - break; - case 188: /* literal ::= NK_BOOL */ -{ yylhsminor.yy140 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_BOOL, &yymsp[0].minor.yy0)); } - yymsp[0].minor.yy140 = yylhsminor.yy140; - break; - case 189: /* literal ::= TIMESTAMP NK_STRING */ -{ yylhsminor.yy140 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_TIMESTAMP, &yymsp[0].minor.yy0)); } - yymsp[-1].minor.yy140 = yylhsminor.yy140; - break; - case 190: /* literal ::= duration_literal */ - case 198: /* signed_literal ::= signed */ yytestcase(yyruleno==198); - case 214: /* expression ::= literal */ yytestcase(yyruleno==214); - case 215: /* expression ::= column_reference */ yytestcase(yyruleno==215); - case 218: /* expression ::= subquery */ yytestcase(yyruleno==218); - case 250: /* boolean_value_expression ::= boolean_primary */ yytestcase(yyruleno==250); - case 254: /* boolean_primary ::= predicate */ yytestcase(yyruleno==254); - case 256: /* common_expression ::= expression */ yytestcase(yyruleno==256); - case 257: /* common_expression ::= boolean_value_expression */ yytestcase(yyruleno==257); - case 259: /* table_reference_list ::= table_reference */ yytestcase(yyruleno==259); - case 261: /* table_reference ::= table_primary */ yytestcase(yyruleno==261); - case 262: /* table_reference ::= joined_table */ yytestcase(yyruleno==262); - case 266: /* table_primary ::= parenthesized_joined_table */ yytestcase(yyruleno==266); - case 313: /* query_expression_body ::= query_primary */ yytestcase(yyruleno==313); - case 315: /* query_primary ::= query_specification */ yytestcase(yyruleno==315); -{ yylhsminor.yy140 = yymsp[0].minor.yy140; } - yymsp[0].minor.yy140 = yylhsminor.yy140; - break; - case 191: /* duration_literal ::= NK_VARIABLE */ -{ yylhsminor.yy140 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createDurationValueNode(pCxt, &yymsp[0].minor.yy0)); } - yymsp[0].minor.yy140 = yylhsminor.yy140; - break; - case 192: /* signed ::= NK_INTEGER */ -{ yylhsminor.yy140 = createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); } - yymsp[0].minor.yy140 = yylhsminor.yy140; - break; - case 193: /* signed ::= NK_PLUS NK_INTEGER */ -{ yymsp[-1].minor.yy140 = createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); } - break; - case 194: /* signed ::= NK_MINUS NK_INTEGER */ + case 163: /* db_name_cond_opt ::= */ + case 168: /* from_db_opt ::= */ yytestcase(yyruleno==168); +{ yymsp[1].minor.yy378 = createDefaultDatabaseCondValue(pCxt); } + break; + case 164: /* db_name_cond_opt ::= db_name NK_DOT */ +{ yylhsminor.yy378 = createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[-1].minor.yy183); } + yymsp[-1].minor.yy378 = yylhsminor.yy378; + break; + case 165: /* like_pattern_opt ::= */ + case 176: /* index_options ::= */ yytestcase(yyruleno==176); + case 288: /* where_clause_opt ::= */ yytestcase(yyruleno==288); + case 292: /* twindow_clause_opt ::= */ yytestcase(yyruleno==292); + case 297: /* sliding_opt ::= */ yytestcase(yyruleno==297); + case 299: /* fill_opt ::= */ yytestcase(yyruleno==299); + case 311: /* having_clause_opt ::= */ yytestcase(yyruleno==311); + case 319: /* slimit_clause_opt ::= */ yytestcase(yyruleno==319); + case 323: /* limit_clause_opt ::= */ yytestcase(yyruleno==323); +{ yymsp[1].minor.yy378 = NULL; } + break; + case 166: /* like_pattern_opt ::= LIKE NK_STRING */ +{ yymsp[-1].minor.yy378 = createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0); } + break; + case 167: /* table_name_cond ::= table_name */ +{ yylhsminor.yy378 = createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy183); } + yymsp[0].minor.yy378 = yylhsminor.yy378; + break; + case 169: /* from_db_opt ::= FROM db_name */ +{ yymsp[-1].minor.yy378 = createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy183); } + break; + case 172: /* func_name ::= function_name */ +{ yylhsminor.yy378 = createFunctionNode(pCxt, &yymsp[0].minor.yy183, NULL); } + yymsp[0].minor.yy378 = yylhsminor.yy378; + break; + case 173: /* cmd ::= CREATE SMA INDEX not_exists_opt index_name ON table_name index_options */ +{ pCxt->pRootNode = createCreateIndexStmt(pCxt, INDEX_TYPE_SMA, yymsp[-4].minor.yy215, &yymsp[-3].minor.yy183, &yymsp[-1].minor.yy183, NULL, yymsp[0].minor.yy378); } + break; + case 174: /* cmd ::= CREATE FULLTEXT INDEX not_exists_opt index_name ON table_name NK_LP col_name_list NK_RP */ +{ pCxt->pRootNode = createCreateIndexStmt(pCxt, INDEX_TYPE_FULLTEXT, yymsp[-6].minor.yy215, &yymsp[-5].minor.yy183, &yymsp[-3].minor.yy183, yymsp[-1].minor.yy404, NULL); } + break; + case 175: /* cmd ::= DROP INDEX exists_opt index_name ON table_name */ +{ pCxt->pRootNode = createDropIndexStmt(pCxt, yymsp[-3].minor.yy215, &yymsp[-2].minor.yy183, &yymsp[0].minor.yy183); } + break; + case 177: /* index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_RP sliding_opt */ +{ yymsp[-8].minor.yy378 = createIndexOption(pCxt, yymsp[-6].minor.yy404, releaseRawExprNode(pCxt, yymsp[-2].minor.yy378), NULL, yymsp[0].minor.yy378); } + break; + case 178: /* index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt */ +{ yymsp[-10].minor.yy378 = createIndexOption(pCxt, yymsp[-8].minor.yy404, releaseRawExprNode(pCxt, yymsp[-4].minor.yy378), releaseRawExprNode(pCxt, yymsp[-2].minor.yy378), yymsp[0].minor.yy378); } + break; + case 181: /* func ::= function_name NK_LP expression_list NK_RP */ +{ yylhsminor.yy378 = createFunctionNode(pCxt, &yymsp[-3].minor.yy183, yymsp[-1].minor.yy404); } + yymsp[-3].minor.yy378 = yylhsminor.yy378; + break; + case 182: /* cmd ::= CREATE TOPIC not_exists_opt topic_name AS query_expression */ +{ pCxt->pRootNode = createCreateTopicStmt(pCxt, yymsp[-3].minor.yy215, &yymsp[-2].minor.yy183, yymsp[0].minor.yy378, NULL); } + break; + case 183: /* cmd ::= CREATE TOPIC not_exists_opt topic_name AS db_name */ +{ pCxt->pRootNode = createCreateTopicStmt(pCxt, yymsp[-3].minor.yy215, &yymsp[-2].minor.yy183, NULL, &yymsp[0].minor.yy183); } + break; + case 184: /* cmd ::= DROP TOPIC exists_opt topic_name */ +{ pCxt->pRootNode = createDropTopicStmt(pCxt, yymsp[-1].minor.yy215, &yymsp[0].minor.yy183); } + break; + case 186: /* literal ::= NK_INTEGER */ +{ yylhsminor.yy378 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0)); } + yymsp[0].minor.yy378 = yylhsminor.yy378; + break; + case 187: /* literal ::= NK_FLOAT */ +{ yylhsminor.yy378 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &yymsp[0].minor.yy0)); } + yymsp[0].minor.yy378 = yylhsminor.yy378; + break; + case 188: /* literal ::= NK_STRING */ +{ yylhsminor.yy378 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0)); } + yymsp[0].minor.yy378 = yylhsminor.yy378; + break; + case 189: /* literal ::= NK_BOOL */ +{ yylhsminor.yy378 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_BOOL, &yymsp[0].minor.yy0)); } + yymsp[0].minor.yy378 = yylhsminor.yy378; + break; + case 190: /* literal ::= TIMESTAMP NK_STRING */ +{ yylhsminor.yy378 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_TIMESTAMP, &yymsp[0].minor.yy0)); } + yymsp[-1].minor.yy378 = yylhsminor.yy378; + break; + case 191: /* literal ::= duration_literal */ + case 199: /* signed_literal ::= signed */ yytestcase(yyruleno==199); + case 215: /* expression ::= literal */ yytestcase(yyruleno==215); + case 216: /* expression ::= column_reference */ yytestcase(yyruleno==216); + case 219: /* expression ::= subquery */ yytestcase(yyruleno==219); + case 251: /* boolean_value_expression ::= boolean_primary */ yytestcase(yyruleno==251); + case 255: /* boolean_primary ::= predicate */ yytestcase(yyruleno==255); + case 257: /* common_expression ::= expression */ yytestcase(yyruleno==257); + case 258: /* common_expression ::= boolean_value_expression */ yytestcase(yyruleno==258); + case 260: /* table_reference_list ::= table_reference */ yytestcase(yyruleno==260); + case 262: /* table_reference ::= table_primary */ yytestcase(yyruleno==262); + case 263: /* table_reference ::= joined_table */ yytestcase(yyruleno==263); + case 267: /* table_primary ::= parenthesized_joined_table */ yytestcase(yyruleno==267); + case 314: /* query_expression_body ::= query_primary */ yytestcase(yyruleno==314); + case 316: /* query_primary ::= query_specification */ yytestcase(yyruleno==316); +{ yylhsminor.yy378 = yymsp[0].minor.yy378; } + yymsp[0].minor.yy378 = yylhsminor.yy378; + break; + case 192: /* duration_literal ::= NK_VARIABLE */ +{ yylhsminor.yy378 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createDurationValueNode(pCxt, &yymsp[0].minor.yy0)); } + yymsp[0].minor.yy378 = yylhsminor.yy378; + break; + case 193: /* signed ::= NK_INTEGER */ +{ yylhsminor.yy378 = createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); } + yymsp[0].minor.yy378 = yylhsminor.yy378; + break; + case 194: /* signed ::= NK_PLUS NK_INTEGER */ +{ yymsp[-1].minor.yy378 = createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); } + break; + case 195: /* signed ::= NK_MINUS NK_INTEGER */ { SToken t = yymsp[-1].minor.yy0; t.n = (yymsp[0].minor.yy0.z + yymsp[0].minor.yy0.n) - yymsp[-1].minor.yy0.z; - yylhsminor.yy140 = createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &t); + yylhsminor.yy378 = createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &t); } - yymsp[-1].minor.yy140 = yylhsminor.yy140; + yymsp[-1].minor.yy378 = yylhsminor.yy378; break; - case 195: /* signed ::= NK_FLOAT */ -{ yylhsminor.yy140 = createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &yymsp[0].minor.yy0); } - yymsp[0].minor.yy140 = yylhsminor.yy140; + case 196: /* signed ::= NK_FLOAT */ +{ yylhsminor.yy378 = createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &yymsp[0].minor.yy0); } + yymsp[0].minor.yy378 = yylhsminor.yy378; break; - case 196: /* signed ::= NK_PLUS NK_FLOAT */ -{ yymsp[-1].minor.yy140 = createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &yymsp[0].minor.yy0); } + case 197: /* signed ::= NK_PLUS NK_FLOAT */ +{ yymsp[-1].minor.yy378 = createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &yymsp[0].minor.yy0); } break; - case 197: /* signed ::= NK_MINUS NK_FLOAT */ + case 198: /* signed ::= NK_MINUS NK_FLOAT */ { SToken t = yymsp[-1].minor.yy0; t.n = (yymsp[0].minor.yy0.z + yymsp[0].minor.yy0.n) - yymsp[-1].minor.yy0.z; - yylhsminor.yy140 = createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &t); + yylhsminor.yy378 = createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &t); } - yymsp[-1].minor.yy140 = yylhsminor.yy140; + yymsp[-1].minor.yy378 = yylhsminor.yy378; break; - case 199: /* signed_literal ::= NK_STRING */ -{ yylhsminor.yy140 = createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0); } - yymsp[0].minor.yy140 = yylhsminor.yy140; + case 200: /* signed_literal ::= NK_STRING */ +{ yylhsminor.yy378 = createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0); } + yymsp[0].minor.yy378 = yylhsminor.yy378; break; - case 200: /* signed_literal ::= NK_BOOL */ -{ yylhsminor.yy140 = createValueNode(pCxt, TSDB_DATA_TYPE_BOOL, &yymsp[0].minor.yy0); } - yymsp[0].minor.yy140 = yylhsminor.yy140; + case 201: /* signed_literal ::= NK_BOOL */ +{ yylhsminor.yy378 = createValueNode(pCxt, TSDB_DATA_TYPE_BOOL, &yymsp[0].minor.yy0); } + yymsp[0].minor.yy378 = yylhsminor.yy378; break; - case 201: /* signed_literal ::= TIMESTAMP NK_STRING */ -{ yymsp[-1].minor.yy140 = createValueNode(pCxt, TSDB_DATA_TYPE_TIMESTAMP, &yymsp[0].minor.yy0); } + case 202: /* signed_literal ::= TIMESTAMP NK_STRING */ +{ yymsp[-1].minor.yy378 = createValueNode(pCxt, TSDB_DATA_TYPE_TIMESTAMP, &yymsp[0].minor.yy0); } break; - case 202: /* signed_literal ::= duration_literal */ - case 327: /* search_condition ::= common_expression */ yytestcase(yyruleno==327); -{ yylhsminor.yy140 = releaseRawExprNode(pCxt, yymsp[0].minor.yy140); } - yymsp[0].minor.yy140 = yylhsminor.yy140; + case 203: /* signed_literal ::= duration_literal */ + case 328: /* search_condition ::= common_expression */ yytestcase(yyruleno==328); +{ yylhsminor.yy378 = releaseRawExprNode(pCxt, yymsp[0].minor.yy378); } + yymsp[0].minor.yy378 = yylhsminor.yy378; break; - case 216: /* expression ::= function_name NK_LP expression_list NK_RP */ -{ yylhsminor.yy140 = createRawExprNodeExt(pCxt, &yymsp[-3].minor.yy149, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[-3].minor.yy149, yymsp[-1].minor.yy136)); } - yymsp[-3].minor.yy140 = yylhsminor.yy140; + case 217: /* expression ::= function_name NK_LP expression_list NK_RP */ +{ yylhsminor.yy378 = createRawExprNodeExt(pCxt, &yymsp[-3].minor.yy183, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[-3].minor.yy183, yymsp[-1].minor.yy404)); } + yymsp[-3].minor.yy378 = yylhsminor.yy378; break; - case 217: /* expression ::= function_name NK_LP NK_STAR NK_RP */ -{ yylhsminor.yy140 = createRawExprNodeExt(pCxt, &yymsp[-3].minor.yy149, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[-3].minor.yy149, createNodeList(pCxt, createColumnNode(pCxt, NULL, &yymsp[-1].minor.yy0)))); } - yymsp[-3].minor.yy140 = yylhsminor.yy140; + case 218: /* expression ::= function_name NK_LP NK_STAR NK_RP */ +{ yylhsminor.yy378 = createRawExprNodeExt(pCxt, &yymsp[-3].minor.yy183, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[-3].minor.yy183, createNodeList(pCxt, createColumnNode(pCxt, NULL, &yymsp[-1].minor.yy0)))); } + yymsp[-3].minor.yy378 = yylhsminor.yy378; break; - case 219: /* expression ::= NK_LP expression NK_RP */ - case 255: /* boolean_primary ::= NK_LP boolean_value_expression NK_RP */ yytestcase(yyruleno==255); -{ yylhsminor.yy140 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0, releaseRawExprNode(pCxt, yymsp[-1].minor.yy140)); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; + case 220: /* expression ::= NK_LP expression NK_RP */ + case 256: /* boolean_primary ::= NK_LP boolean_value_expression NK_RP */ yytestcase(yyruleno==256); +{ yylhsminor.yy378 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0, releaseRawExprNode(pCxt, yymsp[-1].minor.yy378)); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; - case 220: /* expression ::= NK_PLUS expression */ + case 221: /* expression ::= NK_PLUS expression */ { - SToken t = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy140); - yylhsminor.yy140 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &t, releaseRawExprNode(pCxt, yymsp[0].minor.yy140)); + SToken t = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy378); + yylhsminor.yy378 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &t, releaseRawExprNode(pCxt, yymsp[0].minor.yy378)); } - yymsp[-1].minor.yy140 = yylhsminor.yy140; + yymsp[-1].minor.yy378 = yylhsminor.yy378; break; - case 221: /* expression ::= NK_MINUS expression */ + case 222: /* expression ::= NK_MINUS expression */ { - SToken t = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy140); - yylhsminor.yy140 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &t, createOperatorNode(pCxt, OP_TYPE_SUB, releaseRawExprNode(pCxt, yymsp[0].minor.yy140), NULL)); + SToken t = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy378); + yylhsminor.yy378 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &t, createOperatorNode(pCxt, OP_TYPE_SUB, releaseRawExprNode(pCxt, yymsp[0].minor.yy378), NULL)); } - yymsp[-1].minor.yy140 = yylhsminor.yy140; + yymsp[-1].minor.yy378 = yylhsminor.yy378; break; - case 222: /* expression ::= expression NK_PLUS expression */ + case 223: /* expression ::= expression NK_PLUS expression */ { - SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy140); - SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy140); - yylhsminor.yy140 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_ADD, releaseRawExprNode(pCxt, yymsp[-2].minor.yy140), releaseRawExprNode(pCxt, yymsp[0].minor.yy140))); + SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy378); + SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy378); + yylhsminor.yy378 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_ADD, releaseRawExprNode(pCxt, yymsp[-2].minor.yy378), releaseRawExprNode(pCxt, yymsp[0].minor.yy378))); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; - case 223: /* expression ::= expression NK_MINUS expression */ + case 224: /* expression ::= expression NK_MINUS expression */ { - SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy140); - SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy140); - yylhsminor.yy140 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_SUB, releaseRawExprNode(pCxt, yymsp[-2].minor.yy140), releaseRawExprNode(pCxt, yymsp[0].minor.yy140))); + SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy378); + SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy378); + yylhsminor.yy378 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_SUB, releaseRawExprNode(pCxt, yymsp[-2].minor.yy378), releaseRawExprNode(pCxt, yymsp[0].minor.yy378))); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; - case 224: /* expression ::= expression NK_STAR expression */ + case 225: /* expression ::= expression NK_STAR expression */ { - SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy140); - SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy140); - yylhsminor.yy140 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_MULTI, releaseRawExprNode(pCxt, yymsp[-2].minor.yy140), releaseRawExprNode(pCxt, yymsp[0].minor.yy140))); + SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy378); + SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy378); + yylhsminor.yy378 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_MULTI, releaseRawExprNode(pCxt, yymsp[-2].minor.yy378), releaseRawExprNode(pCxt, yymsp[0].minor.yy378))); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; - case 225: /* expression ::= expression NK_SLASH expression */ + case 226: /* expression ::= expression NK_SLASH expression */ { - SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy140); - SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy140); - yylhsminor.yy140 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_DIV, releaseRawExprNode(pCxt, yymsp[-2].minor.yy140), releaseRawExprNode(pCxt, yymsp[0].minor.yy140))); + SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy378); + SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy378); + yylhsminor.yy378 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_DIV, releaseRawExprNode(pCxt, yymsp[-2].minor.yy378), releaseRawExprNode(pCxt, yymsp[0].minor.yy378))); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; - case 226: /* expression ::= expression NK_REM expression */ + case 227: /* expression ::= expression NK_REM expression */ { - SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy140); - SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy140); - yylhsminor.yy140 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_MOD, releaseRawExprNode(pCxt, yymsp[-2].minor.yy140), releaseRawExprNode(pCxt, yymsp[0].minor.yy140))); + SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy378); + SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy378); + yylhsminor.yy378 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_MOD, releaseRawExprNode(pCxt, yymsp[-2].minor.yy378), releaseRawExprNode(pCxt, yymsp[0].minor.yy378))); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; - case 227: /* expression_list ::= expression */ -{ yylhsminor.yy136 = createNodeList(pCxt, releaseRawExprNode(pCxt, yymsp[0].minor.yy140)); } - yymsp[0].minor.yy136 = yylhsminor.yy136; + case 228: /* expression_list ::= expression */ +{ yylhsminor.yy404 = createNodeList(pCxt, releaseRawExprNode(pCxt, yymsp[0].minor.yy378)); } + yymsp[0].minor.yy404 = yylhsminor.yy404; break; - case 228: /* expression_list ::= expression_list NK_COMMA expression */ -{ yylhsminor.yy136 = addNodeToList(pCxt, yymsp[-2].minor.yy136, releaseRawExprNode(pCxt, yymsp[0].minor.yy140)); } - yymsp[-2].minor.yy136 = yylhsminor.yy136; + case 229: /* expression_list ::= expression_list NK_COMMA expression */ +{ yylhsminor.yy404 = addNodeToList(pCxt, yymsp[-2].minor.yy404, releaseRawExprNode(pCxt, yymsp[0].minor.yy378)); } + yymsp[-2].minor.yy404 = yylhsminor.yy404; break; - case 229: /* column_reference ::= column_name */ -{ yylhsminor.yy140 = createRawExprNode(pCxt, &yymsp[0].minor.yy149, createColumnNode(pCxt, NULL, &yymsp[0].minor.yy149)); } - yymsp[0].minor.yy140 = yylhsminor.yy140; + case 230: /* column_reference ::= column_name */ +{ yylhsminor.yy378 = createRawExprNode(pCxt, &yymsp[0].minor.yy183, createColumnNode(pCxt, NULL, &yymsp[0].minor.yy183)); } + yymsp[0].minor.yy378 = yylhsminor.yy378; break; - case 230: /* column_reference ::= table_name NK_DOT column_name */ -{ yylhsminor.yy140 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy149, &yymsp[0].minor.yy149, createColumnNode(pCxt, &yymsp[-2].minor.yy149, &yymsp[0].minor.yy149)); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; + case 231: /* column_reference ::= table_name NK_DOT column_name */ +{ yylhsminor.yy378 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy183, &yymsp[0].minor.yy183, createColumnNode(pCxt, &yymsp[-2].minor.yy183, &yymsp[0].minor.yy183)); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; - case 231: /* predicate ::= expression compare_op expression */ - case 236: /* predicate ::= expression in_op in_predicate_value */ yytestcase(yyruleno==236); + case 232: /* predicate ::= expression compare_op expression */ + case 237: /* predicate ::= expression in_op in_predicate_value */ yytestcase(yyruleno==237); { - SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy140); - SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy140); - yylhsminor.yy140 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, yymsp[-1].minor.yy320, releaseRawExprNode(pCxt, yymsp[-2].minor.yy140), releaseRawExprNode(pCxt, yymsp[0].minor.yy140))); + SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy378); + SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy378); + yylhsminor.yy378 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, yymsp[-1].minor.yy366, releaseRawExprNode(pCxt, yymsp[-2].minor.yy378), releaseRawExprNode(pCxt, yymsp[0].minor.yy378))); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; - case 232: /* predicate ::= expression BETWEEN expression AND expression */ + case 233: /* predicate ::= expression BETWEEN expression AND expression */ { - SToken s = getTokenFromRawExprNode(pCxt, yymsp[-4].minor.yy140); - SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy140); - yylhsminor.yy140 = createRawExprNodeExt(pCxt, &s, &e, createBetweenAnd(pCxt, releaseRawExprNode(pCxt, yymsp[-4].minor.yy140), releaseRawExprNode(pCxt, yymsp[-2].minor.yy140), releaseRawExprNode(pCxt, yymsp[0].minor.yy140))); + SToken s = getTokenFromRawExprNode(pCxt, yymsp[-4].minor.yy378); + SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy378); + yylhsminor.yy378 = createRawExprNodeExt(pCxt, &s, &e, createBetweenAnd(pCxt, releaseRawExprNode(pCxt, yymsp[-4].minor.yy378), releaseRawExprNode(pCxt, yymsp[-2].minor.yy378), releaseRawExprNode(pCxt, yymsp[0].minor.yy378))); } - yymsp[-4].minor.yy140 = yylhsminor.yy140; + yymsp[-4].minor.yy378 = yylhsminor.yy378; break; - case 233: /* predicate ::= expression NOT BETWEEN expression AND expression */ + case 234: /* predicate ::= expression NOT BETWEEN expression AND expression */ { - SToken s = getTokenFromRawExprNode(pCxt, yymsp[-5].minor.yy140); - SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy140); - yylhsminor.yy140 = createRawExprNodeExt(pCxt, &s, &e, createNotBetweenAnd(pCxt, releaseRawExprNode(pCxt, yymsp[-2].minor.yy140), releaseRawExprNode(pCxt, yymsp[-5].minor.yy140), releaseRawExprNode(pCxt, yymsp[0].minor.yy140))); + SToken s = getTokenFromRawExprNode(pCxt, yymsp[-5].minor.yy378); + SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy378); + yylhsminor.yy378 = createRawExprNodeExt(pCxt, &s, &e, createNotBetweenAnd(pCxt, releaseRawExprNode(pCxt, yymsp[-2].minor.yy378), releaseRawExprNode(pCxt, yymsp[-5].minor.yy378), releaseRawExprNode(pCxt, yymsp[0].minor.yy378))); } - yymsp[-5].minor.yy140 = yylhsminor.yy140; + yymsp[-5].minor.yy378 = yylhsminor.yy378; break; - case 234: /* predicate ::= expression IS NULL */ + case 235: /* predicate ::= expression IS NULL */ { - SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy140); - yylhsminor.yy140 = createRawExprNodeExt(pCxt, &s, &yymsp[0].minor.yy0, createOperatorNode(pCxt, OP_TYPE_IS_NULL, releaseRawExprNode(pCxt, yymsp[-2].minor.yy140), NULL)); + SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy378); + yylhsminor.yy378 = createRawExprNodeExt(pCxt, &s, &yymsp[0].minor.yy0, createOperatorNode(pCxt, OP_TYPE_IS_NULL, releaseRawExprNode(pCxt, yymsp[-2].minor.yy378), NULL)); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; - case 235: /* predicate ::= expression IS NOT NULL */ + case 236: /* predicate ::= expression IS NOT NULL */ { - SToken s = getTokenFromRawExprNode(pCxt, yymsp[-3].minor.yy140); - yylhsminor.yy140 = createRawExprNodeExt(pCxt, &s, &yymsp[0].minor.yy0, createOperatorNode(pCxt, OP_TYPE_IS_NOT_NULL, releaseRawExprNode(pCxt, yymsp[-3].minor.yy140), NULL)); + SToken s = getTokenFromRawExprNode(pCxt, yymsp[-3].minor.yy378); + yylhsminor.yy378 = createRawExprNodeExt(pCxt, &s, &yymsp[0].minor.yy0, createOperatorNode(pCxt, OP_TYPE_IS_NOT_NULL, releaseRawExprNode(pCxt, yymsp[-3].minor.yy378), NULL)); } - yymsp[-3].minor.yy140 = yylhsminor.yy140; + yymsp[-3].minor.yy378 = yylhsminor.yy378; break; - case 237: /* compare_op ::= NK_LT */ -{ yymsp[0].minor.yy320 = OP_TYPE_LOWER_THAN; } + case 238: /* compare_op ::= NK_LT */ +{ yymsp[0].minor.yy366 = OP_TYPE_LOWER_THAN; } break; - case 238: /* compare_op ::= NK_GT */ -{ yymsp[0].minor.yy320 = OP_TYPE_GREATER_THAN; } + case 239: /* compare_op ::= NK_GT */ +{ yymsp[0].minor.yy366 = OP_TYPE_GREATER_THAN; } break; - case 239: /* compare_op ::= NK_LE */ -{ yymsp[0].minor.yy320 = OP_TYPE_LOWER_EQUAL; } + case 240: /* compare_op ::= NK_LE */ +{ yymsp[0].minor.yy366 = OP_TYPE_LOWER_EQUAL; } break; - case 240: /* compare_op ::= NK_GE */ -{ yymsp[0].minor.yy320 = OP_TYPE_GREATER_EQUAL; } + case 241: /* compare_op ::= NK_GE */ +{ yymsp[0].minor.yy366 = OP_TYPE_GREATER_EQUAL; } break; - case 241: /* compare_op ::= NK_NE */ -{ yymsp[0].minor.yy320 = OP_TYPE_NOT_EQUAL; } + case 242: /* compare_op ::= NK_NE */ +{ yymsp[0].minor.yy366 = OP_TYPE_NOT_EQUAL; } break; - case 242: /* compare_op ::= NK_EQ */ -{ yymsp[0].minor.yy320 = OP_TYPE_EQUAL; } + case 243: /* compare_op ::= NK_EQ */ +{ yymsp[0].minor.yy366 = OP_TYPE_EQUAL; } break; - case 243: /* compare_op ::= LIKE */ -{ yymsp[0].minor.yy320 = OP_TYPE_LIKE; } + case 244: /* compare_op ::= LIKE */ +{ yymsp[0].minor.yy366 = OP_TYPE_LIKE; } break; - case 244: /* compare_op ::= NOT LIKE */ -{ yymsp[-1].minor.yy320 = OP_TYPE_NOT_LIKE; } + case 245: /* compare_op ::= NOT LIKE */ +{ yymsp[-1].minor.yy366 = OP_TYPE_NOT_LIKE; } break; - case 245: /* compare_op ::= MATCH */ -{ yymsp[0].minor.yy320 = OP_TYPE_MATCH; } + case 246: /* compare_op ::= MATCH */ +{ yymsp[0].minor.yy366 = OP_TYPE_MATCH; } break; - case 246: /* compare_op ::= NMATCH */ -{ yymsp[0].minor.yy320 = OP_TYPE_NMATCH; } + case 247: /* compare_op ::= NMATCH */ +{ yymsp[0].minor.yy366 = OP_TYPE_NMATCH; } break; - case 247: /* in_op ::= IN */ -{ yymsp[0].minor.yy320 = OP_TYPE_IN; } + case 248: /* in_op ::= IN */ +{ yymsp[0].minor.yy366 = OP_TYPE_IN; } break; - case 248: /* in_op ::= NOT IN */ -{ yymsp[-1].minor.yy320 = OP_TYPE_NOT_IN; } + case 249: /* in_op ::= NOT IN */ +{ yymsp[-1].minor.yy366 = OP_TYPE_NOT_IN; } break; - case 249: /* in_predicate_value ::= NK_LP expression_list NK_RP */ -{ yylhsminor.yy140 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0, createNodeListNode(pCxt, yymsp[-1].minor.yy136)); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; + case 250: /* in_predicate_value ::= NK_LP expression_list NK_RP */ +{ yylhsminor.yy378 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0, createNodeListNode(pCxt, yymsp[-1].minor.yy404)); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; - case 251: /* boolean_value_expression ::= NOT boolean_primary */ + case 252: /* boolean_value_expression ::= NOT boolean_primary */ { - SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy140); - yylhsminor.yy140 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &e, createLogicConditionNode(pCxt, LOGIC_COND_TYPE_NOT, releaseRawExprNode(pCxt, yymsp[0].minor.yy140), NULL)); + SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy378); + yylhsminor.yy378 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &e, createLogicConditionNode(pCxt, LOGIC_COND_TYPE_NOT, releaseRawExprNode(pCxt, yymsp[0].minor.yy378), NULL)); } - yymsp[-1].minor.yy140 = yylhsminor.yy140; + yymsp[-1].minor.yy378 = yylhsminor.yy378; break; - case 252: /* boolean_value_expression ::= boolean_value_expression OR boolean_value_expression */ + case 253: /* boolean_value_expression ::= boolean_value_expression OR boolean_value_expression */ { - SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy140); - SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy140); - yylhsminor.yy140 = createRawExprNodeExt(pCxt, &s, &e, createLogicConditionNode(pCxt, LOGIC_COND_TYPE_OR, releaseRawExprNode(pCxt, yymsp[-2].minor.yy140), releaseRawExprNode(pCxt, yymsp[0].minor.yy140))); + SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy378); + SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy378); + yylhsminor.yy378 = createRawExprNodeExt(pCxt, &s, &e, createLogicConditionNode(pCxt, LOGIC_COND_TYPE_OR, releaseRawExprNode(pCxt, yymsp[-2].minor.yy378), releaseRawExprNode(pCxt, yymsp[0].minor.yy378))); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; - case 253: /* boolean_value_expression ::= boolean_value_expression AND boolean_value_expression */ + case 254: /* boolean_value_expression ::= boolean_value_expression AND boolean_value_expression */ { - SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy140); - SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy140); - yylhsminor.yy140 = createRawExprNodeExt(pCxt, &s, &e, createLogicConditionNode(pCxt, LOGIC_COND_TYPE_AND, releaseRawExprNode(pCxt, yymsp[-2].minor.yy140), releaseRawExprNode(pCxt, yymsp[0].minor.yy140))); + SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy378); + SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy378); + yylhsminor.yy378 = createRawExprNodeExt(pCxt, &s, &e, createLogicConditionNode(pCxt, LOGIC_COND_TYPE_AND, releaseRawExprNode(pCxt, yymsp[-2].minor.yy378), releaseRawExprNode(pCxt, yymsp[0].minor.yy378))); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; - case 258: /* from_clause ::= FROM table_reference_list */ - case 288: /* where_clause_opt ::= WHERE search_condition */ yytestcase(yyruleno==288); - case 311: /* having_clause_opt ::= HAVING search_condition */ yytestcase(yyruleno==311); -{ yymsp[-1].minor.yy140 = yymsp[0].minor.yy140; } + case 259: /* from_clause ::= FROM table_reference_list */ + case 289: /* where_clause_opt ::= WHERE search_condition */ yytestcase(yyruleno==289); + case 312: /* having_clause_opt ::= HAVING search_condition */ yytestcase(yyruleno==312); +{ yymsp[-1].minor.yy378 = yymsp[0].minor.yy378; } break; - case 260: /* table_reference_list ::= table_reference_list NK_COMMA table_reference */ -{ yylhsminor.yy140 = createJoinTableNode(pCxt, JOIN_TYPE_INNER, yymsp[-2].minor.yy140, yymsp[0].minor.yy140, NULL); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; + case 261: /* table_reference_list ::= table_reference_list NK_COMMA table_reference */ +{ yylhsminor.yy378 = createJoinTableNode(pCxt, JOIN_TYPE_INNER, yymsp[-2].minor.yy378, yymsp[0].minor.yy378, NULL); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; - case 263: /* table_primary ::= table_name alias_opt */ -{ yylhsminor.yy140 = createRealTableNode(pCxt, NULL, &yymsp[-1].minor.yy149, &yymsp[0].minor.yy149); } - yymsp[-1].minor.yy140 = yylhsminor.yy140; + case 264: /* table_primary ::= table_name alias_opt */ +{ yylhsminor.yy378 = createRealTableNode(pCxt, NULL, &yymsp[-1].minor.yy183, &yymsp[0].minor.yy183); } + yymsp[-1].minor.yy378 = yylhsminor.yy378; break; - case 264: /* table_primary ::= db_name NK_DOT table_name alias_opt */ -{ yylhsminor.yy140 = createRealTableNode(pCxt, &yymsp[-3].minor.yy149, &yymsp[-1].minor.yy149, &yymsp[0].minor.yy149); } - yymsp[-3].minor.yy140 = yylhsminor.yy140; + case 265: /* table_primary ::= db_name NK_DOT table_name alias_opt */ +{ yylhsminor.yy378 = createRealTableNode(pCxt, &yymsp[-3].minor.yy183, &yymsp[-1].minor.yy183, &yymsp[0].minor.yy183); } + yymsp[-3].minor.yy378 = yylhsminor.yy378; break; - case 265: /* table_primary ::= subquery alias_opt */ -{ yylhsminor.yy140 = createTempTableNode(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy140), &yymsp[0].minor.yy149); } - yymsp[-1].minor.yy140 = yylhsminor.yy140; + case 266: /* table_primary ::= subquery alias_opt */ +{ yylhsminor.yy378 = createTempTableNode(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy378), &yymsp[0].minor.yy183); } + yymsp[-1].minor.yy378 = yylhsminor.yy378; break; - case 267: /* alias_opt ::= */ -{ yymsp[1].minor.yy149 = nil_token; } + case 268: /* alias_opt ::= */ +{ yymsp[1].minor.yy183 = nil_token; } break; - case 268: /* alias_opt ::= table_alias */ -{ yylhsminor.yy149 = yymsp[0].minor.yy149; } - yymsp[0].minor.yy149 = yylhsminor.yy149; + case 269: /* alias_opt ::= table_alias */ +{ yylhsminor.yy183 = yymsp[0].minor.yy183; } + yymsp[0].minor.yy183 = yylhsminor.yy183; break; - case 269: /* alias_opt ::= AS table_alias */ -{ yymsp[-1].minor.yy149 = yymsp[0].minor.yy149; } + case 270: /* alias_opt ::= AS table_alias */ +{ yymsp[-1].minor.yy183 = yymsp[0].minor.yy183; } break; - case 270: /* parenthesized_joined_table ::= NK_LP joined_table NK_RP */ - case 271: /* parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP */ yytestcase(yyruleno==271); -{ yymsp[-2].minor.yy140 = yymsp[-1].minor.yy140; } + case 271: /* parenthesized_joined_table ::= NK_LP joined_table NK_RP */ + case 272: /* parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP */ yytestcase(yyruleno==272); +{ yymsp[-2].minor.yy378 = yymsp[-1].minor.yy378; } break; - case 272: /* joined_table ::= table_reference join_type JOIN table_reference ON search_condition */ -{ yylhsminor.yy140 = createJoinTableNode(pCxt, yymsp[-4].minor.yy144, yymsp[-5].minor.yy140, yymsp[-2].minor.yy140, yymsp[0].minor.yy140); } - yymsp[-5].minor.yy140 = yylhsminor.yy140; + case 273: /* joined_table ::= table_reference join_type JOIN table_reference ON search_condition */ +{ yylhsminor.yy378 = createJoinTableNode(pCxt, yymsp[-4].minor.yy162, yymsp[-5].minor.yy378, yymsp[-2].minor.yy378, yymsp[0].minor.yy378); } + yymsp[-5].minor.yy378 = yylhsminor.yy378; break; - case 273: /* join_type ::= */ -{ yymsp[1].minor.yy144 = JOIN_TYPE_INNER; } + case 274: /* join_type ::= */ +{ yymsp[1].minor.yy162 = JOIN_TYPE_INNER; } break; - case 274: /* join_type ::= INNER */ -{ yymsp[0].minor.yy144 = JOIN_TYPE_INNER; } + case 275: /* join_type ::= INNER */ +{ yymsp[0].minor.yy162 = JOIN_TYPE_INNER; } break; - case 275: /* query_specification ::= SELECT set_quantifier_opt select_list from_clause where_clause_opt partition_by_clause_opt twindow_clause_opt group_by_clause_opt having_clause_opt */ + case 276: /* query_specification ::= SELECT set_quantifier_opt select_list from_clause where_clause_opt partition_by_clause_opt twindow_clause_opt group_by_clause_opt having_clause_opt */ { - yymsp[-8].minor.yy140 = createSelectStmt(pCxt, yymsp[-7].minor.yy497, yymsp[-6].minor.yy136, yymsp[-5].minor.yy140); - yymsp[-8].minor.yy140 = addWhereClause(pCxt, yymsp[-8].minor.yy140, yymsp[-4].minor.yy140); - yymsp[-8].minor.yy140 = addPartitionByClause(pCxt, yymsp[-8].minor.yy140, yymsp[-3].minor.yy136); - yymsp[-8].minor.yy140 = addWindowClauseClause(pCxt, yymsp[-8].minor.yy140, yymsp[-2].minor.yy140); - yymsp[-8].minor.yy140 = addGroupByClause(pCxt, yymsp[-8].minor.yy140, yymsp[-1].minor.yy136); - yymsp[-8].minor.yy140 = addHavingClause(pCxt, yymsp[-8].minor.yy140, yymsp[0].minor.yy140); + yymsp[-8].minor.yy378 = createSelectStmt(pCxt, yymsp[-7].minor.yy215, yymsp[-6].minor.yy404, yymsp[-5].minor.yy378); + yymsp[-8].minor.yy378 = addWhereClause(pCxt, yymsp[-8].minor.yy378, yymsp[-4].minor.yy378); + yymsp[-8].minor.yy378 = addPartitionByClause(pCxt, yymsp[-8].minor.yy378, yymsp[-3].minor.yy404); + yymsp[-8].minor.yy378 = addWindowClauseClause(pCxt, yymsp[-8].minor.yy378, yymsp[-2].minor.yy378); + yymsp[-8].minor.yy378 = addGroupByClause(pCxt, yymsp[-8].minor.yy378, yymsp[-1].minor.yy404); + yymsp[-8].minor.yy378 = addHavingClause(pCxt, yymsp[-8].minor.yy378, yymsp[0].minor.yy378); } break; - case 277: /* set_quantifier_opt ::= DISTINCT */ -{ yymsp[0].minor.yy497 = true; } + case 278: /* set_quantifier_opt ::= DISTINCT */ +{ yymsp[0].minor.yy215 = true; } break; - case 278: /* set_quantifier_opt ::= ALL */ -{ yymsp[0].minor.yy497 = false; } + case 279: /* set_quantifier_opt ::= ALL */ +{ yymsp[0].minor.yy215 = false; } break; - case 279: /* select_list ::= NK_STAR */ -{ yymsp[0].minor.yy136 = NULL; } + case 280: /* select_list ::= NK_STAR */ +{ yymsp[0].minor.yy404 = NULL; } break; - case 283: /* select_item ::= common_expression */ + case 284: /* select_item ::= common_expression */ { - SToken t = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy140); - yylhsminor.yy140 = setProjectionAlias(pCxt, releaseRawExprNode(pCxt, yymsp[0].minor.yy140), &t); + SToken t = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy378); + yylhsminor.yy378 = setProjectionAlias(pCxt, releaseRawExprNode(pCxt, yymsp[0].minor.yy378), &t); } - yymsp[0].minor.yy140 = yylhsminor.yy140; + yymsp[0].minor.yy378 = yylhsminor.yy378; break; - case 284: /* select_item ::= common_expression column_alias */ -{ yylhsminor.yy140 = setProjectionAlias(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy140), &yymsp[0].minor.yy149); } - yymsp[-1].minor.yy140 = yylhsminor.yy140; + case 285: /* select_item ::= common_expression column_alias */ +{ yylhsminor.yy378 = setProjectionAlias(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy378), &yymsp[0].minor.yy183); } + yymsp[-1].minor.yy378 = yylhsminor.yy378; break; - case 285: /* select_item ::= common_expression AS column_alias */ -{ yylhsminor.yy140 = setProjectionAlias(pCxt, releaseRawExprNode(pCxt, yymsp[-2].minor.yy140), &yymsp[0].minor.yy149); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; + case 286: /* select_item ::= common_expression AS column_alias */ +{ yylhsminor.yy378 = setProjectionAlias(pCxt, releaseRawExprNode(pCxt, yymsp[-2].minor.yy378), &yymsp[0].minor.yy183); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; - case 286: /* select_item ::= table_name NK_DOT NK_STAR */ -{ yylhsminor.yy140 = createColumnNode(pCxt, &yymsp[-2].minor.yy149, &yymsp[0].minor.yy0); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; + case 287: /* select_item ::= table_name NK_DOT NK_STAR */ +{ yylhsminor.yy378 = createColumnNode(pCxt, &yymsp[-2].minor.yy183, &yymsp[0].minor.yy0); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; - case 290: /* partition_by_clause_opt ::= PARTITION BY expression_list */ - case 307: /* group_by_clause_opt ::= GROUP BY group_by_list */ yytestcase(yyruleno==307); - case 317: /* order_by_clause_opt ::= ORDER BY sort_specification_list */ yytestcase(yyruleno==317); -{ yymsp[-2].minor.yy136 = yymsp[0].minor.yy136; } + case 291: /* partition_by_clause_opt ::= PARTITION BY expression_list */ + case 308: /* group_by_clause_opt ::= GROUP BY group_by_list */ yytestcase(yyruleno==308); + case 318: /* order_by_clause_opt ::= ORDER BY sort_specification_list */ yytestcase(yyruleno==318); +{ yymsp[-2].minor.yy404 = yymsp[0].minor.yy404; } break; - case 292: /* twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA duration_literal NK_RP */ -{ yymsp[-5].minor.yy140 = createSessionWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy140), releaseRawExprNode(pCxt, yymsp[-1].minor.yy140)); } + case 293: /* twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA duration_literal NK_RP */ +{ yymsp[-5].minor.yy378 = createSessionWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy378), releaseRawExprNode(pCxt, yymsp[-1].minor.yy378)); } break; - case 293: /* twindow_clause_opt ::= STATE_WINDOW NK_LP column_reference NK_RP */ -{ yymsp[-3].minor.yy140 = createStateWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy140)); } + case 294: /* twindow_clause_opt ::= STATE_WINDOW NK_LP column_reference NK_RP */ +{ yymsp[-3].minor.yy378 = createStateWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy378)); } break; - case 294: /* twindow_clause_opt ::= INTERVAL NK_LP duration_literal NK_RP sliding_opt fill_opt */ -{ yymsp[-5].minor.yy140 = createIntervalWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy140), NULL, yymsp[-1].minor.yy140, yymsp[0].minor.yy140); } + case 295: /* twindow_clause_opt ::= INTERVAL NK_LP duration_literal NK_RP sliding_opt fill_opt */ +{ yymsp[-5].minor.yy378 = createIntervalWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy378), NULL, yymsp[-1].minor.yy378, yymsp[0].minor.yy378); } break; - case 295: /* twindow_clause_opt ::= INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt fill_opt */ -{ yymsp[-7].minor.yy140 = createIntervalWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-5].minor.yy140), releaseRawExprNode(pCxt, yymsp[-3].minor.yy140), yymsp[-1].minor.yy140, yymsp[0].minor.yy140); } + case 296: /* twindow_clause_opt ::= INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt fill_opt */ +{ yymsp[-7].minor.yy378 = createIntervalWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-5].minor.yy378), releaseRawExprNode(pCxt, yymsp[-3].minor.yy378), yymsp[-1].minor.yy378, yymsp[0].minor.yy378); } break; - case 297: /* sliding_opt ::= SLIDING NK_LP duration_literal NK_RP */ -{ yymsp[-3].minor.yy140 = releaseRawExprNode(pCxt, yymsp[-1].minor.yy140); } + case 298: /* sliding_opt ::= SLIDING NK_LP duration_literal NK_RP */ +{ yymsp[-3].minor.yy378 = releaseRawExprNode(pCxt, yymsp[-1].minor.yy378); } break; - case 299: /* fill_opt ::= FILL NK_LP fill_mode NK_RP */ -{ yymsp[-3].minor.yy140 = createFillNode(pCxt, yymsp[-1].minor.yy306, NULL); } + case 300: /* fill_opt ::= FILL NK_LP fill_mode NK_RP */ +{ yymsp[-3].minor.yy378 = createFillNode(pCxt, yymsp[-1].minor.yy466, NULL); } break; - case 300: /* fill_opt ::= FILL NK_LP VALUE NK_COMMA literal_list NK_RP */ -{ yymsp[-5].minor.yy140 = createFillNode(pCxt, FILL_MODE_VALUE, createNodeListNode(pCxt, yymsp[-1].minor.yy136)); } + case 301: /* fill_opt ::= FILL NK_LP VALUE NK_COMMA literal_list NK_RP */ +{ yymsp[-5].minor.yy378 = createFillNode(pCxt, FILL_MODE_VALUE, createNodeListNode(pCxt, yymsp[-1].minor.yy404)); } break; - case 301: /* fill_mode ::= NONE */ -{ yymsp[0].minor.yy306 = FILL_MODE_NONE; } + case 302: /* fill_mode ::= NONE */ +{ yymsp[0].minor.yy466 = FILL_MODE_NONE; } break; - case 302: /* fill_mode ::= PREV */ -{ yymsp[0].minor.yy306 = FILL_MODE_PREV; } + case 303: /* fill_mode ::= PREV */ +{ yymsp[0].minor.yy466 = FILL_MODE_PREV; } break; - case 303: /* fill_mode ::= NULL */ -{ yymsp[0].minor.yy306 = FILL_MODE_NULL; } + case 304: /* fill_mode ::= NULL */ +{ yymsp[0].minor.yy466 = FILL_MODE_NULL; } break; - case 304: /* fill_mode ::= LINEAR */ -{ yymsp[0].minor.yy306 = FILL_MODE_LINEAR; } + case 305: /* fill_mode ::= LINEAR */ +{ yymsp[0].minor.yy466 = FILL_MODE_LINEAR; } break; - case 305: /* fill_mode ::= NEXT */ -{ yymsp[0].minor.yy306 = FILL_MODE_NEXT; } + case 306: /* fill_mode ::= NEXT */ +{ yymsp[0].minor.yy466 = FILL_MODE_NEXT; } break; - case 308: /* group_by_list ::= expression */ -{ yylhsminor.yy136 = createNodeList(pCxt, createGroupingSetNode(pCxt, releaseRawExprNode(pCxt, yymsp[0].minor.yy140))); } - yymsp[0].minor.yy136 = yylhsminor.yy136; + case 309: /* group_by_list ::= expression */ +{ yylhsminor.yy404 = createNodeList(pCxt, createGroupingSetNode(pCxt, releaseRawExprNode(pCxt, yymsp[0].minor.yy378))); } + yymsp[0].minor.yy404 = yylhsminor.yy404; break; - case 309: /* group_by_list ::= group_by_list NK_COMMA expression */ -{ yylhsminor.yy136 = addNodeToList(pCxt, yymsp[-2].minor.yy136, createGroupingSetNode(pCxt, releaseRawExprNode(pCxt, yymsp[0].minor.yy140))); } - yymsp[-2].minor.yy136 = yylhsminor.yy136; + case 310: /* group_by_list ::= group_by_list NK_COMMA expression */ +{ yylhsminor.yy404 = addNodeToList(pCxt, yymsp[-2].minor.yy404, createGroupingSetNode(pCxt, releaseRawExprNode(pCxt, yymsp[0].minor.yy378))); } + yymsp[-2].minor.yy404 = yylhsminor.yy404; break; - case 312: /* query_expression ::= query_expression_body order_by_clause_opt slimit_clause_opt limit_clause_opt */ + case 313: /* query_expression ::= query_expression_body order_by_clause_opt slimit_clause_opt limit_clause_opt */ { - yylhsminor.yy140 = addOrderByClause(pCxt, yymsp[-3].minor.yy140, yymsp[-2].minor.yy136); - yylhsminor.yy140 = addSlimitClause(pCxt, yylhsminor.yy140, yymsp[-1].minor.yy140); - yylhsminor.yy140 = addLimitClause(pCxt, yylhsminor.yy140, yymsp[0].minor.yy140); + yylhsminor.yy378 = addOrderByClause(pCxt, yymsp[-3].minor.yy378, yymsp[-2].minor.yy404); + yylhsminor.yy378 = addSlimitClause(pCxt, yylhsminor.yy378, yymsp[-1].minor.yy378); + yylhsminor.yy378 = addLimitClause(pCxt, yylhsminor.yy378, yymsp[0].minor.yy378); } - yymsp[-3].minor.yy140 = yylhsminor.yy140; + yymsp[-3].minor.yy378 = yylhsminor.yy378; break; - case 314: /* query_expression_body ::= query_expression_body UNION ALL query_expression_body */ -{ yylhsminor.yy140 = createSetOperator(pCxt, SET_OP_TYPE_UNION_ALL, yymsp[-3].minor.yy140, yymsp[0].minor.yy140); } - yymsp[-3].minor.yy140 = yylhsminor.yy140; + case 315: /* query_expression_body ::= query_expression_body UNION ALL query_expression_body */ +{ yylhsminor.yy378 = createSetOperator(pCxt, SET_OP_TYPE_UNION_ALL, yymsp[-3].minor.yy378, yymsp[0].minor.yy378); } + yymsp[-3].minor.yy378 = yylhsminor.yy378; break; - case 319: /* slimit_clause_opt ::= SLIMIT NK_INTEGER */ - case 323: /* limit_clause_opt ::= LIMIT NK_INTEGER */ yytestcase(yyruleno==323); -{ yymsp[-1].minor.yy140 = createLimitNode(pCxt, &yymsp[0].minor.yy0, NULL); } + case 320: /* slimit_clause_opt ::= SLIMIT NK_INTEGER */ + case 324: /* limit_clause_opt ::= LIMIT NK_INTEGER */ yytestcase(yyruleno==324); +{ yymsp[-1].minor.yy378 = createLimitNode(pCxt, &yymsp[0].minor.yy0, NULL); } break; - case 320: /* slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER */ - case 324: /* limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER */ yytestcase(yyruleno==324); -{ yymsp[-3].minor.yy140 = createLimitNode(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0); } + case 321: /* slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER */ + case 325: /* limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER */ yytestcase(yyruleno==325); +{ yymsp[-3].minor.yy378 = createLimitNode(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0); } break; - case 321: /* slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER */ - case 325: /* limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER */ yytestcase(yyruleno==325); -{ yymsp[-3].minor.yy140 = createLimitNode(pCxt, &yymsp[0].minor.yy0, &yymsp[-2].minor.yy0); } + case 322: /* slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER */ + case 326: /* limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER */ yytestcase(yyruleno==326); +{ yymsp[-3].minor.yy378 = createLimitNode(pCxt, &yymsp[0].minor.yy0, &yymsp[-2].minor.yy0); } break; - case 326: /* subquery ::= NK_LP query_expression NK_RP */ -{ yylhsminor.yy140 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0, yymsp[-1].minor.yy140); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; + case 327: /* subquery ::= NK_LP query_expression NK_RP */ +{ yylhsminor.yy378 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0, yymsp[-1].minor.yy378); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; - case 330: /* sort_specification ::= expression ordering_specification_opt null_ordering_opt */ -{ yylhsminor.yy140 = createOrderByExprNode(pCxt, releaseRawExprNode(pCxt, yymsp[-2].minor.yy140), yymsp[-1].minor.yy158, yymsp[0].minor.yy73); } - yymsp[-2].minor.yy140 = yylhsminor.yy140; + case 331: /* sort_specification ::= expression ordering_specification_opt null_ordering_opt */ +{ yylhsminor.yy378 = createOrderByExprNode(pCxt, releaseRawExprNode(pCxt, yymsp[-2].minor.yy378), yymsp[-1].minor.yy400, yymsp[0].minor.yy151); } + yymsp[-2].minor.yy378 = yylhsminor.yy378; break; - case 331: /* ordering_specification_opt ::= */ -{ yymsp[1].minor.yy158 = ORDER_ASC; } + case 332: /* ordering_specification_opt ::= */ +{ yymsp[1].minor.yy400 = ORDER_ASC; } break; - case 332: /* ordering_specification_opt ::= ASC */ -{ yymsp[0].minor.yy158 = ORDER_ASC; } + case 333: /* ordering_specification_opt ::= ASC */ +{ yymsp[0].minor.yy400 = ORDER_ASC; } break; - case 333: /* ordering_specification_opt ::= DESC */ -{ yymsp[0].minor.yy158 = ORDER_DESC; } + case 334: /* ordering_specification_opt ::= DESC */ +{ yymsp[0].minor.yy400 = ORDER_DESC; } break; - case 334: /* null_ordering_opt ::= */ -{ yymsp[1].minor.yy73 = NULL_ORDER_DEFAULT; } + case 335: /* null_ordering_opt ::= */ +{ yymsp[1].minor.yy151 = NULL_ORDER_DEFAULT; } break; - case 335: /* null_ordering_opt ::= NULLS FIRST */ -{ yymsp[-1].minor.yy73 = NULL_ORDER_FIRST; } + case 336: /* null_ordering_opt ::= NULLS FIRST */ +{ yymsp[-1].minor.yy151 = NULL_ORDER_FIRST; } break; - case 336: /* null_ordering_opt ::= NULLS LAST */ -{ yymsp[-1].minor.yy73 = NULL_ORDER_LAST; } + case 337: /* null_ordering_opt ::= NULLS LAST */ +{ yymsp[-1].minor.yy151 = NULL_ORDER_LAST; } break; default: break; diff --git a/source/libs/parser/test/parserAstTest.cpp b/source/libs/parser/test/parserAstTest.cpp index 1813ad0827fc47207224de624dfaaf1468cfecc8..3057e06fe1d8fabe034d7a970a1a57624cfddbe1 100644 --- a/source/libs/parser/test/parserAstTest.cpp +++ b/source/libs/parser/test/parserAstTest.cpp @@ -416,6 +416,7 @@ TEST_F(ParserTest, createDatabase) { "VGROUPS 100 " "SINGLE_STABLE 0 " "STREAM_MODE 1 " + "RETENTIONS '15s:7d,1m:21d,15m:5y'" ); ASSERT_TRUE(run()); } @@ -469,7 +470,7 @@ TEST_F(ParserTest, createTable) { "c9 SMALLINT UNSIGNED COMMENT 'test column comment', c10 TINYINT, c11 TINYINT UNSIGNED, c12 BOOL, c13 NCHAR(30), c14 JSON, c15 VARCHAR(50)) " "TAGS (tsa TIMESTAMP, a1 INT, a2 INT UNSIGNED, a3 BIGINT, a4 BIGINT UNSIGNED, a5 FLOAT, a6 DOUBLE, a7 BINARY(20), a8 SMALLINT, " "a9 SMALLINT UNSIGNED COMMENT 'test column comment', a10 TINYINT, a11 TINYINT UNSIGNED, a12 BOOL, a13 NCHAR(30), a14 JSON, a15 VARCHAR(50)) " - "KEEP 100 TTL 100 COMMENT 'test create table' SMA(c1, c2, c3)" + "KEEP 100 TTL 100 COMMENT 'test create table' SMA(c1, c2, c3) ROLLUP (min) FILE_FACTOR 0.1 DELAY 2" ); ASSERT_TRUE(run()); @@ -491,7 +492,7 @@ TEST_F(ParserTest, createTable) { "c9 SMALLINT UNSIGNED COMMENT 'test column comment', c10 TINYINT, c11 TINYINT UNSIGNED, c12 BOOL, c13 NCHAR(30), c14 JSON, c15 VARCHAR(50)) " "TAGS (tsa TIMESTAMP, a1 INT, a2 INT UNSIGNED, a3 BIGINT, a4 BIGINT UNSIGNED, a5 FLOAT, a6 DOUBLE, a7 BINARY(20), a8 SMALLINT, " "a9 SMALLINT UNSIGNED COMMENT 'test column comment', a10 TINYINT, a11 TINYINT UNSIGNED, a12 BOOL, a13 NCHAR(30), a14 JSON, a15 VARCHAR(50)) " - "KEEP 100 TTL 100 COMMENT 'test create table' SMA(c1, c2, c3)" + "KEEP 100 TTL 100 COMMENT 'test create table' SMA(c1, c2, c3) ROLLUP (min) FILE_FACTOR 0.1 DELAY 2" ); ASSERT_TRUE(run()); }