/* ** 2000-05-29 ** ** The author disclaims copyright to this source code. In place of ** a legal notice, here is a blessing: ** ** May you do good and not evil. ** May you find forgiveness for yourself and forgive others. ** May you share freely, never taking more than you give. ** ************************************************************************* ** Driver template for the LEMON parser generator. ** ** The "lemon" program processes an LALR(1) input grammar file, then uses ** this template to construct a parser. The "lemon" program inserts text ** at each "%%" line. Also, any "P-a-r-s-e" identifer prefix (without the ** interstitial "-" characters) contained in this template is changed into ** the value of the %name directive from the grammar. Otherwise, the content ** of this template is copied straight through into the generate parser ** source file. ** ** The following is the concatenation of all %include directives from the ** input grammar file: */ #include #include /************ Begin %include sections from the grammar ************************/ #include #include #include #include #include #include "functionMgt.h" #include "nodes.h" #include "parToken.h" #include "ttokendef.h" #include "parAst.h" /**************** End of %include directives **********************************/ /* These constants specify the various numeric values for terminal symbols ** in a format understandable to "makeheaders". This section is blank unless ** "lemon" is run with the "-m" command-line option. ***************** Begin makeheaders token definitions *************************/ /**************** End makeheaders token definitions ***************************/ /* The next sections is a series of control #defines. ** various aspects of the generated parser. ** YYCODETYPE is the data type used to store the integer codes ** that represent terminal and non-terminal symbols. ** "unsigned char" is used if there are fewer than ** 256 symbols. Larger types otherwise. ** YYNOCODE is a number of type YYCODETYPE that is not used for ** any terminal or nonterminal symbol. ** YYFALLBACK If defined, this indicates that one or more tokens ** (also known as: "terminal symbols") have fall-back ** values which should be used if the original symbol ** would not parse. This permits keywords to sometimes ** be used as identifiers, for example. ** YYACTIONTYPE is the data type used for "action codes" - numbers ** that indicate what to do in response to the next ** token. ** ParseTOKENTYPE is the data type used for minor type for terminal ** symbols. Background: A "minor type" is a semantic ** value associated with a terminal or non-terminal ** symbols. For example, for an "ID" terminal symbol, ** the minor type might be the name of the identifier. ** Each non-terminal can have a different minor type. ** Terminal symbols all have the same minor type, though. ** This macros defines the minor type for terminal ** symbols. ** YYMINORTYPE is the data type used for all minor types. ** This is typically a union of many types, one of ** 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 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 ** ParseARG_STORE Code to store %extra_argument into yypParser ** ParseARG_FETCH Code to extract %extra_argument from yypParser ** ParseCTX_* As ParseARG_ except for %extra_context ** YYERRORSYMBOL is the code number of the error symbol. If not ** defined, then do no error processing. ** YYNSTATE the combined number of states. ** YYNRULE the number of rules in the grammar ** YYNTOKEN Number of terminal symbols ** YY_MAX_SHIFT Maximum value for shift actions ** YY_MIN_SHIFTREDUCE Minimum value for shift-reduce actions ** YY_MAX_SHIFTREDUCE Maximum value for shift-reduce actions ** YY_ERROR_ACTION The yy_action[] code for syntax error ** YY_ACCEPT_ACTION The yy_action[] code for accept ** YY_NO_ACTION The yy_action[] code for no-op ** YY_MIN_REDUCE Minimum value for reduce actions ** YY_MAX_REDUCE Maximum value for reduce actions */ #ifndef INTERFACE # define INTERFACE 1 #endif /************* Begin control #defines *****************************************/ #define YYCODETYPE unsigned short int #define YYNOCODE 315 #define YYACTIONTYPE unsigned short int #define ParseTOKENTYPE SToken typedef union { int yyinit; ParseTOKENTYPE yy0; SToken yy29; bool yy47; EFillMode yy144; EJoinType yy162; SNode* yy182; EOrder yy218; SNodeList* yy334; EOperatorType yy380; ENullOrder yy487; SAlterOption yy515; int32_t yy550; SDataType yy574; } YYMINORTYPE; #ifndef YYSTACKDEPTH #define YYSTACKDEPTH 100 #endif #define ParseARG_SDECL SAstCreateContext* pCxt ; #define ParseARG_PDECL , SAstCreateContext* pCxt #define ParseARG_PARAM ,pCxt #define ParseARG_FETCH SAstCreateContext* pCxt =yypParser->pCxt ; #define ParseARG_STORE yypParser->pCxt =pCxt ; #define ParseCTX_SDECL #define ParseCTX_PDECL #define ParseCTX_PARAM #define ParseCTX_FETCH #define ParseCTX_STORE #define YYNSTATE 548 #define YYNRULE 412 #define YYNRULE_WITH_ACTION 412 #define YYNTOKEN 209 #define YY_MAX_SHIFT 547 #define YY_MIN_SHIFTREDUCE 809 #define YY_MAX_SHIFTREDUCE 1220 #define YY_ERROR_ACTION 1221 #define YY_ACCEPT_ACTION 1222 #define YY_NO_ACTION 1223 #define YY_MIN_REDUCE 1224 #define YY_MAX_REDUCE 1635 /************* End control #defines *******************************************/ #define YY_NLOOKAHEAD ((int)(sizeof(yy_lookahead)/sizeof(yy_lookahead[0]))) /* Define the yytestcase() macro to be a no-op if is not already defined ** otherwise. ** ** Applications can choose to define yytestcase() in the %include section ** to a macro that can assist in verifying code coverage. For production ** code the yytestcase() macro should be turned off. But it is useful ** for testing. */ #ifndef yytestcase # define yytestcase(X) #endif /* Next are the tables used to determine what action to take based on the ** current state and lookahead token. These tables are used to implement ** functions that take a state number and lookahead value and return an ** action integer. ** ** Suppose the action integer is N. Then the action is determined as ** follows ** ** 0 <= N <= YY_MAX_SHIFT Shift N. That is, push the lookahead ** token onto the stack and goto state N. ** ** N between YY_MIN_SHIFTREDUCE Shift to an arbitrary state then ** and YY_MAX_SHIFTREDUCE reduce by rule N-YY_MIN_SHIFTREDUCE. ** ** N == YY_ERROR_ACTION A syntax error has occurred. ** ** N == YY_ACCEPT_ACTION The parser accepts its input. ** ** N == YY_NO_ACTION No such action. Denotes unused ** slots in the yy_action[] table. ** ** N between YY_MIN_REDUCE Reduce by rule N-YY_MIN_REDUCE ** and YY_MAX_REDUCE ** ** The action table is constructed as a single large table named yy_action[]. ** Given state S and lookahead X, the action is computed as either: ** ** (A) N = yy_action[ yy_shift_ofst[S] + X ] ** (B) N = yy_default[S] ** ** The (A) formula is preferred. The B formula is used instead if ** yy_lookahead[yy_shift_ofst[S]+X] is not equal to X. ** ** The formulas above are for computing the action when the lookahead is ** a terminal symbol. If the lookahead is a non-terminal (as occurs after ** a reduce action) then the yy_reduce_ofst[] array is used in place of ** the yy_shift_ofst[] array. ** ** The following are the tables generated in this section: ** ** yy_action[] A single table containing all actions. ** yy_lookahead[] A table containing the lookahead for each entry in ** yy_action. Used to detect hash collisions. ** yy_shift_ofst[] For each state, the offset into yy_action for ** shifting terminals. ** yy_reduce_ofst[] For each state, the offset into yy_action for ** shifting non-terminals after a reduce. ** yy_default[] Default action for each state. ** *********** Begin parsing tables **********************************************/ #define YY_ACTTAB_COUNT (1543) static const YYACTIONTYPE yy_action[] = { /* 0 */ 117, 1222, 1236, 1391, 450, 312, 1485, 269, 216, 256, /* 10 */ 1434, 1374, 30, 28, 1389, 21, 306, 1503, 1481, 1488, /* 20 */ 266, 501, 1054, 1316, 1074, 32, 31, 29, 27, 26, /* 30 */ 32, 31, 29, 27, 26, 238, 1077, 437, 1052, 257, /* 40 */ 1333, 1521, 32, 31, 29, 27, 26, 1614, 433, 1329, /* 50 */ 11, 30, 28, 1163, 282, 270, 1485, 1059, 449, 266, /* 60 */ 131, 1054, 1472, 115, 1612, 30, 28, 448, 1481, 1487, /* 70 */ 1503, 1346, 462, 266, 1, 1054, 277, 1052, 69, 1504, /* 80 */ 1505, 1510, 1553, 1425, 1427, 1614, 259, 1549, 126, 11, /* 90 */ 1263, 1052, 1224, 1177, 1521, 118, 1059, 544, 131, 1302, /* 100 */ 190, 433, 1612, 25, 194, 1096, 413, 1580, 274, 1053, /* 110 */ 1059, 449, 384, 1, 348, 1472, 93, 92, 91, 90, /* 120 */ 89, 88, 87, 86, 85, 1485, 12, 7, 1093, 395, /* 130 */ 52, 69, 1504, 1505, 1510, 1553, 544, 1481, 1487, 259, /* 140 */ 1549, 126, 393, 96, 152, 1422, 1055, 125, 1053, 250, /* 150 */ 544, 1339, 139, 365, 462, 361, 357, 353, 151, 305, /* 160 */ 1581, 304, 1053, 1058, 1078, 1079, 1080, 1081, 1108, 1109, /* 170 */ 1110, 1111, 1112, 1113, 1114, 164, 29, 27, 26, 372, /* 180 */ 1078, 1079, 1080, 1081, 53, 1055, 132, 149, 6, 463, /* 190 */ 132, 251, 132, 249, 248, 438, 371, 397, 310, 1055, /* 200 */ 132, 374, 1058, 1078, 1079, 1080, 1081, 1108, 1109, 1110, /* 210 */ 1111, 1112, 1113, 1114, 1344, 1322, 1058, 1078, 1079, 1080, /* 220 */ 1081, 1108, 1109, 1110, 1111, 1112, 1113, 1114, 1614, 30, /* 230 */ 28, 32, 31, 29, 27, 26, 436, 266, 132, 1054, /* 240 */ 1614, 131, 30, 28, 148, 1612, 121, 463, 145, 237, /* 250 */ 266, 1074, 1054, 1613, 1503, 1052, 72, 1612, 327, 1076, /* 260 */ 388, 339, 1521, 369, 348, 143, 1162, 11, 1052, 446, /* 270 */ 340, 1391, 1344, 450, 1059, 396, 498, 271, 1521, 1435, /* 280 */ 30, 28, 1389, 123, 463, 446, 1320, 1059, 266, 166, /* 290 */ 1054, 1, 391, 72, 1384, 449, 383, 385, 377, 1472, /* 300 */ 375, 423, 382, 165, 7, 97, 1052, 378, 376, 1344, /* 310 */ 379, 463, 463, 463, 544, 70, 1504, 1505, 1510, 1553, /* 320 */ 311, 319, 320, 1552, 1549, 1059, 1053, 544, 439, 42, /* 330 */ 1158, 846, 41, 845, 406, 498, 1344, 1344, 1344, 1053, /* 340 */ 164, 512, 7, 338, 372, 300, 333, 332, 331, 330, /* 350 */ 329, 847, 326, 325, 324, 323, 322, 318, 317, 316, /* 360 */ 315, 314, 313, 1055, 84, 544, 374, 83, 82, 81, /* 370 */ 80, 79, 78, 77, 76, 75, 1055, 1053, 407, 137, /* 380 */ 1058, 1078, 1079, 1080, 1081, 1108, 1109, 1110, 1111, 1112, /* 390 */ 1113, 1114, 897, 1058, 1078, 1079, 1080, 1081, 1108, 1109, /* 400 */ 1110, 1111, 1112, 1113, 1114, 50, 540, 539, 49, 1614, /* 410 */ 424, 899, 276, 279, 1055, 1075, 132, 30, 28, 1391, /* 420 */ 115, 115, 131, 9, 8, 266, 1612, 1054, 1346, 1346, /* 430 */ 1426, 1058, 1078, 1079, 1080, 1081, 1108, 1109, 1110, 1111, /* 440 */ 1112, 1113, 1114, 1052, 32, 31, 29, 27, 26, 1161, /* 450 */ 1335, 935, 486, 485, 484, 939, 483, 941, 942, 482, /* 460 */ 944, 479, 1059, 950, 476, 952, 953, 473, 470, 32, /* 470 */ 31, 29, 27, 26, 23, 65, 489, 52, 1054, 1, /* 480 */ 1273, 463, 241, 462, 32, 31, 29, 27, 26, 101, /* 490 */ 460, 381, 380, 500, 1052, 1472, 1336, 1139, 1340, 116, /* 500 */ 463, 463, 544, 463, 222, 1082, 1344, 1096, 334, 347, /* 510 */ 208, 420, 1341, 1059, 1053, 1126, 220, 513, 511, 441, /* 520 */ 32, 31, 29, 27, 26, 1344, 1344, 1187, 1344, 142, /* 530 */ 9, 8, 520, 519, 518, 517, 281, 12, 516, 515, /* 540 */ 514, 102, 509, 508, 507, 506, 505, 504, 503, 502, /* 550 */ 108, 1055, 1247, 544, 141, 140, 1246, 1331, 241, 417, /* 560 */ 1185, 1186, 1188, 1189, 1127, 1053, 425, 421, 1058, 1078, /* 570 */ 1079, 1080, 1081, 1108, 1109, 1110, 1111, 1112, 1113, 1114, /* 580 */ 430, 1245, 1131, 32, 31, 29, 27, 26, 1244, 1391, /* 590 */ 1083, 1126, 67, 1572, 1158, 278, 1217, 1472, 1567, 1567, /* 600 */ 1389, 1472, 1055, 1219, 1220, 100, 1243, 24, 264, 1121, /* 610 */ 1122, 1123, 1124, 1125, 1129, 1130, 1564, 1563, 1242, 1058, /* 620 */ 48, 47, 309, 189, 136, 1241, 1472, 1237, 1567, 303, /* 630 */ 106, 1503, 59, 1472, 409, 463, 463, 246, 98, 295, /* 640 */ 1127, 291, 287, 133, 461, 280, 1562, 432, 127, 1560, /* 650 */ 1561, 1472, 1565, 1337, 442, 1521, 1128, 1240, 1131, 845, /* 660 */ 1344, 1344, 446, 1472, 1216, 1239, 1238, 132, 445, 115, /* 670 */ 1472, 1235, 449, 1503, 1132, 367, 1472, 1347, 1234, 1233, /* 680 */ 1327, 434, 430, 24, 264, 1121, 1122, 1123, 1124, 1125, /* 690 */ 1129, 1130, 68, 1504, 1505, 1510, 1553, 1521, 1258, 22, /* 700 */ 240, 1549, 1472, 1232, 446, 547, 1391, 100, 175, 114, /* 710 */ 1472, 1472, 1614, 1231, 449, 1503, 1472, 1390, 1472, 213, /* 720 */ 386, 1230, 95, 1472, 1472, 131, 434, 1229, 536, 1612, /* 730 */ 532, 528, 524, 212, 69, 1504, 1505, 1510, 1553, 1521, /* 740 */ 98, 1170, 259, 1549, 1626, 1228, 446, 1076, 1472, 297, /* 750 */ 187, 1560, 429, 1587, 428, 1276, 449, 1614, 1472, 66, /* 760 */ 1472, 1227, 206, 1503, 299, 157, 1472, 1461, 155, 169, /* 770 */ 131, 44, 1472, 1062, 1612, 1184, 69, 1504, 1505, 1510, /* 780 */ 1553, 1118, 871, 1061, 259, 1549, 1626, 1521, 159, 1256, /* 790 */ 1472, 158, 459, 161, 446, 1610, 160, 163, 1492, 447, /* 800 */ 162, 872, 64, 289, 449, 1503, 1472, 383, 1472, 377, /* 810 */ 1490, 389, 61, 382, 488, 405, 97, 1303, 378, 376, /* 820 */ 412, 379, 418, 171, 69, 1504, 1505, 1510, 1553, 1521, /* 830 */ 191, 178, 259, 1549, 1626, 180, 446, 33, 1038, 343, /* 840 */ 168, 1133, 404, 1571, 1065, 1385, 449, 273, 272, 33, /* 850 */ 1472, 184, 1503, 1091, 1064, 434, 366, 1067, 33, 197, /* 860 */ 1583, 94, 1021, 199, 431, 455, 228, 1504, 1505, 1510, /* 870 */ 104, 1522, 193, 1060, 205, 106, 1521, 2, 44, 928, /* 880 */ 1074, 468, 923, 446, 284, 956, 1614, 288, 245, 247, /* 890 */ 897, 104, 1059, 449, 1503, 960, 1030, 1472, 105, 131, /* 900 */ 1503, 214, 966, 1612, 106, 1503, 138, 104, 965, 321, /* 910 */ 1424, 107, 328, 70, 1504, 1505, 1510, 1553, 1521, 335, /* 920 */ 337, 444, 1549, 336, 1521, 446, 341, 1087, 1086, 1521, /* 930 */ 342, 446, 464, 344, 144, 449, 446, 345, 1085, 1472, /* 940 */ 147, 449, 51, 346, 1063, 1472, 449, 349, 1084, 370, /* 950 */ 1472, 1503, 150, 265, 368, 119, 1504, 1505, 1510, 1225, /* 960 */ 255, 70, 1504, 1505, 1510, 1553, 229, 1504, 1505, 1510, /* 970 */ 1550, 373, 1334, 154, 1330, 1521, 1503, 156, 109, 110, /* 980 */ 84, 1068, 446, 83, 82, 81, 80, 79, 78, 77, /* 990 */ 76, 75, 449, 435, 1627, 1332, 1472, 1328, 1071, 414, /* 1000 */ 1521, 111, 74, 430, 112, 398, 400, 446, 408, 170, /* 1010 */ 411, 173, 233, 1504, 1505, 1510, 401, 449, 1503, 410, /* 1020 */ 399, 1472, 1083, 1584, 419, 453, 1594, 430, 100, 176, /* 1030 */ 1059, 416, 258, 1593, 1574, 179, 422, 232, 1504, 1505, /* 1040 */ 1510, 5, 1521, 427, 415, 4, 1503, 183, 1158, 446, /* 1050 */ 1082, 124, 100, 185, 99, 34, 186, 260, 1433, 449, /* 1060 */ 17, 98, 440, 1472, 1568, 451, 443, 1611, 456, 426, /* 1070 */ 1521, 128, 1560, 1561, 452, 1565, 1535, 446, 192, 119, /* 1080 */ 1504, 1505, 1510, 1629, 1432, 98, 268, 449, 201, 1503, /* 1090 */ 203, 1472, 457, 458, 263, 129, 1560, 1561, 215, 1565, /* 1100 */ 58, 1345, 60, 466, 495, 1317, 217, 233, 1504, 1505, /* 1110 */ 1510, 211, 543, 1521, 40, 223, 1503, 224, 1628, 219, /* 1120 */ 446, 221, 1466, 1465, 283, 1462, 285, 286, 1048, 1049, /* 1130 */ 449, 1503, 134, 290, 1472, 1460, 292, 267, 293, 294, /* 1140 */ 1521, 1459, 1503, 296, 1458, 298, 1449, 446, 135, 301, /* 1150 */ 233, 1504, 1505, 1510, 302, 1521, 1033, 449, 1032, 1443, /* 1160 */ 1442, 1472, 446, 307, 308, 1441, 1521, 1440, 1004, 1417, /* 1170 */ 1416, 1415, 449, 446, 1414, 1413, 1472, 225, 1504, 1505, /* 1180 */ 1510, 1412, 1411, 449, 1410, 1409, 1408, 1472, 1503, 1407, /* 1190 */ 1406, 1405, 231, 1504, 1505, 1510, 1503, 1404, 1403, 1402, /* 1200 */ 103, 1503, 1006, 234, 1504, 1505, 1510, 1401, 1400, 1399, /* 1210 */ 1398, 1397, 1521, 1396, 1395, 1394, 1393, 1392, 1275, 446, /* 1220 */ 1521, 1457, 1451, 1439, 1430, 1521, 146, 446, 1323, 449, /* 1230 */ 1503, 1274, 446, 1472, 1272, 352, 351, 449, 864, 350, /* 1240 */ 1270, 1472, 449, 354, 1268, 1266, 1472, 356, 355, 226, /* 1250 */ 1504, 1505, 1510, 1255, 1521, 1503, 359, 235, 1504, 1505, /* 1260 */ 1510, 446, 227, 1504, 1505, 1510, 363, 358, 360, 364, /* 1270 */ 362, 449, 1254, 1251, 1325, 1472, 73, 153, 971, 1521, /* 1280 */ 973, 1324, 1503, 1264, 896, 895, 446, 894, 893, 890, /* 1290 */ 1503, 236, 1504, 1505, 1510, 889, 449, 252, 512, 1259, /* 1300 */ 1472, 253, 387, 1257, 510, 390, 1521, 254, 1250, 392, /* 1310 */ 1249, 394, 71, 446, 1521, 1456, 1518, 1504, 1505, 1510, /* 1320 */ 1040, 446, 1450, 449, 402, 1438, 1503, 1472, 167, 113, /* 1330 */ 1437, 449, 43, 403, 1429, 1472, 54, 172, 122, 174, /* 1340 */ 3, 33, 14, 1517, 1504, 1505, 1510, 38, 182, 20, /* 1350 */ 1521, 243, 1504, 1505, 1510, 1503, 15, 446, 10, 177, /* 1360 */ 1503, 1183, 120, 35, 181, 19, 1490, 449, 1503, 56, /* 1370 */ 1176, 1472, 55, 37, 1205, 1155, 1154, 36, 16, 1521, /* 1380 */ 1210, 1204, 188, 130, 1521, 1321, 446, 1516, 1504, 1505, /* 1390 */ 1510, 446, 1521, 1319, 261, 1209, 449, 1208, 262, 446, /* 1400 */ 1472, 449, 8, 195, 1119, 1472, 1094, 1092, 196, 449, /* 1410 */ 1181, 13, 18, 1472, 1503, 198, 244, 1504, 1505, 1510, /* 1420 */ 200, 242, 1504, 1505, 1510, 45, 1428, 202, 57, 239, /* 1430 */ 1504, 1505, 1510, 61, 1489, 1069, 207, 39, 1521, 957, /* 1440 */ 454, 467, 204, 465, 275, 446, 209, 469, 471, 954, /* 1450 */ 494, 472, 474, 951, 209, 449, 475, 477, 494, 1472, /* 1460 */ 480, 945, 478, 934, 943, 481, 949, 948, 947, 946, /* 1470 */ 487, 62, 496, 968, 964, 230, 1504, 1505, 1510, 46, /* 1480 */ 496, 967, 63, 962, 862, 903, 210, 497, 499, 885, /* 1490 */ 884, 493, 492, 491, 883, 490, 882, 881, 880, 493, /* 1500 */ 492, 491, 879, 490, 878, 900, 898, 875, 874, 873, /* 1510 */ 870, 869, 868, 867, 1271, 521, 522, 1269, 1267, 523, /* 1520 */ 526, 525, 527, 529, 530, 1265, 534, 533, 1253, 531, /* 1530 */ 535, 537, 538, 1252, 1248, 541, 542, 1223, 1056, 1223, /* 1540 */ 546, 218, 545, }; static const YYCODETYPE yy_lookahead[] = { /* 0 */ 211, 209, 213, 236, 253, 218, 257, 256, 229, 242, /* 10 */ 259, 232, 12, 13, 247, 2, 262, 212, 269, 270, /* 20 */ 20, 224, 22, 226, 20, 12, 13, 14, 15, 16, /* 30 */ 12, 13, 14, 15, 16, 248, 20, 3, 38, 240, /* 40 */ 237, 236, 12, 13, 14, 15, 16, 293, 243, 237, /* 50 */ 50, 12, 13, 14, 262, 228, 257, 57, 253, 20, /* 60 */ 306, 22, 257, 236, 310, 12, 13, 14, 269, 270, /* 70 */ 212, 244, 20, 20, 74, 22, 245, 38, 273, 274, /* 80 */ 275, 276, 277, 252, 253, 293, 281, 282, 283, 50, /* 90 */ 0, 38, 0, 75, 236, 221, 57, 97, 306, 225, /* 100 */ 295, 243, 310, 278, 279, 75, 301, 302, 240, 109, /* 110 */ 57, 253, 22, 74, 49, 257, 24, 25, 26, 27, /* 120 */ 28, 29, 30, 31, 32, 257, 74, 74, 75, 21, /* 130 */ 220, 273, 274, 275, 276, 277, 97, 269, 270, 281, /* 140 */ 282, 283, 34, 233, 33, 243, 146, 36, 109, 35, /* 150 */ 97, 241, 250, 42, 20, 44, 45, 46, 47, 145, /* 160 */ 302, 147, 109, 163, 164, 165, 166, 167, 168, 169, /* 170 */ 170, 171, 172, 173, 174, 61, 14, 15, 16, 65, /* 180 */ 164, 165, 166, 167, 73, 146, 186, 76, 43, 218, /* 190 */ 186, 77, 186, 79, 80, 71, 82, 262, 227, 146, /* 200 */ 186, 87, 163, 164, 165, 166, 167, 168, 169, 170, /* 210 */ 171, 172, 173, 174, 243, 0, 163, 164, 165, 166, /* 220 */ 167, 168, 169, 170, 171, 172, 173, 174, 293, 12, /* 230 */ 13, 12, 13, 14, 15, 16, 202, 20, 186, 22, /* 240 */ 293, 306, 12, 13, 133, 310, 135, 218, 137, 18, /* 250 */ 20, 20, 22, 306, 212, 38, 227, 310, 27, 20, /* 260 */ 4, 30, 236, 234, 49, 154, 4, 50, 38, 243, /* 270 */ 39, 236, 243, 253, 57, 19, 49, 242, 236, 259, /* 280 */ 12, 13, 247, 235, 218, 243, 0, 57, 20, 33, /* 290 */ 22, 74, 36, 227, 246, 253, 52, 41, 54, 257, /* 300 */ 234, 275, 58, 47, 74, 61, 38, 63, 64, 243, /* 310 */ 66, 218, 218, 218, 97, 273, 274, 275, 276, 277, /* 320 */ 227, 227, 227, 281, 282, 57, 109, 97, 204, 73, /* 330 */ 185, 20, 76, 22, 218, 49, 243, 243, 243, 109, /* 340 */ 61, 71, 74, 112, 65, 75, 115, 116, 117, 118, /* 350 */ 119, 40, 121, 122, 123, 124, 125, 126, 127, 128, /* 360 */ 129, 130, 131, 146, 21, 97, 87, 24, 25, 26, /* 370 */ 27, 28, 29, 30, 31, 32, 146, 109, 262, 47, /* 380 */ 163, 164, 165, 166, 167, 168, 169, 170, 171, 172, /* 390 */ 173, 174, 38, 163, 164, 165, 166, 167, 168, 169, /* 400 */ 170, 171, 172, 173, 174, 73, 215, 216, 76, 293, /* 410 */ 20, 57, 228, 228, 146, 20, 186, 12, 13, 236, /* 420 */ 236, 236, 306, 1, 2, 20, 310, 22, 244, 244, /* 430 */ 247, 163, 164, 165, 166, 167, 168, 169, 170, 171, /* 440 */ 172, 173, 174, 38, 12, 13, 14, 15, 16, 187, /* 450 */ 212, 88, 89, 90, 91, 92, 93, 94, 95, 96, /* 460 */ 97, 98, 57, 100, 101, 102, 103, 104, 105, 12, /* 470 */ 13, 14, 15, 16, 2, 217, 85, 220, 22, 74, /* 480 */ 0, 218, 50, 20, 12, 13, 14, 15, 16, 231, /* 490 */ 227, 222, 223, 57, 38, 257, 238, 75, 241, 18, /* 500 */ 218, 218, 97, 218, 23, 20, 243, 75, 67, 227, /* 510 */ 227, 136, 227, 57, 109, 83, 35, 222, 223, 71, /* 520 */ 12, 13, 14, 15, 16, 243, 243, 163, 243, 48, /* 530 */ 1, 2, 52, 53, 54, 55, 56, 74, 58, 59, /* 540 */ 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, /* 550 */ 70, 146, 212, 97, 113, 114, 212, 237, 50, 195, /* 560 */ 196, 197, 198, 199, 132, 109, 191, 192, 163, 164, /* 570 */ 165, 166, 167, 168, 169, 170, 171, 172, 173, 174, /* 580 */ 218, 212, 150, 12, 13, 14, 15, 16, 212, 236, /* 590 */ 20, 83, 111, 184, 185, 242, 139, 257, 271, 271, /* 600 */ 247, 257, 146, 164, 165, 243, 212, 175, 176, 177, /* 610 */ 178, 179, 180, 181, 182, 183, 289, 289, 212, 163, /* 620 */ 139, 140, 141, 138, 143, 212, 257, 213, 271, 148, /* 630 */ 71, 212, 217, 257, 75, 218, 218, 156, 276, 158, /* 640 */ 132, 160, 161, 162, 227, 227, 289, 285, 286, 287, /* 650 */ 288, 257, 290, 238, 206, 236, 132, 212, 150, 22, /* 660 */ 243, 243, 243, 257, 207, 212, 212, 186, 50, 236, /* 670 */ 257, 212, 253, 212, 150, 38, 257, 244, 212, 212, /* 680 */ 237, 262, 218, 175, 176, 177, 178, 179, 180, 181, /* 690 */ 182, 183, 273, 274, 275, 276, 277, 236, 0, 175, /* 700 */ 281, 282, 257, 212, 243, 19, 236, 243, 138, 138, /* 710 */ 257, 257, 293, 212, 253, 212, 257, 247, 257, 33, /* 720 */ 22, 212, 36, 257, 257, 306, 262, 212, 42, 310, /* 730 */ 44, 45, 46, 47, 273, 274, 275, 276, 277, 236, /* 740 */ 276, 14, 281, 282, 283, 212, 243, 20, 257, 142, /* 750 */ 286, 287, 288, 292, 290, 0, 253, 293, 257, 73, /* 760 */ 257, 212, 76, 212, 157, 78, 257, 0, 81, 237, /* 770 */ 306, 71, 257, 38, 310, 75, 273, 274, 275, 276, /* 780 */ 277, 163, 38, 38, 281, 282, 283, 236, 78, 0, /* 790 */ 257, 81, 106, 78, 243, 292, 81, 78, 74, 237, /* 800 */ 81, 57, 74, 36, 253, 212, 257, 52, 257, 54, /* 810 */ 86, 22, 84, 58, 237, 265, 61, 225, 63, 64, /* 820 */ 134, 66, 304, 137, 273, 274, 275, 276, 277, 236, /* 830 */ 313, 71, 281, 282, 283, 75, 243, 71, 152, 253, /* 840 */ 154, 75, 253, 292, 109, 246, 253, 12, 13, 71, /* 850 */ 257, 298, 212, 75, 109, 262, 215, 22, 71, 71, /* 860 */ 272, 71, 75, 75, 291, 75, 273, 274, 275, 276, /* 870 */ 71, 236, 307, 38, 75, 71, 236, 294, 71, 75, /* 880 */ 20, 71, 75, 243, 218, 75, 293, 36, 268, 222, /* 890 */ 38, 71, 57, 253, 212, 75, 144, 257, 71, 306, /* 900 */ 212, 263, 75, 310, 71, 212, 120, 71, 75, 218, /* 910 */ 218, 75, 251, 273, 274, 275, 276, 277, 236, 249, /* 920 */ 249, 281, 282, 132, 236, 243, 218, 20, 20, 236, /* 930 */ 267, 243, 97, 261, 220, 253, 243, 243, 20, 257, /* 940 */ 220, 253, 220, 254, 109, 257, 253, 218, 20, 236, /* 950 */ 257, 212, 220, 260, 214, 273, 274, 275, 276, 0, /* 960 */ 214, 273, 274, 275, 276, 277, 273, 274, 275, 276, /* 970 */ 282, 222, 236, 236, 236, 236, 212, 236, 236, 236, /* 980 */ 21, 146, 243, 24, 25, 26, 27, 28, 29, 30, /* 990 */ 31, 32, 253, 311, 312, 236, 257, 236, 163, 260, /* 1000 */ 236, 236, 218, 218, 236, 243, 153, 243, 261, 217, /* 1010 */ 254, 217, 273, 274, 275, 276, 266, 253, 212, 243, /* 1020 */ 267, 257, 20, 272, 194, 193, 303, 218, 243, 258, /* 1030 */ 57, 257, 257, 303, 300, 258, 257, 273, 274, 275, /* 1040 */ 276, 201, 236, 200, 189, 188, 212, 299, 185, 243, /* 1050 */ 20, 297, 243, 296, 243, 120, 284, 208, 258, 253, /* 1060 */ 74, 276, 203, 257, 271, 257, 205, 309, 135, 305, /* 1070 */ 236, 286, 287, 288, 257, 290, 280, 243, 308, 273, /* 1080 */ 274, 275, 276, 314, 258, 276, 257, 253, 243, 212, /* 1090 */ 217, 257, 255, 254, 260, 286, 287, 288, 232, 290, /* 1100 */ 217, 243, 74, 239, 222, 226, 218, 273, 274, 275, /* 1110 */ 276, 217, 214, 236, 264, 230, 212, 230, 312, 219, /* 1120 */ 243, 210, 0, 0, 64, 0, 38, 159, 38, 38, /* 1130 */ 253, 212, 38, 159, 257, 0, 38, 260, 38, 159, /* 1140 */ 236, 0, 212, 38, 0, 38, 0, 243, 74, 150, /* 1150 */ 273, 274, 275, 276, 149, 236, 109, 253, 146, 0, /* 1160 */ 0, 257, 243, 53, 142, 0, 236, 0, 86, 0, /* 1170 */ 0, 0, 253, 243, 0, 0, 257, 273, 274, 275, /* 1180 */ 276, 0, 0, 253, 0, 0, 0, 257, 212, 0, /* 1190 */ 0, 0, 273, 274, 275, 276, 212, 0, 0, 0, /* 1200 */ 120, 212, 22, 273, 274, 275, 276, 0, 0, 0, /* 1210 */ 0, 0, 236, 0, 0, 0, 0, 0, 0, 243, /* 1220 */ 236, 0, 0, 0, 0, 236, 43, 243, 0, 253, /* 1230 */ 212, 0, 243, 257, 0, 43, 36, 253, 51, 38, /* 1240 */ 0, 257, 253, 38, 0, 0, 257, 43, 36, 273, /* 1250 */ 274, 275, 276, 0, 236, 212, 36, 273, 274, 275, /* 1260 */ 276, 243, 273, 274, 275, 276, 36, 38, 43, 43, /* 1270 */ 38, 253, 0, 0, 0, 257, 83, 81, 22, 236, /* 1280 */ 38, 0, 212, 0, 38, 38, 243, 38, 38, 38, /* 1290 */ 212, 273, 274, 275, 276, 38, 253, 22, 71, 0, /* 1300 */ 257, 22, 39, 0, 71, 38, 236, 22, 0, 22, /* 1310 */ 0, 22, 20, 243, 236, 0, 273, 274, 275, 276, /* 1320 */ 38, 243, 0, 253, 22, 0, 212, 257, 155, 151, /* 1330 */ 0, 253, 138, 138, 0, 257, 74, 43, 135, 133, /* 1340 */ 71, 71, 190, 273, 274, 275, 276, 71, 71, 71, /* 1350 */ 236, 273, 274, 275, 276, 212, 190, 243, 190, 75, /* 1360 */ 212, 75, 74, 184, 74, 74, 86, 253, 212, 4, /* 1370 */ 75, 257, 74, 138, 38, 75, 75, 71, 71, 236, /* 1380 */ 75, 38, 86, 86, 236, 0, 243, 273, 274, 275, /* 1390 */ 276, 243, 236, 0, 38, 38, 253, 38, 38, 243, /* 1400 */ 257, 253, 2, 86, 163, 257, 75, 75, 75, 253, /* 1410 */ 75, 74, 74, 257, 212, 74, 273, 274, 275, 276, /* 1420 */ 74, 273, 274, 275, 276, 74, 0, 43, 74, 273, /* 1430 */ 274, 275, 276, 84, 86, 22, 86, 74, 236, 75, /* 1440 */ 136, 38, 133, 85, 38, 243, 61, 74, 38, 75, /* 1450 */ 65, 74, 38, 75, 61, 253, 74, 38, 65, 257, /* 1460 */ 38, 75, 74, 22, 75, 74, 99, 99, 99, 99, /* 1470 */ 87, 74, 87, 38, 38, 273, 274, 275, 276, 74, /* 1480 */ 87, 109, 74, 22, 51, 57, 71, 50, 72, 38, /* 1490 */ 38, 106, 107, 108, 38, 110, 38, 38, 38, 106, /* 1500 */ 107, 108, 38, 110, 22, 57, 38, 38, 38, 38, /* 1510 */ 38, 38, 38, 38, 0, 38, 36, 0, 0, 43, /* 1520 */ 36, 38, 43, 38, 36, 0, 36, 38, 0, 43, /* 1530 */ 43, 38, 37, 0, 0, 22, 21, 315, 22, 315, /* 1540 */ 20, 22, 21, 315, 315, 315, 315, 315, 315, 315, /* 1550 */ 315, 315, 315, 315, 315, 315, 315, 315, 315, 315, /* 1560 */ 315, 315, 315, 315, 315, 315, 315, 315, 315, 315, /* 1570 */ 315, 315, 315, 315, 315, 315, 315, 315, 315, 315, /* 1580 */ 315, 315, 315, 315, 315, 315, 315, 315, 315, 315, /* 1590 */ 315, 315, 315, 315, 315, 315, 315, 315, 315, 315, /* 1600 */ 315, 315, 315, 315, 315, 315, 315, 315, 315, 315, /* 1610 */ 315, 315, 315, 315, 315, 315, 315, 315, 315, 315, /* 1620 */ 315, 315, 315, 315, 315, 315, 315, 315, 315, 315, /* 1630 */ 315, 315, 315, 315, 315, 315, 315, 315, 315, 315, /* 1640 */ 315, 315, 315, 315, 315, 315, 315, 315, 315, 315, /* 1650 */ 315, 315, 315, 315, 315, 315, 315, 315, 315, 315, /* 1660 */ 315, 315, 315, 315, 315, 315, 315, 315, 315, 315, /* 1670 */ 315, 315, 315, 315, 315, 315, 315, 315, 315, 315, /* 1680 */ 315, 315, 315, 315, 315, 315, 315, 315, 315, 315, /* 1690 */ 315, 315, 315, 315, 315, 315, 315, 315, 315, 315, /* 1700 */ 315, 315, 315, 315, 315, 315, 315, 315, 315, 315, /* 1710 */ 315, 315, 315, 315, 315, 315, 315, 315, 315, 315, /* 1720 */ 315, 315, 315, 315, 315, 315, 315, 315, 315, 315, /* 1730 */ 315, 315, 315, 315, 315, 315, 315, 315, 315, 315, /* 1740 */ 315, 315, 315, 315, 315, 315, 315, 315, 315, 315, /* 1750 */ 315, 315, }; #define YY_SHIFT_COUNT (547) #define YY_SHIFT_MIN (0) #define YY_SHIFT_MAX (1534) static const unsigned short int yy_shift_ofst[] = { /* 0 */ 481, 0, 39, 217, 217, 217, 217, 230, 217, 217, /* 10 */ 268, 405, 52, 53, 268, 268, 268, 268, 268, 268, /* 20 */ 268, 268, 268, 268, 268, 268, 268, 268, 268, 268, /* 30 */ 268, 268, 268, 268, 463, 463, 463, 4, 835, 835, /* 40 */ 14, 134, 134, 6, 835, 16, 16, 134, 134, 134, /* 50 */ 134, 134, 134, 65, 239, 390, 6, 239, 134, 134, /* 60 */ 239, 134, 239, 239, 239, 134, 227, 231, 432, 508, /* 70 */ 508, 343, 114, 456, 244, 456, 456, 456, 456, 456, /* 80 */ 456, 456, 456, 456, 456, 456, 456, 456, 456, 456, /* 90 */ 456, 456, 456, 456, 16, 311, 215, 354, 485, 485, /* 100 */ 485, 286, 354, 395, 239, 239, 239, 391, 436, 363, /* 110 */ 363, 363, 363, 363, 363, 363, 686, 959, 755, 457, /* 120 */ 364, 16, 16, 279, 375, 637, 570, 409, 145, 409, /* 130 */ 727, 34, 262, 860, 851, 852, 752, 860, 860, 786, /* 140 */ 791, 791, 860, 907, 908, 65, 395, 918, 65, 65, /* 150 */ 860, 65, 928, 239, 239, 239, 239, 239, 239, 239, /* 160 */ 239, 239, 239, 239, 852, 860, 928, 395, 907, 853, /* 170 */ 908, 227, 395, 918, 227, 1002, 830, 832, 973, 830, /* 180 */ 832, 973, 973, 840, 843, 855, 857, 863, 395, 1030, /* 190 */ 935, 849, 861, 859, 986, 239, 832, 973, 973, 832, /* 200 */ 973, 933, 395, 918, 227, 391, 227, 395, 1028, 852, /* 210 */ 436, 860, 227, 928, 1543, 1543, 1543, 1543, 1543, 480, /* 220 */ 111, 92, 256, 1385, 1393, 18, 13, 472, 30, 571, /* 230 */ 219, 219, 219, 219, 219, 219, 219, 332, 441, 162, /* 240 */ 422, 524, 162, 162, 162, 767, 607, 270, 687, 710, /* 250 */ 715, 719, 90, 698, 789, 108, 559, 700, 760, 529, /* 260 */ 439, 124, 448, 766, 618, 778, 724, 787, 788, 790, /* 270 */ 799, 804, 735, 745, 807, 810, 820, 827, 833, 836, /* 280 */ 728, 744, 1122, 1123, 1060, 1125, 1088, 968, 1090, 1091, /* 290 */ 1094, 974, 1135, 1098, 1100, 980, 1141, 1105, 1144, 1107, /* 300 */ 1146, 1074, 999, 1005, 1047, 1012, 1159, 1160, 1110, 1022, /* 310 */ 1165, 1167, 1082, 1169, 1170, 1171, 1174, 1175, 1181, 1182, /* 320 */ 1184, 1185, 1186, 1189, 1190, 1191, 1197, 1198, 1199, 1080, /* 330 */ 1207, 1208, 1209, 1210, 1211, 1213, 1180, 1214, 1215, 1216, /* 340 */ 1217, 1218, 1221, 1222, 1223, 1224, 1183, 1228, 1187, 1231, /* 350 */ 1234, 1201, 1200, 1192, 1240, 1205, 1212, 1204, 1244, 1229, /* 360 */ 1220, 1225, 1245, 1232, 1230, 1226, 1253, 1272, 1273, 1274, /* 370 */ 1193, 1196, 1242, 1227, 1256, 1281, 1246, 1247, 1249, 1250, /* 380 */ 1233, 1227, 1251, 1257, 1283, 1275, 1299, 1279, 1263, 1303, /* 390 */ 1285, 1267, 1308, 1287, 1310, 1289, 1292, 1315, 1194, 1173, /* 400 */ 1282, 1322, 1178, 1302, 1195, 1203, 1325, 1330, 1235, 1334, /* 410 */ 1262, 1294, 1206, 1269, 1270, 1152, 1284, 1276, 1286, 1288, /* 420 */ 1290, 1291, 1295, 1277, 1280, 1298, 1278, 1166, 1300, 1301, /* 430 */ 1296, 1179, 1306, 1297, 1305, 1307, 1168, 1365, 1336, 1343, /* 440 */ 1356, 1357, 1359, 1360, 1400, 1241, 1317, 1331, 1332, 1337, /* 450 */ 1338, 1333, 1335, 1341, 1346, 1304, 1351, 1426, 1384, 1309, /* 460 */ 1354, 1349, 1348, 1350, 1413, 1363, 1358, 1364, 1403, 1406, /* 470 */ 1373, 1374, 1410, 1377, 1378, 1414, 1382, 1386, 1419, 1388, /* 480 */ 1389, 1422, 1391, 1367, 1368, 1369, 1370, 1441, 1383, 1397, /* 490 */ 1435, 1372, 1405, 1408, 1436, 1227, 1461, 1433, 1437, 1428, /* 500 */ 1416, 1415, 1451, 1452, 1456, 1458, 1459, 1460, 1464, 1482, /* 510 */ 1448, 1233, 1468, 1227, 1469, 1470, 1471, 1472, 1473, 1474, /* 520 */ 1475, 1514, 1477, 1480, 1476, 1517, 1483, 1484, 1479, 1518, /* 530 */ 1485, 1488, 1486, 1525, 1489, 1490, 1487, 1528, 1493, 1495, /* 540 */ 1533, 1534, 1513, 1515, 1516, 1519, 1521, 1520, }; #define YY_REDUCE_COUNT (218) #define YY_REDUCE_MIN (-251) #define YY_REDUCE_MAX (1202) static const short yy_reduce_ofst[] = { /* 0 */ -208, 419, -195, -142, 461, 503, 551, 593, 42, 640, /* 10 */ 682, 688, 464, 693, 739, 764, 806, 834, 877, 904, /* 20 */ 919, 930, 976, 984, 989, 1018, 1043, 1070, 1078, 1114, /* 30 */ 1143, 1148, 1156, 1202, 362, 785, 809, 116, -201, -132, /* 40 */ -246, 29, 66, -65, -251, -249, -169, -29, 93, 94, /* 50 */ 95, 282, 285, -90, -233, 26, -53, -173, 263, 417, /* 60 */ 35, 283, 184, 353, 185, 418, 258, -213, -175, -175, /* 70 */ -175, -211, 48, 238, -126, 340, 344, 369, 376, 394, /* 80 */ 406, 413, 445, 453, 454, 459, 466, 467, 491, 501, /* 90 */ 509, 515, 533, 549, 20, 191, 257, 269, 327, 328, /* 100 */ 357, 415, 295, -98, 433, 183, 470, -221, -203, -197, /* 110 */ -188, 320, 443, 532, 562, 577, 550, 414, 592, 517, /* 120 */ 518, 586, 589, 599, 553, 641, 588, 573, 573, 573, /* 130 */ 635, 565, 583, 666, 620, 667, 638, 691, 692, 661, /* 140 */ 670, 671, 708, 663, 672, 714, 694, 689, 720, 722, /* 150 */ 729, 732, 740, 713, 736, 737, 738, 741, 742, 743, /* 160 */ 759, 761, 765, 768, 749, 784, 746, 762, 753, 750, /* 170 */ 747, 792, 776, 756, 794, 751, 723, 771, 774, 730, /* 180 */ 777, 775, 779, 734, 748, 754, 757, 573, 811, 793, /* 190 */ 772, 769, 758, 770, 796, 635, 800, 808, 817, 826, /* 200 */ 829, 837, 845, 839, 873, 866, 883, 858, 864, 882, /* 210 */ 879, 888, 894, 898, 850, 885, 887, 900, 911, }; static const YYACTIONTYPE yy_default[] = { /* 0 */ 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, /* 10 */ 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, /* 20 */ 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, /* 30 */ 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, /* 40 */ 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, /* 50 */ 1221, 1221, 1221, 1280, 1221, 1221, 1221, 1221, 1221, 1221, /* 60 */ 1221, 1221, 1221, 1221, 1221, 1221, 1278, 1418, 1221, 1555, /* 70 */ 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, /* 80 */ 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, /* 90 */ 1221, 1221, 1221, 1221, 1221, 1221, 1280, 1221, 1566, 1566, /* 100 */ 1566, 1278, 1221, 1221, 1221, 1221, 1221, 1373, 1221, 1221, /* 110 */ 1221, 1221, 1221, 1221, 1221, 1221, 1452, 1221, 1221, 1630, /* 120 */ 1221, 1221, 1221, 1326, 1590, 1221, 1582, 1558, 1572, 1559, /* 130 */ 1221, 1615, 1575, 1221, 1221, 1221, 1444, 1221, 1221, 1423, /* 140 */ 1420, 1420, 1221, 1221, 1221, 1280, 1221, 1221, 1280, 1280, /* 150 */ 1221, 1280, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, /* 160 */ 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1454, /* 170 */ 1221, 1278, 1221, 1221, 1278, 1221, 1597, 1595, 1221, 1597, /* 180 */ 1595, 1221, 1221, 1609, 1605, 1588, 1586, 1572, 1221, 1221, /* 190 */ 1221, 1633, 1621, 1617, 1221, 1221, 1595, 1221, 1221, 1595, /* 200 */ 1221, 1431, 1221, 1221, 1278, 1221, 1278, 1221, 1342, 1221, /* 210 */ 1221, 1221, 1278, 1221, 1446, 1376, 1376, 1281, 1226, 1221, /* 220 */ 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1519, /* 230 */ 1520, 1608, 1607, 1519, 1532, 1531, 1530, 1221, 1221, 1514, /* 240 */ 1221, 1221, 1515, 1513, 1512, 1221, 1221, 1221, 1221, 1221, /* 250 */ 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1556, /* 260 */ 1221, 1618, 1622, 1221, 1221, 1221, 1491, 1221, 1221, 1221, /* 270 */ 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, /* 280 */ 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, /* 290 */ 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, /* 300 */ 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, /* 310 */ 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, /* 320 */ 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, /* 330 */ 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, /* 340 */ 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, /* 350 */ 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, /* 360 */ 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, /* 370 */ 1221, 1221, 1221, 1387, 1221, 1221, 1221, 1221, 1221, 1221, /* 380 */ 1307, 1306, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, /* 390 */ 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, /* 400 */ 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, /* 410 */ 1221, 1221, 1221, 1579, 1589, 1221, 1221, 1221, 1221, 1221, /* 420 */ 1221, 1221, 1221, 1221, 1491, 1221, 1606, 1221, 1565, 1561, /* 430 */ 1221, 1221, 1557, 1221, 1221, 1616, 1221, 1221, 1221, 1221, /* 440 */ 1221, 1221, 1221, 1221, 1551, 1221, 1221, 1221, 1221, 1221, /* 450 */ 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, /* 460 */ 1221, 1221, 1490, 1221, 1221, 1221, 1221, 1221, 1221, 1221, /* 470 */ 1370, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, /* 480 */ 1221, 1221, 1221, 1355, 1353, 1352, 1351, 1221, 1348, 1221, /* 490 */ 1221, 1221, 1221, 1221, 1221, 1378, 1221, 1221, 1221, 1221, /* 500 */ 1221, 1301, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, /* 510 */ 1221, 1292, 1221, 1291, 1221, 1221, 1221, 1221, 1221, 1221, /* 520 */ 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, /* 530 */ 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, /* 540 */ 1221, 1221, 1221, 1221, 1221, 1221, 1221, 1221, }; /********** End of lemon-generated parsing tables *****************************/ /* The next table maps tokens (terminal symbols) into fallback tokens. ** If a construct like the following: ** ** %fallback ID X Y Z. ** ** appears in the grammar, then ID becomes a fallback token for X, Y, ** and Z. Whenever one of the tokens X, Y, or Z is input to the parser ** but it does not parse, the type of the token is changed to ID and ** the parse is retried before an error is thrown. ** ** This feature can be used, for example, to cause some keywords in a language ** to revert to identifiers if they keyword does not apply in the context where ** it appears. */ #ifdef YYFALLBACK static const YYCODETYPE yyFallback[] = { }; #endif /* YYFALLBACK */ /* The following structure represents a single element of the ** parser's stack. Information stored includes: ** ** + The state number for the parser at this level of the stack. ** ** + The value of the token stored at this level of the stack. ** (In other words, the "major" token.) ** ** + The semantic value stored at this level of the stack. This is ** the information used by the action routines in the grammar. ** It is sometimes called the "minor" token. ** ** After the "shift" half of a SHIFTREDUCE action, the stateno field ** actually contains the reduce action for the second half of the ** SHIFTREDUCE. */ struct yyStackEntry { YYACTIONTYPE stateno; /* The state-number, or reduce action in SHIFTREDUCE */ YYCODETYPE major; /* The major token value. This is the code ** number for the token at this stack level */ YYMINORTYPE minor; /* The user-supplied minor token value. This ** is the value of the token */ }; typedef struct yyStackEntry yyStackEntry; /* The state of the parser is completely contained in an instance of ** the following structure */ struct yyParser { yyStackEntry *yytos; /* Pointer to top element of the stack */ #ifdef YYTRACKMAXSTACKDEPTH int yyhwm; /* High-water mark of the stack */ #endif #ifndef YYNOERRORRECOVERY int yyerrcnt; /* Shifts left before out of the error */ #endif ParseARG_SDECL /* A place to hold %extra_argument */ ParseCTX_SDECL /* A place to hold %extra_context */ #if YYSTACKDEPTH<=0 int yystksz; /* Current side of the stack */ yyStackEntry *yystack; /* The parser's stack */ yyStackEntry yystk0; /* First stack entry */ #else yyStackEntry yystack[YYSTACKDEPTH]; /* The parser's stack */ yyStackEntry *yystackEnd; /* Last entry in the stack */ #endif }; typedef struct yyParser yyParser; #ifndef NDEBUG #include static FILE *yyTraceFILE = 0; static char *yyTracePrompt = 0; #endif /* NDEBUG */ #ifndef NDEBUG /* ** Turn parser tracing on by giving a stream to which to write the trace ** and a prompt to preface each trace message. Tracing is turned off ** by making either argument NULL ** ** Inputs: **
    **
  • A FILE* to which trace output should be written. ** If NULL, then tracing is turned off. **
  • A prefix string written at the beginning of every ** line of trace output. If NULL, then tracing is ** turned off. **
** ** Outputs: ** None. */ void ParseTrace(FILE *TraceFILE, char *zTracePrompt){ yyTraceFILE = TraceFILE; yyTracePrompt = zTracePrompt; if( yyTraceFILE==0 ) yyTracePrompt = 0; else if( yyTracePrompt==0 ) yyTraceFILE = 0; } #endif /* NDEBUG */ #if defined(YYCOVERAGE) || !defined(NDEBUG) /* For tracing shifts, the names of all terminals and nonterminals ** are required. The following table supplies these names */ static const char *const yyTokenName[] = { /* 0 */ "$", /* 1 */ "OR", /* 2 */ "AND", /* 3 */ "UNION", /* 4 */ "ALL", /* 5 */ "MINUS", /* 6 */ "EXCEPT", /* 7 */ "INTERSECT", /* 8 */ "NK_BITAND", /* 9 */ "NK_BITOR", /* 10 */ "NK_LSHIFT", /* 11 */ "NK_RSHIFT", /* 12 */ "NK_PLUS", /* 13 */ "NK_MINUS", /* 14 */ "NK_STAR", /* 15 */ "NK_SLASH", /* 16 */ "NK_REM", /* 17 */ "NK_CONCAT", /* 18 */ "CREATE", /* 19 */ "ACCOUNT", /* 20 */ "NK_ID", /* 21 */ "PASS", /* 22 */ "NK_STRING", /* 23 */ "ALTER", /* 24 */ "PPS", /* 25 */ "TSERIES", /* 26 */ "STORAGE", /* 27 */ "STREAMS", /* 28 */ "QTIME", /* 29 */ "DBS", /* 30 */ "USERS", /* 31 */ "CONNS", /* 32 */ "STATE", /* 33 */ "USER", /* 34 */ "PRIVILEGE", /* 35 */ "DROP", /* 36 */ "DNODE", /* 37 */ "PORT", /* 38 */ "NK_INTEGER", /* 39 */ "DNODES", /* 40 */ "NK_IPTOKEN", /* 41 */ "LOCAL", /* 42 */ "QNODE", /* 43 */ "ON", /* 44 */ "BNODE", /* 45 */ "SNODE", /* 46 */ "MNODE", /* 47 */ "DATABASE", /* 48 */ "USE", /* 49 */ "IF", /* 50 */ "NOT", /* 51 */ "EXISTS", /* 52 */ "BLOCKS", /* 53 */ "CACHE", /* 54 */ "CACHELAST", /* 55 */ "COMP", /* 56 */ "DAYS", /* 57 */ "NK_VARIABLE", /* 58 */ "FSYNC", /* 59 */ "MAXROWS", /* 60 */ "MINROWS", /* 61 */ "KEEP", /* 62 */ "PRECISION", /* 63 */ "QUORUM", /* 64 */ "REPLICA", /* 65 */ "TTL", /* 66 */ "WAL", /* 67 */ "VGROUPS", /* 68 */ "SINGLE_STABLE", /* 69 */ "STREAM_MODE", /* 70 */ "RETENTIONS", /* 71 */ "NK_COMMA", /* 72 */ "NK_COLON", /* 73 */ "TABLE", /* 74 */ "NK_LP", /* 75 */ "NK_RP", /* 76 */ "STABLE", /* 77 */ "ADD", /* 78 */ "COLUMN", /* 79 */ "MODIFY", /* 80 */ "RENAME", /* 81 */ "TAG", /* 82 */ "SET", /* 83 */ "NK_EQ", /* 84 */ "USING", /* 85 */ "TAGS", /* 86 */ "NK_DOT", /* 87 */ "COMMENT", /* 88 */ "BOOL", /* 89 */ "TINYINT", /* 90 */ "SMALLINT", /* 91 */ "INT", /* 92 */ "INTEGER", /* 93 */ "BIGINT", /* 94 */ "FLOAT", /* 95 */ "DOUBLE", /* 96 */ "BINARY", /* 97 */ "TIMESTAMP", /* 98 */ "NCHAR", /* 99 */ "UNSIGNED", /* 100 */ "JSON", /* 101 */ "VARCHAR", /* 102 */ "MEDIUMBLOB", /* 103 */ "BLOB", /* 104 */ "VARBINARY", /* 105 */ "DECIMAL", /* 106 */ "SMA", /* 107 */ "ROLLUP", /* 108 */ "FILE_FACTOR", /* 109 */ "NK_FLOAT", /* 110 */ "DELAY", /* 111 */ "SHOW", /* 112 */ "DATABASES", /* 113 */ "TABLES", /* 114 */ "STABLES", /* 115 */ "MNODES", /* 116 */ "MODULES", /* 117 */ "QNODES", /* 118 */ "FUNCTIONS", /* 119 */ "INDEXES", /* 120 */ "FROM", /* 121 */ "ACCOUNTS", /* 122 */ "APPS", /* 123 */ "CONNECTIONS", /* 124 */ "LICENCE", /* 125 */ "GRANTS", /* 126 */ "QUERIES", /* 127 */ "SCORES", /* 128 */ "TOPICS", /* 129 */ "VARIABLES", /* 130 */ "BNODES", /* 131 */ "SNODES", /* 132 */ "LIKE", /* 133 */ "INDEX", /* 134 */ "FULLTEXT", /* 135 */ "FUNCTION", /* 136 */ "INTERVAL", /* 137 */ "TOPIC", /* 138 */ "AS", /* 139 */ "DESC", /* 140 */ "DESCRIBE", /* 141 */ "RESET", /* 142 */ "QUERY", /* 143 */ "EXPLAIN", /* 144 */ "ANALYZE", /* 145 */ "VERBOSE", /* 146 */ "NK_BOOL", /* 147 */ "RATIO", /* 148 */ "COMPACT", /* 149 */ "VNODES", /* 150 */ "IN", /* 151 */ "OUTPUTTYPE", /* 152 */ "AGGREGATE", /* 153 */ "BUFSIZE", /* 154 */ "STREAM", /* 155 */ "INTO", /* 156 */ "KILL", /* 157 */ "CONNECTION", /* 158 */ "MERGE", /* 159 */ "VGROUP", /* 160 */ "REDISTRIBUTE", /* 161 */ "SPLIT", /* 162 */ "SYNCDB", /* 163 */ "NULL", /* 164 */ "FIRST", /* 165 */ "LAST", /* 166 */ "NOW", /* 167 */ "TODAY", /* 168 */ "ROWTS", /* 169 */ "TBNAME", /* 170 */ "QSTARTTS", /* 171 */ "QENDTS", /* 172 */ "WSTARTTS", /* 173 */ "WENDTS", /* 174 */ "WDURATION", /* 175 */ "BETWEEN", /* 176 */ "IS", /* 177 */ "NK_LT", /* 178 */ "NK_GT", /* 179 */ "NK_LE", /* 180 */ "NK_GE", /* 181 */ "NK_NE", /* 182 */ "MATCH", /* 183 */ "NMATCH", /* 184 */ "JOIN", /* 185 */ "INNER", /* 186 */ "SELECT", /* 187 */ "DISTINCT", /* 188 */ "WHERE", /* 189 */ "PARTITION", /* 190 */ "BY", /* 191 */ "SESSION", /* 192 */ "STATE_WINDOW", /* 193 */ "SLIDING", /* 194 */ "FILL", /* 195 */ "VALUE", /* 196 */ "NONE", /* 197 */ "PREV", /* 198 */ "LINEAR", /* 199 */ "NEXT", /* 200 */ "GROUP", /* 201 */ "HAVING", /* 202 */ "ORDER", /* 203 */ "SLIMIT", /* 204 */ "SOFFSET", /* 205 */ "LIMIT", /* 206 */ "OFFSET", /* 207 */ "ASC", /* 208 */ "NULLS", /* 209 */ "cmd", /* 210 */ "account_options", /* 211 */ "alter_account_options", /* 212 */ "literal", /* 213 */ "alter_account_option", /* 214 */ "user_name", /* 215 */ "dnode_endpoint", /* 216 */ "dnode_host_name", /* 217 */ "not_exists_opt", /* 218 */ "db_name", /* 219 */ "db_options", /* 220 */ "exists_opt", /* 221 */ "alter_db_options", /* 222 */ "integer_list", /* 223 */ "variable_list", /* 224 */ "retention_list", /* 225 */ "alter_db_option", /* 226 */ "retention", /* 227 */ "full_table_name", /* 228 */ "column_def_list", /* 229 */ "tags_def_opt", /* 230 */ "table_options", /* 231 */ "multi_create_clause", /* 232 */ "tags_def", /* 233 */ "multi_drop_clause", /* 234 */ "alter_table_clause", /* 235 */ "alter_table_options", /* 236 */ "column_name", /* 237 */ "type_name", /* 238 */ "create_subtable_clause", /* 239 */ "specific_tags_opt", /* 240 */ "literal_list", /* 241 */ "drop_table_clause", /* 242 */ "col_name_list", /* 243 */ "table_name", /* 244 */ "column_def", /* 245 */ "func_name_list", /* 246 */ "alter_table_option", /* 247 */ "col_name", /* 248 */ "db_name_cond_opt", /* 249 */ "like_pattern_opt", /* 250 */ "table_name_cond", /* 251 */ "from_db_opt", /* 252 */ "func_name", /* 253 */ "function_name", /* 254 */ "index_name", /* 255 */ "index_options", /* 256 */ "func_list", /* 257 */ "duration_literal", /* 258 */ "sliding_opt", /* 259 */ "func", /* 260 */ "expression_list", /* 261 */ "topic_name", /* 262 */ "query_expression", /* 263 */ "analyze_opt", /* 264 */ "explain_options", /* 265 */ "agg_func_opt", /* 266 */ "bufsize_opt", /* 267 */ "stream_name", /* 268 */ "dnode_list", /* 269 */ "signed", /* 270 */ "signed_literal", /* 271 */ "table_alias", /* 272 */ "column_alias", /* 273 */ "expression", /* 274 */ "pseudo_column", /* 275 */ "column_reference", /* 276 */ "subquery", /* 277 */ "predicate", /* 278 */ "compare_op", /* 279 */ "in_op", /* 280 */ "in_predicate_value", /* 281 */ "boolean_value_expression", /* 282 */ "boolean_primary", /* 283 */ "common_expression", /* 284 */ "from_clause", /* 285 */ "table_reference_list", /* 286 */ "table_reference", /* 287 */ "table_primary", /* 288 */ "joined_table", /* 289 */ "alias_opt", /* 290 */ "parenthesized_joined_table", /* 291 */ "join_type", /* 292 */ "search_condition", /* 293 */ "query_specification", /* 294 */ "set_quantifier_opt", /* 295 */ "select_list", /* 296 */ "where_clause_opt", /* 297 */ "partition_by_clause_opt", /* 298 */ "twindow_clause_opt", /* 299 */ "group_by_clause_opt", /* 300 */ "having_clause_opt", /* 301 */ "select_sublist", /* 302 */ "select_item", /* 303 */ "fill_opt", /* 304 */ "fill_mode", /* 305 */ "group_by_list", /* 306 */ "query_expression_body", /* 307 */ "order_by_clause_opt", /* 308 */ "slimit_clause_opt", /* 309 */ "limit_clause_opt", /* 310 */ "query_primary", /* 311 */ "sort_specification_list", /* 312 */ "sort_specification", /* 313 */ "ordering_specification_opt", /* 314 */ "null_ordering_opt", }; #endif /* defined(YYCOVERAGE) || !defined(NDEBUG) */ #ifndef NDEBUG /* For tracing reduce actions, the names of all rules are required. */ static const char *const yyRuleName[] = { /* 0 */ "cmd ::= CREATE ACCOUNT NK_ID PASS NK_STRING account_options", /* 1 */ "cmd ::= ALTER ACCOUNT NK_ID alter_account_options", /* 2 */ "account_options ::=", /* 3 */ "account_options ::= account_options PPS literal", /* 4 */ "account_options ::= account_options TSERIES literal", /* 5 */ "account_options ::= account_options STORAGE literal", /* 6 */ "account_options ::= account_options STREAMS literal", /* 7 */ "account_options ::= account_options QTIME literal", /* 8 */ "account_options ::= account_options DBS literal", /* 9 */ "account_options ::= account_options USERS literal", /* 10 */ "account_options ::= account_options CONNS literal", /* 11 */ "account_options ::= account_options STATE literal", /* 12 */ "alter_account_options ::= alter_account_option", /* 13 */ "alter_account_options ::= alter_account_options alter_account_option", /* 14 */ "alter_account_option ::= PASS literal", /* 15 */ "alter_account_option ::= PPS literal", /* 16 */ "alter_account_option ::= TSERIES literal", /* 17 */ "alter_account_option ::= STORAGE literal", /* 18 */ "alter_account_option ::= STREAMS literal", /* 19 */ "alter_account_option ::= QTIME literal", /* 20 */ "alter_account_option ::= DBS literal", /* 21 */ "alter_account_option ::= USERS literal", /* 22 */ "alter_account_option ::= CONNS literal", /* 23 */ "alter_account_option ::= STATE literal", /* 24 */ "cmd ::= CREATE USER user_name PASS NK_STRING", /* 25 */ "cmd ::= ALTER USER user_name PASS NK_STRING", /* 26 */ "cmd ::= ALTER USER user_name PRIVILEGE NK_STRING", /* 27 */ "cmd ::= DROP USER user_name", /* 28 */ "cmd ::= CREATE DNODE dnode_endpoint", /* 29 */ "cmd ::= CREATE DNODE dnode_host_name PORT NK_INTEGER", /* 30 */ "cmd ::= DROP DNODE NK_INTEGER", /* 31 */ "cmd ::= DROP DNODE dnode_endpoint", /* 32 */ "cmd ::= ALTER DNODE NK_INTEGER NK_STRING", /* 33 */ "cmd ::= ALTER DNODE NK_INTEGER NK_STRING NK_STRING", /* 34 */ "cmd ::= ALTER ALL DNODES NK_STRING", /* 35 */ "cmd ::= ALTER ALL DNODES NK_STRING NK_STRING", /* 36 */ "dnode_endpoint ::= NK_STRING", /* 37 */ "dnode_host_name ::= NK_ID", /* 38 */ "dnode_host_name ::= NK_IPTOKEN", /* 39 */ "cmd ::= ALTER LOCAL NK_STRING", /* 40 */ "cmd ::= ALTER LOCAL NK_STRING NK_STRING", /* 41 */ "cmd ::= CREATE QNODE ON DNODE NK_INTEGER", /* 42 */ "cmd ::= DROP QNODE ON DNODE NK_INTEGER", /* 43 */ "cmd ::= CREATE BNODE ON DNODE NK_INTEGER", /* 44 */ "cmd ::= DROP BNODE ON DNODE NK_INTEGER", /* 45 */ "cmd ::= CREATE SNODE ON DNODE NK_INTEGER", /* 46 */ "cmd ::= DROP SNODE ON DNODE NK_INTEGER", /* 47 */ "cmd ::= CREATE MNODE ON DNODE NK_INTEGER", /* 48 */ "cmd ::= DROP MNODE ON DNODE NK_INTEGER", /* 49 */ "cmd ::= CREATE DATABASE not_exists_opt db_name db_options", /* 50 */ "cmd ::= DROP DATABASE exists_opt db_name", /* 51 */ "cmd ::= USE db_name", /* 52 */ "cmd ::= ALTER DATABASE db_name alter_db_options", /* 53 */ "not_exists_opt ::= IF NOT EXISTS", /* 54 */ "not_exists_opt ::=", /* 55 */ "exists_opt ::= IF EXISTS", /* 56 */ "exists_opt ::=", /* 57 */ "db_options ::=", /* 58 */ "db_options ::= db_options BLOCKS NK_INTEGER", /* 59 */ "db_options ::= db_options CACHE NK_INTEGER", /* 60 */ "db_options ::= db_options CACHELAST NK_INTEGER", /* 61 */ "db_options ::= db_options COMP NK_INTEGER", /* 62 */ "db_options ::= db_options DAYS NK_INTEGER", /* 63 */ "db_options ::= db_options DAYS NK_VARIABLE", /* 64 */ "db_options ::= db_options FSYNC NK_INTEGER", /* 65 */ "db_options ::= db_options MAXROWS NK_INTEGER", /* 66 */ "db_options ::= db_options MINROWS NK_INTEGER", /* 67 */ "db_options ::= db_options KEEP integer_list", /* 68 */ "db_options ::= db_options KEEP variable_list", /* 69 */ "db_options ::= db_options PRECISION NK_STRING", /* 70 */ "db_options ::= db_options QUORUM NK_INTEGER", /* 71 */ "db_options ::= db_options REPLICA NK_INTEGER", /* 72 */ "db_options ::= db_options TTL NK_INTEGER", /* 73 */ "db_options ::= db_options WAL NK_INTEGER", /* 74 */ "db_options ::= db_options VGROUPS NK_INTEGER", /* 75 */ "db_options ::= db_options SINGLE_STABLE NK_INTEGER", /* 76 */ "db_options ::= db_options STREAM_MODE NK_INTEGER", /* 77 */ "db_options ::= db_options RETENTIONS retention_list", /* 78 */ "alter_db_options ::= alter_db_option", /* 79 */ "alter_db_options ::= alter_db_options alter_db_option", /* 80 */ "alter_db_option ::= BLOCKS NK_INTEGER", /* 81 */ "alter_db_option ::= FSYNC NK_INTEGER", /* 82 */ "alter_db_option ::= KEEP integer_list", /* 83 */ "alter_db_option ::= KEEP variable_list", /* 84 */ "alter_db_option ::= WAL NK_INTEGER", /* 85 */ "alter_db_option ::= QUORUM NK_INTEGER", /* 86 */ "alter_db_option ::= CACHELAST NK_INTEGER", /* 87 */ "alter_db_option ::= REPLICA NK_INTEGER", /* 88 */ "integer_list ::= NK_INTEGER", /* 89 */ "integer_list ::= integer_list NK_COMMA NK_INTEGER", /* 90 */ "variable_list ::= NK_VARIABLE", /* 91 */ "variable_list ::= variable_list NK_COMMA NK_VARIABLE", /* 92 */ "retention_list ::= retention", /* 93 */ "retention_list ::= retention_list NK_COMMA retention", /* 94 */ "retention ::= NK_VARIABLE NK_COLON NK_VARIABLE", /* 95 */ "cmd ::= CREATE TABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def_opt table_options", /* 96 */ "cmd ::= CREATE TABLE multi_create_clause", /* 97 */ "cmd ::= CREATE STABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def table_options", /* 98 */ "cmd ::= DROP TABLE multi_drop_clause", /* 99 */ "cmd ::= DROP STABLE exists_opt full_table_name", /* 100 */ "cmd ::= ALTER TABLE alter_table_clause", /* 101 */ "cmd ::= ALTER STABLE alter_table_clause", /* 102 */ "alter_table_clause ::= full_table_name alter_table_options", /* 103 */ "alter_table_clause ::= full_table_name ADD COLUMN column_name type_name", /* 104 */ "alter_table_clause ::= full_table_name DROP COLUMN column_name", /* 105 */ "alter_table_clause ::= full_table_name MODIFY COLUMN column_name type_name", /* 106 */ "alter_table_clause ::= full_table_name RENAME COLUMN column_name column_name", /* 107 */ "alter_table_clause ::= full_table_name ADD TAG column_name type_name", /* 108 */ "alter_table_clause ::= full_table_name DROP TAG column_name", /* 109 */ "alter_table_clause ::= full_table_name MODIFY TAG column_name type_name", /* 110 */ "alter_table_clause ::= full_table_name RENAME TAG column_name column_name", /* 111 */ "alter_table_clause ::= full_table_name SET TAG column_name NK_EQ literal", /* 112 */ "multi_create_clause ::= create_subtable_clause", /* 113 */ "multi_create_clause ::= multi_create_clause create_subtable_clause", /* 114 */ "create_subtable_clause ::= not_exists_opt full_table_name USING full_table_name specific_tags_opt TAGS NK_LP literal_list NK_RP", /* 115 */ "multi_drop_clause ::= drop_table_clause", /* 116 */ "multi_drop_clause ::= multi_drop_clause drop_table_clause", /* 117 */ "drop_table_clause ::= exists_opt full_table_name", /* 118 */ "specific_tags_opt ::=", /* 119 */ "specific_tags_opt ::= NK_LP col_name_list NK_RP", /* 120 */ "full_table_name ::= table_name", /* 121 */ "full_table_name ::= db_name NK_DOT table_name", /* 122 */ "column_def_list ::= column_def", /* 123 */ "column_def_list ::= column_def_list NK_COMMA column_def", /* 124 */ "column_def ::= column_name type_name", /* 125 */ "column_def ::= column_name type_name COMMENT NK_STRING", /* 126 */ "type_name ::= BOOL", /* 127 */ "type_name ::= TINYINT", /* 128 */ "type_name ::= SMALLINT", /* 129 */ "type_name ::= INT", /* 130 */ "type_name ::= INTEGER", /* 131 */ "type_name ::= BIGINT", /* 132 */ "type_name ::= FLOAT", /* 133 */ "type_name ::= DOUBLE", /* 134 */ "type_name ::= BINARY NK_LP NK_INTEGER NK_RP", /* 135 */ "type_name ::= TIMESTAMP", /* 136 */ "type_name ::= NCHAR NK_LP NK_INTEGER NK_RP", /* 137 */ "type_name ::= TINYINT UNSIGNED", /* 138 */ "type_name ::= SMALLINT UNSIGNED", /* 139 */ "type_name ::= INT UNSIGNED", /* 140 */ "type_name ::= BIGINT UNSIGNED", /* 141 */ "type_name ::= JSON", /* 142 */ "type_name ::= VARCHAR NK_LP NK_INTEGER NK_RP", /* 143 */ "type_name ::= MEDIUMBLOB", /* 144 */ "type_name ::= BLOB", /* 145 */ "type_name ::= VARBINARY NK_LP NK_INTEGER NK_RP", /* 146 */ "type_name ::= DECIMAL", /* 147 */ "type_name ::= DECIMAL NK_LP NK_INTEGER NK_RP", /* 148 */ "type_name ::= DECIMAL NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP", /* 149 */ "tags_def_opt ::=", /* 150 */ "tags_def_opt ::= tags_def", /* 151 */ "tags_def ::= TAGS NK_LP column_def_list NK_RP", /* 152 */ "table_options ::=", /* 153 */ "table_options ::= table_options COMMENT NK_STRING", /* 154 */ "table_options ::= table_options KEEP integer_list", /* 155 */ "table_options ::= table_options TTL NK_INTEGER", /* 156 */ "table_options ::= table_options SMA NK_LP col_name_list NK_RP", /* 157 */ "table_options ::= table_options ROLLUP NK_LP func_name_list NK_RP", /* 158 */ "table_options ::= table_options FILE_FACTOR NK_FLOAT", /* 159 */ "table_options ::= table_options DELAY NK_INTEGER", /* 160 */ "alter_table_options ::= alter_table_option", /* 161 */ "alter_table_options ::= alter_table_options alter_table_option", /* 162 */ "alter_table_option ::= COMMENT NK_STRING", /* 163 */ "alter_table_option ::= KEEP integer_list", /* 164 */ "alter_table_option ::= TTL NK_INTEGER", /* 165 */ "col_name_list ::= col_name", /* 166 */ "col_name_list ::= col_name_list NK_COMMA col_name", /* 167 */ "col_name ::= column_name", /* 168 */ "cmd ::= SHOW DNODES", /* 169 */ "cmd ::= SHOW USERS", /* 170 */ "cmd ::= SHOW DATABASES", /* 171 */ "cmd ::= SHOW db_name_cond_opt TABLES like_pattern_opt", /* 172 */ "cmd ::= SHOW db_name_cond_opt STABLES like_pattern_opt", /* 173 */ "cmd ::= SHOW db_name_cond_opt VGROUPS", /* 174 */ "cmd ::= SHOW MNODES", /* 175 */ "cmd ::= SHOW MODULES", /* 176 */ "cmd ::= SHOW QNODES", /* 177 */ "cmd ::= SHOW FUNCTIONS", /* 178 */ "cmd ::= SHOW INDEXES FROM table_name_cond from_db_opt", /* 179 */ "cmd ::= SHOW STREAMS", /* 180 */ "cmd ::= SHOW ACCOUNTS", /* 181 */ "cmd ::= SHOW APPS", /* 182 */ "cmd ::= SHOW CONNECTIONS", /* 183 */ "cmd ::= SHOW LICENCE", /* 184 */ "cmd ::= SHOW GRANTS", /* 185 */ "cmd ::= SHOW CREATE DATABASE db_name", /* 186 */ "cmd ::= SHOW CREATE TABLE full_table_name", /* 187 */ "cmd ::= SHOW CREATE STABLE full_table_name", /* 188 */ "cmd ::= SHOW QUERIES", /* 189 */ "cmd ::= SHOW SCORES", /* 190 */ "cmd ::= SHOW TOPICS", /* 191 */ "cmd ::= SHOW VARIABLES", /* 192 */ "cmd ::= SHOW BNODES", /* 193 */ "cmd ::= SHOW SNODES", /* 194 */ "db_name_cond_opt ::=", /* 195 */ "db_name_cond_opt ::= db_name NK_DOT", /* 196 */ "like_pattern_opt ::=", /* 197 */ "like_pattern_opt ::= LIKE NK_STRING", /* 198 */ "table_name_cond ::= table_name", /* 199 */ "from_db_opt ::=", /* 200 */ "from_db_opt ::= FROM db_name", /* 201 */ "func_name_list ::= func_name", /* 202 */ "func_name_list ::= func_name_list NK_COMMA col_name", /* 203 */ "func_name ::= function_name", /* 204 */ "cmd ::= CREATE SMA INDEX not_exists_opt index_name ON table_name index_options", /* 205 */ "cmd ::= CREATE FULLTEXT INDEX not_exists_opt index_name ON table_name NK_LP col_name_list NK_RP", /* 206 */ "cmd ::= DROP INDEX exists_opt index_name ON table_name", /* 207 */ "index_options ::=", /* 208 */ "index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_RP sliding_opt", /* 209 */ "index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt", /* 210 */ "func_list ::= func", /* 211 */ "func_list ::= func_list NK_COMMA func", /* 212 */ "func ::= function_name NK_LP expression_list NK_RP", /* 213 */ "cmd ::= CREATE TOPIC not_exists_opt topic_name AS query_expression", /* 214 */ "cmd ::= CREATE TOPIC not_exists_opt topic_name AS db_name", /* 215 */ "cmd ::= DROP TOPIC exists_opt topic_name", /* 216 */ "cmd ::= DESC full_table_name", /* 217 */ "cmd ::= DESCRIBE full_table_name", /* 218 */ "cmd ::= RESET QUERY CACHE", /* 219 */ "cmd ::= EXPLAIN analyze_opt explain_options query_expression", /* 220 */ "analyze_opt ::=", /* 221 */ "analyze_opt ::= ANALYZE", /* 222 */ "explain_options ::=", /* 223 */ "explain_options ::= explain_options VERBOSE NK_BOOL", /* 224 */ "explain_options ::= explain_options RATIO NK_FLOAT", /* 225 */ "cmd ::= COMPACT VNODES IN NK_LP integer_list NK_RP", /* 226 */ "cmd ::= CREATE agg_func_opt FUNCTION function_name AS NK_STRING OUTPUTTYPE type_name bufsize_opt", /* 227 */ "cmd ::= DROP FUNCTION function_name", /* 228 */ "agg_func_opt ::=", /* 229 */ "agg_func_opt ::= AGGREGATE", /* 230 */ "bufsize_opt ::=", /* 231 */ "bufsize_opt ::= BUFSIZE NK_INTEGER", /* 232 */ "cmd ::= CREATE STREAM stream_name INTO table_name AS query_expression", /* 233 */ "cmd ::= DROP STREAM stream_name", /* 234 */ "cmd ::= KILL CONNECTION NK_INTEGER", /* 235 */ "cmd ::= KILL QUERY NK_INTEGER", /* 236 */ "cmd ::= MERGE VGROUP NK_INTEGER NK_INTEGER", /* 237 */ "cmd ::= REDISTRIBUTE VGROUP NK_INTEGER dnode_list", /* 238 */ "cmd ::= SPLIT VGROUP NK_INTEGER", /* 239 */ "dnode_list ::= DNODE NK_INTEGER", /* 240 */ "dnode_list ::= dnode_list DNODE NK_INTEGER", /* 241 */ "cmd ::= SYNCDB db_name REPLICA", /* 242 */ "cmd ::= query_expression", /* 243 */ "literal ::= NK_INTEGER", /* 244 */ "literal ::= NK_FLOAT", /* 245 */ "literal ::= NK_STRING", /* 246 */ "literal ::= NK_BOOL", /* 247 */ "literal ::= TIMESTAMP NK_STRING", /* 248 */ "literal ::= duration_literal", /* 249 */ "literal ::= NULL", /* 250 */ "duration_literal ::= NK_VARIABLE", /* 251 */ "signed ::= NK_INTEGER", /* 252 */ "signed ::= NK_PLUS NK_INTEGER", /* 253 */ "signed ::= NK_MINUS NK_INTEGER", /* 254 */ "signed ::= NK_FLOAT", /* 255 */ "signed ::= NK_PLUS NK_FLOAT", /* 256 */ "signed ::= NK_MINUS NK_FLOAT", /* 257 */ "signed_literal ::= signed", /* 258 */ "signed_literal ::= NK_STRING", /* 259 */ "signed_literal ::= NK_BOOL", /* 260 */ "signed_literal ::= TIMESTAMP NK_STRING", /* 261 */ "signed_literal ::= duration_literal", /* 262 */ "signed_literal ::= NULL", /* 263 */ "literal_list ::= signed_literal", /* 264 */ "literal_list ::= literal_list NK_COMMA signed_literal", /* 265 */ "db_name ::= NK_ID", /* 266 */ "table_name ::= NK_ID", /* 267 */ "column_name ::= NK_ID", /* 268 */ "function_name ::= NK_ID", /* 269 */ "function_name ::= FIRST", /* 270 */ "function_name ::= LAST", /* 271 */ "function_name ::= NOW", /* 272 */ "function_name ::= TODAY", /* 273 */ "table_alias ::= NK_ID", /* 274 */ "column_alias ::= NK_ID", /* 275 */ "user_name ::= NK_ID", /* 276 */ "index_name ::= NK_ID", /* 277 */ "topic_name ::= NK_ID", /* 278 */ "stream_name ::= NK_ID", /* 279 */ "expression ::= literal", /* 280 */ "expression ::= pseudo_column", /* 281 */ "expression ::= column_reference", /* 282 */ "expression ::= function_name NK_LP expression_list NK_RP", /* 283 */ "expression ::= function_name NK_LP NK_STAR NK_RP", /* 284 */ "expression ::= function_name NK_LP NK_RP", /* 285 */ "expression ::= function_name NK_LP expression AS type_name NK_RP", /* 286 */ "expression ::= subquery", /* 287 */ "expression ::= NK_LP expression NK_RP", /* 288 */ "expression ::= NK_PLUS expression", /* 289 */ "expression ::= NK_MINUS expression", /* 290 */ "expression ::= expression NK_PLUS expression", /* 291 */ "expression ::= expression NK_MINUS expression", /* 292 */ "expression ::= expression NK_STAR expression", /* 293 */ "expression ::= expression NK_SLASH expression", /* 294 */ "expression ::= expression NK_REM expression", /* 295 */ "expression_list ::= expression", /* 296 */ "expression_list ::= expression_list NK_COMMA expression", /* 297 */ "column_reference ::= column_name", /* 298 */ "column_reference ::= table_name NK_DOT column_name", /* 299 */ "pseudo_column ::= ROWTS", /* 300 */ "pseudo_column ::= TBNAME", /* 301 */ "pseudo_column ::= QSTARTTS", /* 302 */ "pseudo_column ::= QENDTS", /* 303 */ "pseudo_column ::= WSTARTTS", /* 304 */ "pseudo_column ::= WENDTS", /* 305 */ "pseudo_column ::= WDURATION", /* 306 */ "predicate ::= expression compare_op expression", /* 307 */ "predicate ::= expression BETWEEN expression AND expression", /* 308 */ "predicate ::= expression NOT BETWEEN expression AND expression", /* 309 */ "predicate ::= expression IS NULL", /* 310 */ "predicate ::= expression IS NOT NULL", /* 311 */ "predicate ::= expression in_op in_predicate_value", /* 312 */ "compare_op ::= NK_LT", /* 313 */ "compare_op ::= NK_GT", /* 314 */ "compare_op ::= NK_LE", /* 315 */ "compare_op ::= NK_GE", /* 316 */ "compare_op ::= NK_NE", /* 317 */ "compare_op ::= NK_EQ", /* 318 */ "compare_op ::= LIKE", /* 319 */ "compare_op ::= NOT LIKE", /* 320 */ "compare_op ::= MATCH", /* 321 */ "compare_op ::= NMATCH", /* 322 */ "in_op ::= IN", /* 323 */ "in_op ::= NOT IN", /* 324 */ "in_predicate_value ::= NK_LP expression_list NK_RP", /* 325 */ "boolean_value_expression ::= boolean_primary", /* 326 */ "boolean_value_expression ::= NOT boolean_primary", /* 327 */ "boolean_value_expression ::= boolean_value_expression OR boolean_value_expression", /* 328 */ "boolean_value_expression ::= boolean_value_expression AND boolean_value_expression", /* 329 */ "boolean_primary ::= predicate", /* 330 */ "boolean_primary ::= NK_LP boolean_value_expression NK_RP", /* 331 */ "common_expression ::= expression", /* 332 */ "common_expression ::= boolean_value_expression", /* 333 */ "from_clause ::= FROM table_reference_list", /* 334 */ "table_reference_list ::= table_reference", /* 335 */ "table_reference_list ::= table_reference_list NK_COMMA table_reference", /* 336 */ "table_reference ::= table_primary", /* 337 */ "table_reference ::= joined_table", /* 338 */ "table_primary ::= table_name alias_opt", /* 339 */ "table_primary ::= db_name NK_DOT table_name alias_opt", /* 340 */ "table_primary ::= subquery alias_opt", /* 341 */ "table_primary ::= parenthesized_joined_table", /* 342 */ "alias_opt ::=", /* 343 */ "alias_opt ::= table_alias", /* 344 */ "alias_opt ::= AS table_alias", /* 345 */ "parenthesized_joined_table ::= NK_LP joined_table NK_RP", /* 346 */ "parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP", /* 347 */ "joined_table ::= table_reference join_type JOIN table_reference ON search_condition", /* 348 */ "join_type ::=", /* 349 */ "join_type ::= INNER", /* 350 */ "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", /* 351 */ "set_quantifier_opt ::=", /* 352 */ "set_quantifier_opt ::= DISTINCT", /* 353 */ "set_quantifier_opt ::= ALL", /* 354 */ "select_list ::= NK_STAR", /* 355 */ "select_list ::= select_sublist", /* 356 */ "select_sublist ::= select_item", /* 357 */ "select_sublist ::= select_sublist NK_COMMA select_item", /* 358 */ "select_item ::= common_expression", /* 359 */ "select_item ::= common_expression column_alias", /* 360 */ "select_item ::= common_expression AS column_alias", /* 361 */ "select_item ::= table_name NK_DOT NK_STAR", /* 362 */ "where_clause_opt ::=", /* 363 */ "where_clause_opt ::= WHERE search_condition", /* 364 */ "partition_by_clause_opt ::=", /* 365 */ "partition_by_clause_opt ::= PARTITION BY expression_list", /* 366 */ "twindow_clause_opt ::=", /* 367 */ "twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA duration_literal NK_RP", /* 368 */ "twindow_clause_opt ::= STATE_WINDOW NK_LP expression NK_RP", /* 369 */ "twindow_clause_opt ::= INTERVAL NK_LP duration_literal NK_RP sliding_opt fill_opt", /* 370 */ "twindow_clause_opt ::= INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt fill_opt", /* 371 */ "sliding_opt ::=", /* 372 */ "sliding_opt ::= SLIDING NK_LP duration_literal NK_RP", /* 373 */ "fill_opt ::=", /* 374 */ "fill_opt ::= FILL NK_LP fill_mode NK_RP", /* 375 */ "fill_opt ::= FILL NK_LP VALUE NK_COMMA literal_list NK_RP", /* 376 */ "fill_mode ::= NONE", /* 377 */ "fill_mode ::= PREV", /* 378 */ "fill_mode ::= NULL", /* 379 */ "fill_mode ::= LINEAR", /* 380 */ "fill_mode ::= NEXT", /* 381 */ "group_by_clause_opt ::=", /* 382 */ "group_by_clause_opt ::= GROUP BY group_by_list", /* 383 */ "group_by_list ::= expression", /* 384 */ "group_by_list ::= group_by_list NK_COMMA expression", /* 385 */ "having_clause_opt ::=", /* 386 */ "having_clause_opt ::= HAVING search_condition", /* 387 */ "query_expression ::= query_expression_body order_by_clause_opt slimit_clause_opt limit_clause_opt", /* 388 */ "query_expression_body ::= query_primary", /* 389 */ "query_expression_body ::= query_expression_body UNION ALL query_expression_body", /* 390 */ "query_primary ::= query_specification", /* 391 */ "order_by_clause_opt ::=", /* 392 */ "order_by_clause_opt ::= ORDER BY sort_specification_list", /* 393 */ "slimit_clause_opt ::=", /* 394 */ "slimit_clause_opt ::= SLIMIT NK_INTEGER", /* 395 */ "slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER", /* 396 */ "slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER", /* 397 */ "limit_clause_opt ::=", /* 398 */ "limit_clause_opt ::= LIMIT NK_INTEGER", /* 399 */ "limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER", /* 400 */ "limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER", /* 401 */ "subquery ::= NK_LP query_expression NK_RP", /* 402 */ "search_condition ::= common_expression", /* 403 */ "sort_specification_list ::= sort_specification", /* 404 */ "sort_specification_list ::= sort_specification_list NK_COMMA sort_specification", /* 405 */ "sort_specification ::= expression ordering_specification_opt null_ordering_opt", /* 406 */ "ordering_specification_opt ::=", /* 407 */ "ordering_specification_opt ::= ASC", /* 408 */ "ordering_specification_opt ::= DESC", /* 409 */ "null_ordering_opt ::=", /* 410 */ "null_ordering_opt ::= NULLS FIRST", /* 411 */ "null_ordering_opt ::= NULLS LAST", }; #endif /* NDEBUG */ #if YYSTACKDEPTH<=0 /* ** Try to increase the size of the parser stack. Return the number ** of errors. Return 0 on success. */ static int yyGrowStack(yyParser *p){ int newSize; int idx; yyStackEntry *pNew; newSize = p->yystksz*2 + 100; idx = p->yytos ? (int)(p->yytos - p->yystack) : 0; if( p->yystack==&p->yystk0 ){ pNew = malloc(newSize*sizeof(pNew[0])); if( pNew ) pNew[0] = p->yystk0; }else{ pNew = realloc(p->yystack, newSize*sizeof(pNew[0])); } if( pNew ){ p->yystack = pNew; p->yytos = &p->yystack[idx]; #ifndef NDEBUG if( yyTraceFILE ){ fprintf(yyTraceFILE,"%sStack grows from %d to %d entries.\n", yyTracePrompt, p->yystksz, newSize); } #endif p->yystksz = newSize; } return pNew==0; } #endif /* Datatype of the argument to the memory allocated passed as the ** second argument to ParseAlloc() below. This can be changed by ** putting an appropriate #define in the %include section of the input ** grammar. */ #ifndef YYMALLOCARGTYPE # define YYMALLOCARGTYPE size_t #endif /* Initialize a new parser that has already been allocated. */ void ParseInit(void *yypRawParser ParseCTX_PDECL){ yyParser *yypParser = (yyParser*)yypRawParser; ParseCTX_STORE #ifdef YYTRACKMAXSTACKDEPTH yypParser->yyhwm = 0; #endif #if YYSTACKDEPTH<=0 yypParser->yytos = NULL; yypParser->yystack = NULL; yypParser->yystksz = 0; if( yyGrowStack(yypParser) ){ yypParser->yystack = &yypParser->yystk0; yypParser->yystksz = 1; } #endif #ifndef YYNOERRORRECOVERY yypParser->yyerrcnt = -1; #endif yypParser->yytos = yypParser->yystack; yypParser->yystack[0].stateno = 0; yypParser->yystack[0].major = 0; #if YYSTACKDEPTH>0 yypParser->yystackEnd = &yypParser->yystack[YYSTACKDEPTH-1]; #endif } #ifndef Parse_ENGINEALWAYSONSTACK /* ** This function allocates a new parser. ** The only argument is a pointer to a function which works like ** malloc. ** ** Inputs: ** A pointer to the function used to allocate memory. ** ** Outputs: ** A pointer to a parser. This pointer is used in subsequent calls ** to Parse and ParseFree. */ void *ParseAlloc(void *(*mallocProc)(YYMALLOCARGTYPE) ParseCTX_PDECL){ yyParser *yypParser; yypParser = (yyParser*)(*mallocProc)( (YYMALLOCARGTYPE)sizeof(yyParser) ); if( yypParser ){ ParseCTX_STORE ParseInit(yypParser ParseCTX_PARAM); } return (void*)yypParser; } #endif /* Parse_ENGINEALWAYSONSTACK */ /* The following function deletes the "minor type" or semantic value ** associated with a symbol. The symbol can be either a terminal ** or nonterminal. "yymajor" is the symbol code, and "yypminor" is ** a pointer to the value to be deleted. The code used to do the ** deletions is derived from the %destructor and/or %token_destructor ** directives of the input grammar. */ static void yy_destructor( yyParser *yypParser, /* The parser */ YYCODETYPE yymajor, /* Type code for object to destroy */ YYMINORTYPE *yypminor /* The object to be destroyed */ ){ ParseARG_FETCH ParseCTX_FETCH switch( yymajor ){ /* Here is inserted the actions which take place when a ** terminal or non-terminal is destroyed. This can happen ** when the symbol is popped from the stack during a ** reduce or during error processing or when a parser is ** being destroyed before it is finished parsing. ** ** Note: during a reduce, the only symbols destroyed are those ** which appear on the RHS of the rule, but which are *not* used ** inside the C code. */ /********* Begin destructor definitions ***************************************/ /* Default NON-TERMINAL Destructor */ case 209: /* cmd */ case 212: /* literal */ case 219: /* db_options */ case 221: /* alter_db_options */ case 226: /* retention */ case 227: /* full_table_name */ case 230: /* table_options */ case 234: /* alter_table_clause */ case 235: /* alter_table_options */ case 238: /* create_subtable_clause */ case 241: /* drop_table_clause */ case 244: /* column_def */ case 247: /* col_name */ case 248: /* db_name_cond_opt */ case 249: /* like_pattern_opt */ case 250: /* table_name_cond */ case 251: /* from_db_opt */ case 252: /* func_name */ case 255: /* index_options */ case 257: /* duration_literal */ case 258: /* sliding_opt */ case 259: /* func */ case 262: /* query_expression */ case 264: /* explain_options */ case 269: /* signed */ case 270: /* signed_literal */ case 273: /* expression */ case 274: /* pseudo_column */ case 275: /* column_reference */ case 276: /* subquery */ case 277: /* predicate */ case 280: /* in_predicate_value */ case 281: /* boolean_value_expression */ case 282: /* boolean_primary */ case 283: /* common_expression */ case 284: /* from_clause */ case 285: /* table_reference_list */ case 286: /* table_reference */ case 287: /* table_primary */ case 288: /* joined_table */ case 290: /* parenthesized_joined_table */ case 292: /* search_condition */ case 293: /* query_specification */ case 296: /* where_clause_opt */ case 298: /* twindow_clause_opt */ case 300: /* having_clause_opt */ case 302: /* select_item */ case 303: /* fill_opt */ case 306: /* query_expression_body */ case 308: /* slimit_clause_opt */ case 309: /* limit_clause_opt */ case 310: /* query_primary */ case 312: /* sort_specification */ { nodesDestroyNode((yypminor->yy182)); } break; case 210: /* account_options */ case 211: /* alter_account_options */ case 213: /* alter_account_option */ case 266: /* bufsize_opt */ { } break; case 214: /* user_name */ case 215: /* dnode_endpoint */ case 216: /* dnode_host_name */ case 218: /* db_name */ case 236: /* column_name */ case 243: /* table_name */ case 253: /* function_name */ case 254: /* index_name */ case 261: /* topic_name */ case 267: /* stream_name */ case 271: /* table_alias */ case 272: /* column_alias */ case 289: /* alias_opt */ { } break; case 217: /* not_exists_opt */ case 220: /* exists_opt */ case 263: /* analyze_opt */ case 265: /* agg_func_opt */ case 294: /* set_quantifier_opt */ { } break; case 222: /* integer_list */ case 223: /* variable_list */ case 224: /* retention_list */ case 228: /* column_def_list */ case 229: /* tags_def_opt */ case 231: /* multi_create_clause */ case 232: /* tags_def */ case 233: /* multi_drop_clause */ case 239: /* specific_tags_opt */ case 240: /* literal_list */ case 242: /* col_name_list */ case 245: /* func_name_list */ case 256: /* func_list */ case 260: /* expression_list */ case 268: /* dnode_list */ case 295: /* select_list */ case 297: /* partition_by_clause_opt */ case 299: /* group_by_clause_opt */ case 301: /* select_sublist */ case 305: /* group_by_list */ case 307: /* order_by_clause_opt */ case 311: /* sort_specification_list */ { nodesDestroyList((yypminor->yy334)); } break; case 225: /* alter_db_option */ case 246: /* alter_table_option */ { } break; case 237: /* type_name */ { } break; case 278: /* compare_op */ case 279: /* in_op */ { } break; case 291: /* join_type */ { } break; case 304: /* fill_mode */ { } break; case 313: /* ordering_specification_opt */ { } break; case 314: /* null_ordering_opt */ { } break; /********* End destructor definitions *****************************************/ default: break; /* If no destructor action specified: do nothing */ } } /* ** Pop the parser's stack once. ** ** If there is a destructor routine associated with the token which ** is popped from the stack, then call it. */ static void yy_pop_parser_stack(yyParser *pParser){ yyStackEntry *yytos; assert( pParser->yytos!=0 ); assert( pParser->yytos > pParser->yystack ); yytos = pParser->yytos--; #ifndef NDEBUG if( yyTraceFILE ){ fprintf(yyTraceFILE,"%sPopping %s\n", yyTracePrompt, yyTokenName[yytos->major]); } #endif yy_destructor(pParser, yytos->major, &yytos->minor); } /* ** Clear all secondary memory allocations from the parser */ 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 ) free(pParser->yystack); #endif } #ifndef Parse_ENGINEALWAYSONSTACK /* ** Deallocate and destroy a parser. Destructors are called for ** all stack elements before shutting the parser down. ** ** If the YYPARSEFREENEVERNULL macro exists (for example because it ** is defined in a %include section of the input grammar) then it is ** assumed that the input pointer is never NULL. */ void ParseFree( void *p, /* The parser to be deleted */ void (*freeProc)(void*) /* Function used to reclaim memory */ ){ #ifndef YYPARSEFREENEVERNULL if( p==0 ) return; #endif ParseFinalize(p); (*freeProc)(p); } #endif /* Parse_ENGINEALWAYSONSTACK */ /* ** Return the peak depth of the stack for a parser. */ #ifdef YYTRACKMAXSTACKDEPTH int ParseStackPeak(void *p){ yyParser *pParser = (yyParser*)p; return pParser->yyhwm; } #endif /* This array of booleans keeps track of the parser statement ** coverage. The element yycoverage[X][Y] is set when the parser ** is in state X and has a lookahead token Y. In a well-tested ** systems, every element of this matrix should end up being set. */ #if defined(YYCOVERAGE) static unsigned char yycoverage[YYNSTATE][YYNTOKEN]; #endif /* ** Write into out a description of every state/lookahead combination that ** ** (1) has not been used by the parser, and ** (2) is not a syntax error. ** ** Return the number of missed state/lookahead combinations. */ #if defined(YYCOVERAGE) int ParseCoverage(FILE *out){ int stateno, iLookAhead, i; int nMissed = 0; for(stateno=0; statenoYY_MAX_SHIFT ) return stateno; assert( stateno <= YY_SHIFT_COUNT ); #if defined(YYCOVERAGE) yycoverage[stateno][iLookAhead] = 1; #endif do{ i = yy_shift_ofst[stateno]; assert( i>=0 ); assert( i<=YY_ACTTAB_COUNT ); assert( i+YYNTOKEN<=(int)YY_NLOOKAHEAD ); assert( iLookAhead!=YYNOCODE ); assert( iLookAhead < YYNTOKEN ); i += iLookAhead; assert( i<(int)YY_NLOOKAHEAD ); if( yy_lookahead[i]!=iLookAhead ){ #ifdef YYFALLBACK YYCODETYPE iFallback; /* Fallback token */ assert( iLookAhead %s\n", yyTracePrompt, yyTokenName[iLookAhead], yyTokenName[iFallback]); } #endif assert( yyFallback[iFallback]==0 ); /* Fallback loop must terminate */ iLookAhead = iFallback; continue; } #endif #ifdef YYWILDCARD { int j = i - iLookAhead + YYWILDCARD; assert( j<(int)(sizeof(yy_lookahead)/sizeof(yy_lookahead[0])) ); if( yy_lookahead[j]==YYWILDCARD && iLookAhead>0 ){ #ifndef NDEBUG if( yyTraceFILE ){ fprintf(yyTraceFILE, "%sWILDCARD %s => %s\n", yyTracePrompt, yyTokenName[iLookAhead], yyTokenName[YYWILDCARD]); } #endif /* NDEBUG */ return yy_action[j]; } } #endif /* YYWILDCARD */ return yy_default[stateno]; }else{ assert( i>=0 && iYY_REDUCE_COUNT ){ return yy_default[stateno]; } #else assert( stateno<=YY_REDUCE_COUNT ); #endif i = yy_reduce_ofst[stateno]; assert( iLookAhead!=YYNOCODE ); i += iLookAhead; #ifdef YYERRORSYMBOL if( i<0 || i>=YY_ACTTAB_COUNT || yy_lookahead[i]!=iLookAhead ){ return yy_default[stateno]; } #else assert( i>=0 && iyytos>yypParser->yystack ) yy_pop_parser_stack(yypParser); /* Here code is inserted which will execute if the parser ** stack every overflows */ /******** Begin %stack_overflow code ******************************************/ /******** End %stack_overflow code ********************************************/ ParseARG_STORE /* Suppress warning about unused %extra_argument var */ ParseCTX_STORE } /* ** Print tracing information for a SHIFT action */ #ifndef NDEBUG static void yyTraceShift(yyParser *yypParser, int yyNewState, const char *zTag){ if( yyTraceFILE ){ if( yyNewStateyytos->major], yyNewState); }else{ fprintf(yyTraceFILE,"%s%s '%s', pending reduce %d\n", yyTracePrompt, zTag, yyTokenName[yypParser->yytos->major], yyNewState - YY_MIN_REDUCE); } } } #else # define yyTraceShift(X,Y,Z) #endif /* ** Perform a shift action. */ static void yy_shift( yyParser *yypParser, /* The parser to be shifted */ YYACTIONTYPE yyNewState, /* The new state to shift in */ YYCODETYPE yyMajor, /* The major token to shift in */ ParseTOKENTYPE yyMinor /* The minor token to shift in */ ){ yyStackEntry *yytos; yypParser->yytos++; #ifdef YYTRACKMAXSTACKDEPTH if( (int)(yypParser->yytos - yypParser->yystack)>yypParser->yyhwm ){ yypParser->yyhwm++; assert( yypParser->yyhwm == (int)(yypParser->yytos - yypParser->yystack) ); } #endif #if YYSTACKDEPTH>0 if( yypParser->yytos>yypParser->yystackEnd ){ yypParser->yytos--; yyStackOverflow(yypParser); return; } #else if( yypParser->yytos>=&yypParser->yystack[yypParser->yystksz] ){ if( yyGrowStack(yypParser) ){ yypParser->yytos--; yyStackOverflow(yypParser); return; } } #endif if( yyNewState > YY_MAX_SHIFT ){ yyNewState += YY_MIN_REDUCE - YY_MIN_SHIFTREDUCE; } yytos = yypParser->yytos; yytos->stateno = yyNewState; yytos->major = yyMajor; yytos->minor.yy0 = yyMinor; yyTraceShift(yypParser, yyNewState, "Shift"); } /* For rule J, yyRuleInfoLhs[J] contains the symbol on the left-hand side ** of that rule */ static const YYCODETYPE yyRuleInfoLhs[] = { 209, /* (0) cmd ::= CREATE ACCOUNT NK_ID PASS NK_STRING account_options */ 209, /* (1) cmd ::= ALTER ACCOUNT NK_ID alter_account_options */ 210, /* (2) account_options ::= */ 210, /* (3) account_options ::= account_options PPS literal */ 210, /* (4) account_options ::= account_options TSERIES literal */ 210, /* (5) account_options ::= account_options STORAGE literal */ 210, /* (6) account_options ::= account_options STREAMS literal */ 210, /* (7) account_options ::= account_options QTIME literal */ 210, /* (8) account_options ::= account_options DBS literal */ 210, /* (9) account_options ::= account_options USERS literal */ 210, /* (10) account_options ::= account_options CONNS literal */ 210, /* (11) account_options ::= account_options STATE literal */ 211, /* (12) alter_account_options ::= alter_account_option */ 211, /* (13) alter_account_options ::= alter_account_options alter_account_option */ 213, /* (14) alter_account_option ::= PASS literal */ 213, /* (15) alter_account_option ::= PPS literal */ 213, /* (16) alter_account_option ::= TSERIES literal */ 213, /* (17) alter_account_option ::= STORAGE literal */ 213, /* (18) alter_account_option ::= STREAMS literal */ 213, /* (19) alter_account_option ::= QTIME literal */ 213, /* (20) alter_account_option ::= DBS literal */ 213, /* (21) alter_account_option ::= USERS literal */ 213, /* (22) alter_account_option ::= CONNS literal */ 213, /* (23) alter_account_option ::= STATE literal */ 209, /* (24) cmd ::= CREATE USER user_name PASS NK_STRING */ 209, /* (25) cmd ::= ALTER USER user_name PASS NK_STRING */ 209, /* (26) cmd ::= ALTER USER user_name PRIVILEGE NK_STRING */ 209, /* (27) cmd ::= DROP USER user_name */ 209, /* (28) cmd ::= CREATE DNODE dnode_endpoint */ 209, /* (29) cmd ::= CREATE DNODE dnode_host_name PORT NK_INTEGER */ 209, /* (30) cmd ::= DROP DNODE NK_INTEGER */ 209, /* (31) cmd ::= DROP DNODE dnode_endpoint */ 209, /* (32) cmd ::= ALTER DNODE NK_INTEGER NK_STRING */ 209, /* (33) cmd ::= ALTER DNODE NK_INTEGER NK_STRING NK_STRING */ 209, /* (34) cmd ::= ALTER ALL DNODES NK_STRING */ 209, /* (35) cmd ::= ALTER ALL DNODES NK_STRING NK_STRING */ 215, /* (36) dnode_endpoint ::= NK_STRING */ 216, /* (37) dnode_host_name ::= NK_ID */ 216, /* (38) dnode_host_name ::= NK_IPTOKEN */ 209, /* (39) cmd ::= ALTER LOCAL NK_STRING */ 209, /* (40) cmd ::= ALTER LOCAL NK_STRING NK_STRING */ 209, /* (41) cmd ::= CREATE QNODE ON DNODE NK_INTEGER */ 209, /* (42) cmd ::= DROP QNODE ON DNODE NK_INTEGER */ 209, /* (43) cmd ::= CREATE BNODE ON DNODE NK_INTEGER */ 209, /* (44) cmd ::= DROP BNODE ON DNODE NK_INTEGER */ 209, /* (45) cmd ::= CREATE SNODE ON DNODE NK_INTEGER */ 209, /* (46) cmd ::= DROP SNODE ON DNODE NK_INTEGER */ 209, /* (47) cmd ::= CREATE MNODE ON DNODE NK_INTEGER */ 209, /* (48) cmd ::= DROP MNODE ON DNODE NK_INTEGER */ 209, /* (49) cmd ::= CREATE DATABASE not_exists_opt db_name db_options */ 209, /* (50) cmd ::= DROP DATABASE exists_opt db_name */ 209, /* (51) cmd ::= USE db_name */ 209, /* (52) cmd ::= ALTER DATABASE db_name alter_db_options */ 217, /* (53) not_exists_opt ::= IF NOT EXISTS */ 217, /* (54) not_exists_opt ::= */ 220, /* (55) exists_opt ::= IF EXISTS */ 220, /* (56) exists_opt ::= */ 219, /* (57) db_options ::= */ 219, /* (58) db_options ::= db_options BLOCKS NK_INTEGER */ 219, /* (59) db_options ::= db_options CACHE NK_INTEGER */ 219, /* (60) db_options ::= db_options CACHELAST NK_INTEGER */ 219, /* (61) db_options ::= db_options COMP NK_INTEGER */ 219, /* (62) db_options ::= db_options DAYS NK_INTEGER */ 219, /* (63) db_options ::= db_options DAYS NK_VARIABLE */ 219, /* (64) db_options ::= db_options FSYNC NK_INTEGER */ 219, /* (65) db_options ::= db_options MAXROWS NK_INTEGER */ 219, /* (66) db_options ::= db_options MINROWS NK_INTEGER */ 219, /* (67) db_options ::= db_options KEEP integer_list */ 219, /* (68) db_options ::= db_options KEEP variable_list */ 219, /* (69) db_options ::= db_options PRECISION NK_STRING */ 219, /* (70) db_options ::= db_options QUORUM NK_INTEGER */ 219, /* (71) db_options ::= db_options REPLICA NK_INTEGER */ 219, /* (72) db_options ::= db_options TTL NK_INTEGER */ 219, /* (73) db_options ::= db_options WAL NK_INTEGER */ 219, /* (74) db_options ::= db_options VGROUPS NK_INTEGER */ 219, /* (75) db_options ::= db_options SINGLE_STABLE NK_INTEGER */ 219, /* (76) db_options ::= db_options STREAM_MODE NK_INTEGER */ 219, /* (77) db_options ::= db_options RETENTIONS retention_list */ 221, /* (78) alter_db_options ::= alter_db_option */ 221, /* (79) alter_db_options ::= alter_db_options alter_db_option */ 225, /* (80) alter_db_option ::= BLOCKS NK_INTEGER */ 225, /* (81) alter_db_option ::= FSYNC NK_INTEGER */ 225, /* (82) alter_db_option ::= KEEP integer_list */ 225, /* (83) alter_db_option ::= KEEP variable_list */ 225, /* (84) alter_db_option ::= WAL NK_INTEGER */ 225, /* (85) alter_db_option ::= QUORUM NK_INTEGER */ 225, /* (86) alter_db_option ::= CACHELAST NK_INTEGER */ 225, /* (87) alter_db_option ::= REPLICA NK_INTEGER */ 222, /* (88) integer_list ::= NK_INTEGER */ 222, /* (89) integer_list ::= integer_list NK_COMMA NK_INTEGER */ 223, /* (90) variable_list ::= NK_VARIABLE */ 223, /* (91) variable_list ::= variable_list NK_COMMA NK_VARIABLE */ 224, /* (92) retention_list ::= retention */ 224, /* (93) retention_list ::= retention_list NK_COMMA retention */ 226, /* (94) retention ::= NK_VARIABLE NK_COLON NK_VARIABLE */ 209, /* (95) cmd ::= CREATE TABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def_opt table_options */ 209, /* (96) cmd ::= CREATE TABLE multi_create_clause */ 209, /* (97) cmd ::= CREATE STABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def table_options */ 209, /* (98) cmd ::= DROP TABLE multi_drop_clause */ 209, /* (99) cmd ::= DROP STABLE exists_opt full_table_name */ 209, /* (100) cmd ::= ALTER TABLE alter_table_clause */ 209, /* (101) cmd ::= ALTER STABLE alter_table_clause */ 234, /* (102) alter_table_clause ::= full_table_name alter_table_options */ 234, /* (103) alter_table_clause ::= full_table_name ADD COLUMN column_name type_name */ 234, /* (104) alter_table_clause ::= full_table_name DROP COLUMN column_name */ 234, /* (105) alter_table_clause ::= full_table_name MODIFY COLUMN column_name type_name */ 234, /* (106) alter_table_clause ::= full_table_name RENAME COLUMN column_name column_name */ 234, /* (107) alter_table_clause ::= full_table_name ADD TAG column_name type_name */ 234, /* (108) alter_table_clause ::= full_table_name DROP TAG column_name */ 234, /* (109) alter_table_clause ::= full_table_name MODIFY TAG column_name type_name */ 234, /* (110) alter_table_clause ::= full_table_name RENAME TAG column_name column_name */ 234, /* (111) alter_table_clause ::= full_table_name SET TAG column_name NK_EQ literal */ 231, /* (112) multi_create_clause ::= create_subtable_clause */ 231, /* (113) multi_create_clause ::= multi_create_clause create_subtable_clause */ 238, /* (114) create_subtable_clause ::= not_exists_opt full_table_name USING full_table_name specific_tags_opt TAGS NK_LP literal_list NK_RP */ 233, /* (115) multi_drop_clause ::= drop_table_clause */ 233, /* (116) multi_drop_clause ::= multi_drop_clause drop_table_clause */ 241, /* (117) drop_table_clause ::= exists_opt full_table_name */ 239, /* (118) specific_tags_opt ::= */ 239, /* (119) specific_tags_opt ::= NK_LP col_name_list NK_RP */ 227, /* (120) full_table_name ::= table_name */ 227, /* (121) full_table_name ::= db_name NK_DOT table_name */ 228, /* (122) column_def_list ::= column_def */ 228, /* (123) column_def_list ::= column_def_list NK_COMMA column_def */ 244, /* (124) column_def ::= column_name type_name */ 244, /* (125) column_def ::= column_name type_name COMMENT NK_STRING */ 237, /* (126) type_name ::= BOOL */ 237, /* (127) type_name ::= TINYINT */ 237, /* (128) type_name ::= SMALLINT */ 237, /* (129) type_name ::= INT */ 237, /* (130) type_name ::= INTEGER */ 237, /* (131) type_name ::= BIGINT */ 237, /* (132) type_name ::= FLOAT */ 237, /* (133) type_name ::= DOUBLE */ 237, /* (134) type_name ::= BINARY NK_LP NK_INTEGER NK_RP */ 237, /* (135) type_name ::= TIMESTAMP */ 237, /* (136) type_name ::= NCHAR NK_LP NK_INTEGER NK_RP */ 237, /* (137) type_name ::= TINYINT UNSIGNED */ 237, /* (138) type_name ::= SMALLINT UNSIGNED */ 237, /* (139) type_name ::= INT UNSIGNED */ 237, /* (140) type_name ::= BIGINT UNSIGNED */ 237, /* (141) type_name ::= JSON */ 237, /* (142) type_name ::= VARCHAR NK_LP NK_INTEGER NK_RP */ 237, /* (143) type_name ::= MEDIUMBLOB */ 237, /* (144) type_name ::= BLOB */ 237, /* (145) type_name ::= VARBINARY NK_LP NK_INTEGER NK_RP */ 237, /* (146) type_name ::= DECIMAL */ 237, /* (147) type_name ::= DECIMAL NK_LP NK_INTEGER NK_RP */ 237, /* (148) type_name ::= DECIMAL NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP */ 229, /* (149) tags_def_opt ::= */ 229, /* (150) tags_def_opt ::= tags_def */ 232, /* (151) tags_def ::= TAGS NK_LP column_def_list NK_RP */ 230, /* (152) table_options ::= */ 230, /* (153) table_options ::= table_options COMMENT NK_STRING */ 230, /* (154) table_options ::= table_options KEEP integer_list */ 230, /* (155) table_options ::= table_options TTL NK_INTEGER */ 230, /* (156) table_options ::= table_options SMA NK_LP col_name_list NK_RP */ 230, /* (157) table_options ::= table_options ROLLUP NK_LP func_name_list NK_RP */ 230, /* (158) table_options ::= table_options FILE_FACTOR NK_FLOAT */ 230, /* (159) table_options ::= table_options DELAY NK_INTEGER */ 235, /* (160) alter_table_options ::= alter_table_option */ 235, /* (161) alter_table_options ::= alter_table_options alter_table_option */ 246, /* (162) alter_table_option ::= COMMENT NK_STRING */ 246, /* (163) alter_table_option ::= KEEP integer_list */ 246, /* (164) alter_table_option ::= TTL NK_INTEGER */ 242, /* (165) col_name_list ::= col_name */ 242, /* (166) col_name_list ::= col_name_list NK_COMMA col_name */ 247, /* (167) col_name ::= column_name */ 209, /* (168) cmd ::= SHOW DNODES */ 209, /* (169) cmd ::= SHOW USERS */ 209, /* (170) cmd ::= SHOW DATABASES */ 209, /* (171) cmd ::= SHOW db_name_cond_opt TABLES like_pattern_opt */ 209, /* (172) cmd ::= SHOW db_name_cond_opt STABLES like_pattern_opt */ 209, /* (173) cmd ::= SHOW db_name_cond_opt VGROUPS */ 209, /* (174) cmd ::= SHOW MNODES */ 209, /* (175) cmd ::= SHOW MODULES */ 209, /* (176) cmd ::= SHOW QNODES */ 209, /* (177) cmd ::= SHOW FUNCTIONS */ 209, /* (178) cmd ::= SHOW INDEXES FROM table_name_cond from_db_opt */ 209, /* (179) cmd ::= SHOW STREAMS */ 209, /* (180) cmd ::= SHOW ACCOUNTS */ 209, /* (181) cmd ::= SHOW APPS */ 209, /* (182) cmd ::= SHOW CONNECTIONS */ 209, /* (183) cmd ::= SHOW LICENCE */ 209, /* (184) cmd ::= SHOW GRANTS */ 209, /* (185) cmd ::= SHOW CREATE DATABASE db_name */ 209, /* (186) cmd ::= SHOW CREATE TABLE full_table_name */ 209, /* (187) cmd ::= SHOW CREATE STABLE full_table_name */ 209, /* (188) cmd ::= SHOW QUERIES */ 209, /* (189) cmd ::= SHOW SCORES */ 209, /* (190) cmd ::= SHOW TOPICS */ 209, /* (191) cmd ::= SHOW VARIABLES */ 209, /* (192) cmd ::= SHOW BNODES */ 209, /* (193) cmd ::= SHOW SNODES */ 248, /* (194) db_name_cond_opt ::= */ 248, /* (195) db_name_cond_opt ::= db_name NK_DOT */ 249, /* (196) like_pattern_opt ::= */ 249, /* (197) like_pattern_opt ::= LIKE NK_STRING */ 250, /* (198) table_name_cond ::= table_name */ 251, /* (199) from_db_opt ::= */ 251, /* (200) from_db_opt ::= FROM db_name */ 245, /* (201) func_name_list ::= func_name */ 245, /* (202) func_name_list ::= func_name_list NK_COMMA col_name */ 252, /* (203) func_name ::= function_name */ 209, /* (204) cmd ::= CREATE SMA INDEX not_exists_opt index_name ON table_name index_options */ 209, /* (205) cmd ::= CREATE FULLTEXT INDEX not_exists_opt index_name ON table_name NK_LP col_name_list NK_RP */ 209, /* (206) cmd ::= DROP INDEX exists_opt index_name ON table_name */ 255, /* (207) index_options ::= */ 255, /* (208) index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_RP sliding_opt */ 255, /* (209) index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt */ 256, /* (210) func_list ::= func */ 256, /* (211) func_list ::= func_list NK_COMMA func */ 259, /* (212) func ::= function_name NK_LP expression_list NK_RP */ 209, /* (213) cmd ::= CREATE TOPIC not_exists_opt topic_name AS query_expression */ 209, /* (214) cmd ::= CREATE TOPIC not_exists_opt topic_name AS db_name */ 209, /* (215) cmd ::= DROP TOPIC exists_opt topic_name */ 209, /* (216) cmd ::= DESC full_table_name */ 209, /* (217) cmd ::= DESCRIBE full_table_name */ 209, /* (218) cmd ::= RESET QUERY CACHE */ 209, /* (219) cmd ::= EXPLAIN analyze_opt explain_options query_expression */ 263, /* (220) analyze_opt ::= */ 263, /* (221) analyze_opt ::= ANALYZE */ 264, /* (222) explain_options ::= */ 264, /* (223) explain_options ::= explain_options VERBOSE NK_BOOL */ 264, /* (224) explain_options ::= explain_options RATIO NK_FLOAT */ 209, /* (225) cmd ::= COMPACT VNODES IN NK_LP integer_list NK_RP */ 209, /* (226) cmd ::= CREATE agg_func_opt FUNCTION function_name AS NK_STRING OUTPUTTYPE type_name bufsize_opt */ 209, /* (227) cmd ::= DROP FUNCTION function_name */ 265, /* (228) agg_func_opt ::= */ 265, /* (229) agg_func_opt ::= AGGREGATE */ 266, /* (230) bufsize_opt ::= */ 266, /* (231) bufsize_opt ::= BUFSIZE NK_INTEGER */ 209, /* (232) cmd ::= CREATE STREAM stream_name INTO table_name AS query_expression */ 209, /* (233) cmd ::= DROP STREAM stream_name */ 209, /* (234) cmd ::= KILL CONNECTION NK_INTEGER */ 209, /* (235) cmd ::= KILL QUERY NK_INTEGER */ 209, /* (236) cmd ::= MERGE VGROUP NK_INTEGER NK_INTEGER */ 209, /* (237) cmd ::= REDISTRIBUTE VGROUP NK_INTEGER dnode_list */ 209, /* (238) cmd ::= SPLIT VGROUP NK_INTEGER */ 268, /* (239) dnode_list ::= DNODE NK_INTEGER */ 268, /* (240) dnode_list ::= dnode_list DNODE NK_INTEGER */ 209, /* (241) cmd ::= SYNCDB db_name REPLICA */ 209, /* (242) cmd ::= query_expression */ 212, /* (243) literal ::= NK_INTEGER */ 212, /* (244) literal ::= NK_FLOAT */ 212, /* (245) literal ::= NK_STRING */ 212, /* (246) literal ::= NK_BOOL */ 212, /* (247) literal ::= TIMESTAMP NK_STRING */ 212, /* (248) literal ::= duration_literal */ 212, /* (249) literal ::= NULL */ 257, /* (250) duration_literal ::= NK_VARIABLE */ 269, /* (251) signed ::= NK_INTEGER */ 269, /* (252) signed ::= NK_PLUS NK_INTEGER */ 269, /* (253) signed ::= NK_MINUS NK_INTEGER */ 269, /* (254) signed ::= NK_FLOAT */ 269, /* (255) signed ::= NK_PLUS NK_FLOAT */ 269, /* (256) signed ::= NK_MINUS NK_FLOAT */ 270, /* (257) signed_literal ::= signed */ 270, /* (258) signed_literal ::= NK_STRING */ 270, /* (259) signed_literal ::= NK_BOOL */ 270, /* (260) signed_literal ::= TIMESTAMP NK_STRING */ 270, /* (261) signed_literal ::= duration_literal */ 270, /* (262) signed_literal ::= NULL */ 240, /* (263) literal_list ::= signed_literal */ 240, /* (264) literal_list ::= literal_list NK_COMMA signed_literal */ 218, /* (265) db_name ::= NK_ID */ 243, /* (266) table_name ::= NK_ID */ 236, /* (267) column_name ::= NK_ID */ 253, /* (268) function_name ::= NK_ID */ 253, /* (269) function_name ::= FIRST */ 253, /* (270) function_name ::= LAST */ 253, /* (271) function_name ::= NOW */ 253, /* (272) function_name ::= TODAY */ 271, /* (273) table_alias ::= NK_ID */ 272, /* (274) column_alias ::= NK_ID */ 214, /* (275) user_name ::= NK_ID */ 254, /* (276) index_name ::= NK_ID */ 261, /* (277) topic_name ::= NK_ID */ 267, /* (278) stream_name ::= NK_ID */ 273, /* (279) expression ::= literal */ 273, /* (280) expression ::= pseudo_column */ 273, /* (281) expression ::= column_reference */ 273, /* (282) expression ::= function_name NK_LP expression_list NK_RP */ 273, /* (283) expression ::= function_name NK_LP NK_STAR NK_RP */ 273, /* (284) expression ::= function_name NK_LP NK_RP */ 273, /* (285) expression ::= function_name NK_LP expression AS type_name NK_RP */ 273, /* (286) expression ::= subquery */ 273, /* (287) expression ::= NK_LP expression NK_RP */ 273, /* (288) expression ::= NK_PLUS expression */ 273, /* (289) expression ::= NK_MINUS expression */ 273, /* (290) expression ::= expression NK_PLUS expression */ 273, /* (291) expression ::= expression NK_MINUS expression */ 273, /* (292) expression ::= expression NK_STAR expression */ 273, /* (293) expression ::= expression NK_SLASH expression */ 273, /* (294) expression ::= expression NK_REM expression */ 260, /* (295) expression_list ::= expression */ 260, /* (296) expression_list ::= expression_list NK_COMMA expression */ 275, /* (297) column_reference ::= column_name */ 275, /* (298) column_reference ::= table_name NK_DOT column_name */ 274, /* (299) pseudo_column ::= ROWTS */ 274, /* (300) pseudo_column ::= TBNAME */ 274, /* (301) pseudo_column ::= QSTARTTS */ 274, /* (302) pseudo_column ::= QENDTS */ 274, /* (303) pseudo_column ::= WSTARTTS */ 274, /* (304) pseudo_column ::= WENDTS */ 274, /* (305) pseudo_column ::= WDURATION */ 277, /* (306) predicate ::= expression compare_op expression */ 277, /* (307) predicate ::= expression BETWEEN expression AND expression */ 277, /* (308) predicate ::= expression NOT BETWEEN expression AND expression */ 277, /* (309) predicate ::= expression IS NULL */ 277, /* (310) predicate ::= expression IS NOT NULL */ 277, /* (311) predicate ::= expression in_op in_predicate_value */ 278, /* (312) compare_op ::= NK_LT */ 278, /* (313) compare_op ::= NK_GT */ 278, /* (314) compare_op ::= NK_LE */ 278, /* (315) compare_op ::= NK_GE */ 278, /* (316) compare_op ::= NK_NE */ 278, /* (317) compare_op ::= NK_EQ */ 278, /* (318) compare_op ::= LIKE */ 278, /* (319) compare_op ::= NOT LIKE */ 278, /* (320) compare_op ::= MATCH */ 278, /* (321) compare_op ::= NMATCH */ 279, /* (322) in_op ::= IN */ 279, /* (323) in_op ::= NOT IN */ 280, /* (324) in_predicate_value ::= NK_LP expression_list NK_RP */ 281, /* (325) boolean_value_expression ::= boolean_primary */ 281, /* (326) boolean_value_expression ::= NOT boolean_primary */ 281, /* (327) boolean_value_expression ::= boolean_value_expression OR boolean_value_expression */ 281, /* (328) boolean_value_expression ::= boolean_value_expression AND boolean_value_expression */ 282, /* (329) boolean_primary ::= predicate */ 282, /* (330) boolean_primary ::= NK_LP boolean_value_expression NK_RP */ 283, /* (331) common_expression ::= expression */ 283, /* (332) common_expression ::= boolean_value_expression */ 284, /* (333) from_clause ::= FROM table_reference_list */ 285, /* (334) table_reference_list ::= table_reference */ 285, /* (335) table_reference_list ::= table_reference_list NK_COMMA table_reference */ 286, /* (336) table_reference ::= table_primary */ 286, /* (337) table_reference ::= joined_table */ 287, /* (338) table_primary ::= table_name alias_opt */ 287, /* (339) table_primary ::= db_name NK_DOT table_name alias_opt */ 287, /* (340) table_primary ::= subquery alias_opt */ 287, /* (341) table_primary ::= parenthesized_joined_table */ 289, /* (342) alias_opt ::= */ 289, /* (343) alias_opt ::= table_alias */ 289, /* (344) alias_opt ::= AS table_alias */ 290, /* (345) parenthesized_joined_table ::= NK_LP joined_table NK_RP */ 290, /* (346) parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP */ 288, /* (347) joined_table ::= table_reference join_type JOIN table_reference ON search_condition */ 291, /* (348) join_type ::= */ 291, /* (349) join_type ::= INNER */ 293, /* (350) 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 */ 294, /* (351) set_quantifier_opt ::= */ 294, /* (352) set_quantifier_opt ::= DISTINCT */ 294, /* (353) set_quantifier_opt ::= ALL */ 295, /* (354) select_list ::= NK_STAR */ 295, /* (355) select_list ::= select_sublist */ 301, /* (356) select_sublist ::= select_item */ 301, /* (357) select_sublist ::= select_sublist NK_COMMA select_item */ 302, /* (358) select_item ::= common_expression */ 302, /* (359) select_item ::= common_expression column_alias */ 302, /* (360) select_item ::= common_expression AS column_alias */ 302, /* (361) select_item ::= table_name NK_DOT NK_STAR */ 296, /* (362) where_clause_opt ::= */ 296, /* (363) where_clause_opt ::= WHERE search_condition */ 297, /* (364) partition_by_clause_opt ::= */ 297, /* (365) partition_by_clause_opt ::= PARTITION BY expression_list */ 298, /* (366) twindow_clause_opt ::= */ 298, /* (367) twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA duration_literal NK_RP */ 298, /* (368) twindow_clause_opt ::= STATE_WINDOW NK_LP expression NK_RP */ 298, /* (369) twindow_clause_opt ::= INTERVAL NK_LP duration_literal NK_RP sliding_opt fill_opt */ 298, /* (370) twindow_clause_opt ::= INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt fill_opt */ 258, /* (371) sliding_opt ::= */ 258, /* (372) sliding_opt ::= SLIDING NK_LP duration_literal NK_RP */ 303, /* (373) fill_opt ::= */ 303, /* (374) fill_opt ::= FILL NK_LP fill_mode NK_RP */ 303, /* (375) fill_opt ::= FILL NK_LP VALUE NK_COMMA literal_list NK_RP */ 304, /* (376) fill_mode ::= NONE */ 304, /* (377) fill_mode ::= PREV */ 304, /* (378) fill_mode ::= NULL */ 304, /* (379) fill_mode ::= LINEAR */ 304, /* (380) fill_mode ::= NEXT */ 299, /* (381) group_by_clause_opt ::= */ 299, /* (382) group_by_clause_opt ::= GROUP BY group_by_list */ 305, /* (383) group_by_list ::= expression */ 305, /* (384) group_by_list ::= group_by_list NK_COMMA expression */ 300, /* (385) having_clause_opt ::= */ 300, /* (386) having_clause_opt ::= HAVING search_condition */ 262, /* (387) query_expression ::= query_expression_body order_by_clause_opt slimit_clause_opt limit_clause_opt */ 306, /* (388) query_expression_body ::= query_primary */ 306, /* (389) query_expression_body ::= query_expression_body UNION ALL query_expression_body */ 310, /* (390) query_primary ::= query_specification */ 307, /* (391) order_by_clause_opt ::= */ 307, /* (392) order_by_clause_opt ::= ORDER BY sort_specification_list */ 308, /* (393) slimit_clause_opt ::= */ 308, /* (394) slimit_clause_opt ::= SLIMIT NK_INTEGER */ 308, /* (395) slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER */ 308, /* (396) slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER */ 309, /* (397) limit_clause_opt ::= */ 309, /* (398) limit_clause_opt ::= LIMIT NK_INTEGER */ 309, /* (399) limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER */ 309, /* (400) limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER */ 276, /* (401) subquery ::= NK_LP query_expression NK_RP */ 292, /* (402) search_condition ::= common_expression */ 311, /* (403) sort_specification_list ::= sort_specification */ 311, /* (404) sort_specification_list ::= sort_specification_list NK_COMMA sort_specification */ 312, /* (405) sort_specification ::= expression ordering_specification_opt null_ordering_opt */ 313, /* (406) ordering_specification_opt ::= */ 313, /* (407) ordering_specification_opt ::= ASC */ 313, /* (408) ordering_specification_opt ::= DESC */ 314, /* (409) null_ordering_opt ::= */ 314, /* (410) null_ordering_opt ::= NULLS FIRST */ 314, /* (411) null_ordering_opt ::= NULLS LAST */ }; /* For rule J, yyRuleInfoNRhs[J] contains the negative of the number ** of symbols on the right-hand side of that rule. */ static const signed char yyRuleInfoNRhs[] = { -6, /* (0) cmd ::= CREATE ACCOUNT NK_ID PASS NK_STRING account_options */ -4, /* (1) cmd ::= ALTER ACCOUNT NK_ID alter_account_options */ 0, /* (2) account_options ::= */ -3, /* (3) account_options ::= account_options PPS literal */ -3, /* (4) account_options ::= account_options TSERIES literal */ -3, /* (5) account_options ::= account_options STORAGE literal */ -3, /* (6) account_options ::= account_options STREAMS literal */ -3, /* (7) account_options ::= account_options QTIME literal */ -3, /* (8) account_options ::= account_options DBS literal */ -3, /* (9) account_options ::= account_options USERS literal */ -3, /* (10) account_options ::= account_options CONNS literal */ -3, /* (11) account_options ::= account_options STATE literal */ -1, /* (12) alter_account_options ::= alter_account_option */ -2, /* (13) alter_account_options ::= alter_account_options alter_account_option */ -2, /* (14) alter_account_option ::= PASS literal */ -2, /* (15) alter_account_option ::= PPS literal */ -2, /* (16) alter_account_option ::= TSERIES literal */ -2, /* (17) alter_account_option ::= STORAGE literal */ -2, /* (18) alter_account_option ::= STREAMS literal */ -2, /* (19) alter_account_option ::= QTIME literal */ -2, /* (20) alter_account_option ::= DBS literal */ -2, /* (21) alter_account_option ::= USERS literal */ -2, /* (22) alter_account_option ::= CONNS literal */ -2, /* (23) alter_account_option ::= STATE literal */ -5, /* (24) cmd ::= CREATE USER user_name PASS NK_STRING */ -5, /* (25) cmd ::= ALTER USER user_name PASS NK_STRING */ -5, /* (26) cmd ::= ALTER USER user_name PRIVILEGE NK_STRING */ -3, /* (27) cmd ::= DROP USER user_name */ -3, /* (28) cmd ::= CREATE DNODE dnode_endpoint */ -5, /* (29) cmd ::= CREATE DNODE dnode_host_name PORT NK_INTEGER */ -3, /* (30) cmd ::= DROP DNODE NK_INTEGER */ -3, /* (31) cmd ::= DROP DNODE dnode_endpoint */ -4, /* (32) cmd ::= ALTER DNODE NK_INTEGER NK_STRING */ -5, /* (33) cmd ::= ALTER DNODE NK_INTEGER NK_STRING NK_STRING */ -4, /* (34) cmd ::= ALTER ALL DNODES NK_STRING */ -5, /* (35) cmd ::= ALTER ALL DNODES NK_STRING NK_STRING */ -1, /* (36) dnode_endpoint ::= NK_STRING */ -1, /* (37) dnode_host_name ::= NK_ID */ -1, /* (38) dnode_host_name ::= NK_IPTOKEN */ -3, /* (39) cmd ::= ALTER LOCAL NK_STRING */ -4, /* (40) cmd ::= ALTER LOCAL NK_STRING NK_STRING */ -5, /* (41) cmd ::= CREATE QNODE ON DNODE NK_INTEGER */ -5, /* (42) cmd ::= DROP QNODE ON DNODE NK_INTEGER */ -5, /* (43) cmd ::= CREATE BNODE ON DNODE NK_INTEGER */ -5, /* (44) cmd ::= DROP BNODE ON DNODE NK_INTEGER */ -5, /* (45) cmd ::= CREATE SNODE ON DNODE NK_INTEGER */ -5, /* (46) cmd ::= DROP SNODE ON DNODE NK_INTEGER */ -5, /* (47) cmd ::= CREATE MNODE ON DNODE NK_INTEGER */ -5, /* (48) cmd ::= DROP MNODE ON DNODE NK_INTEGER */ -5, /* (49) cmd ::= CREATE DATABASE not_exists_opt db_name db_options */ -4, /* (50) cmd ::= DROP DATABASE exists_opt db_name */ -2, /* (51) cmd ::= USE db_name */ -4, /* (52) cmd ::= ALTER DATABASE db_name alter_db_options */ -3, /* (53) not_exists_opt ::= IF NOT EXISTS */ 0, /* (54) not_exists_opt ::= */ -2, /* (55) exists_opt ::= IF EXISTS */ 0, /* (56) exists_opt ::= */ 0, /* (57) db_options ::= */ -3, /* (58) db_options ::= db_options BLOCKS NK_INTEGER */ -3, /* (59) db_options ::= db_options CACHE NK_INTEGER */ -3, /* (60) db_options ::= db_options CACHELAST NK_INTEGER */ -3, /* (61) db_options ::= db_options COMP NK_INTEGER */ -3, /* (62) db_options ::= db_options DAYS NK_INTEGER */ -3, /* (63) db_options ::= db_options DAYS NK_VARIABLE */ -3, /* (64) db_options ::= db_options FSYNC NK_INTEGER */ -3, /* (65) db_options ::= db_options MAXROWS NK_INTEGER */ -3, /* (66) db_options ::= db_options MINROWS NK_INTEGER */ -3, /* (67) db_options ::= db_options KEEP integer_list */ -3, /* (68) db_options ::= db_options KEEP variable_list */ -3, /* (69) db_options ::= db_options PRECISION NK_STRING */ -3, /* (70) db_options ::= db_options QUORUM NK_INTEGER */ -3, /* (71) db_options ::= db_options REPLICA NK_INTEGER */ -3, /* (72) db_options ::= db_options TTL NK_INTEGER */ -3, /* (73) db_options ::= db_options WAL NK_INTEGER */ -3, /* (74) db_options ::= db_options VGROUPS NK_INTEGER */ -3, /* (75) db_options ::= db_options SINGLE_STABLE NK_INTEGER */ -3, /* (76) db_options ::= db_options STREAM_MODE NK_INTEGER */ -3, /* (77) db_options ::= db_options RETENTIONS retention_list */ -1, /* (78) alter_db_options ::= alter_db_option */ -2, /* (79) alter_db_options ::= alter_db_options alter_db_option */ -2, /* (80) alter_db_option ::= BLOCKS NK_INTEGER */ -2, /* (81) alter_db_option ::= FSYNC NK_INTEGER */ -2, /* (82) alter_db_option ::= KEEP integer_list */ -2, /* (83) alter_db_option ::= KEEP variable_list */ -2, /* (84) alter_db_option ::= WAL NK_INTEGER */ -2, /* (85) alter_db_option ::= QUORUM NK_INTEGER */ -2, /* (86) alter_db_option ::= CACHELAST NK_INTEGER */ -2, /* (87) alter_db_option ::= REPLICA NK_INTEGER */ -1, /* (88) integer_list ::= NK_INTEGER */ -3, /* (89) integer_list ::= integer_list NK_COMMA NK_INTEGER */ -1, /* (90) variable_list ::= NK_VARIABLE */ -3, /* (91) variable_list ::= variable_list NK_COMMA NK_VARIABLE */ -1, /* (92) retention_list ::= retention */ -3, /* (93) retention_list ::= retention_list NK_COMMA retention */ -3, /* (94) retention ::= NK_VARIABLE NK_COLON NK_VARIABLE */ -9, /* (95) cmd ::= CREATE TABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def_opt table_options */ -3, /* (96) cmd ::= CREATE TABLE multi_create_clause */ -9, /* (97) cmd ::= CREATE STABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def table_options */ -3, /* (98) cmd ::= DROP TABLE multi_drop_clause */ -4, /* (99) cmd ::= DROP STABLE exists_opt full_table_name */ -3, /* (100) cmd ::= ALTER TABLE alter_table_clause */ -3, /* (101) cmd ::= ALTER STABLE alter_table_clause */ -2, /* (102) alter_table_clause ::= full_table_name alter_table_options */ -5, /* (103) alter_table_clause ::= full_table_name ADD COLUMN column_name type_name */ -4, /* (104) alter_table_clause ::= full_table_name DROP COLUMN column_name */ -5, /* (105) alter_table_clause ::= full_table_name MODIFY COLUMN column_name type_name */ -5, /* (106) alter_table_clause ::= full_table_name RENAME COLUMN column_name column_name */ -5, /* (107) alter_table_clause ::= full_table_name ADD TAG column_name type_name */ -4, /* (108) alter_table_clause ::= full_table_name DROP TAG column_name */ -5, /* (109) alter_table_clause ::= full_table_name MODIFY TAG column_name type_name */ -5, /* (110) alter_table_clause ::= full_table_name RENAME TAG column_name column_name */ -6, /* (111) alter_table_clause ::= full_table_name SET TAG column_name NK_EQ literal */ -1, /* (112) multi_create_clause ::= create_subtable_clause */ -2, /* (113) multi_create_clause ::= multi_create_clause create_subtable_clause */ -9, /* (114) create_subtable_clause ::= not_exists_opt full_table_name USING full_table_name specific_tags_opt TAGS NK_LP literal_list NK_RP */ -1, /* (115) multi_drop_clause ::= drop_table_clause */ -2, /* (116) multi_drop_clause ::= multi_drop_clause drop_table_clause */ -2, /* (117) drop_table_clause ::= exists_opt full_table_name */ 0, /* (118) specific_tags_opt ::= */ -3, /* (119) specific_tags_opt ::= NK_LP col_name_list NK_RP */ -1, /* (120) full_table_name ::= table_name */ -3, /* (121) full_table_name ::= db_name NK_DOT table_name */ -1, /* (122) column_def_list ::= column_def */ -3, /* (123) column_def_list ::= column_def_list NK_COMMA column_def */ -2, /* (124) column_def ::= column_name type_name */ -4, /* (125) column_def ::= column_name type_name COMMENT NK_STRING */ -1, /* (126) type_name ::= BOOL */ -1, /* (127) type_name ::= TINYINT */ -1, /* (128) type_name ::= SMALLINT */ -1, /* (129) type_name ::= INT */ -1, /* (130) type_name ::= INTEGER */ -1, /* (131) type_name ::= BIGINT */ -1, /* (132) type_name ::= FLOAT */ -1, /* (133) type_name ::= DOUBLE */ -4, /* (134) type_name ::= BINARY NK_LP NK_INTEGER NK_RP */ -1, /* (135) type_name ::= TIMESTAMP */ -4, /* (136) type_name ::= NCHAR NK_LP NK_INTEGER NK_RP */ -2, /* (137) type_name ::= TINYINT UNSIGNED */ -2, /* (138) type_name ::= SMALLINT UNSIGNED */ -2, /* (139) type_name ::= INT UNSIGNED */ -2, /* (140) type_name ::= BIGINT UNSIGNED */ -1, /* (141) type_name ::= JSON */ -4, /* (142) type_name ::= VARCHAR NK_LP NK_INTEGER NK_RP */ -1, /* (143) type_name ::= MEDIUMBLOB */ -1, /* (144) type_name ::= BLOB */ -4, /* (145) type_name ::= VARBINARY NK_LP NK_INTEGER NK_RP */ -1, /* (146) type_name ::= DECIMAL */ -4, /* (147) type_name ::= DECIMAL NK_LP NK_INTEGER NK_RP */ -6, /* (148) type_name ::= DECIMAL NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP */ 0, /* (149) tags_def_opt ::= */ -1, /* (150) tags_def_opt ::= tags_def */ -4, /* (151) tags_def ::= TAGS NK_LP column_def_list NK_RP */ 0, /* (152) table_options ::= */ -3, /* (153) table_options ::= table_options COMMENT NK_STRING */ -3, /* (154) table_options ::= table_options KEEP integer_list */ -3, /* (155) table_options ::= table_options TTL NK_INTEGER */ -5, /* (156) table_options ::= table_options SMA NK_LP col_name_list NK_RP */ -5, /* (157) table_options ::= table_options ROLLUP NK_LP func_name_list NK_RP */ -3, /* (158) table_options ::= table_options FILE_FACTOR NK_FLOAT */ -3, /* (159) table_options ::= table_options DELAY NK_INTEGER */ -1, /* (160) alter_table_options ::= alter_table_option */ -2, /* (161) alter_table_options ::= alter_table_options alter_table_option */ -2, /* (162) alter_table_option ::= COMMENT NK_STRING */ -2, /* (163) alter_table_option ::= KEEP integer_list */ -2, /* (164) alter_table_option ::= TTL NK_INTEGER */ -1, /* (165) col_name_list ::= col_name */ -3, /* (166) col_name_list ::= col_name_list NK_COMMA col_name */ -1, /* (167) col_name ::= column_name */ -2, /* (168) cmd ::= SHOW DNODES */ -2, /* (169) cmd ::= SHOW USERS */ -2, /* (170) cmd ::= SHOW DATABASES */ -4, /* (171) cmd ::= SHOW db_name_cond_opt TABLES like_pattern_opt */ -4, /* (172) cmd ::= SHOW db_name_cond_opt STABLES like_pattern_opt */ -3, /* (173) cmd ::= SHOW db_name_cond_opt VGROUPS */ -2, /* (174) cmd ::= SHOW MNODES */ -2, /* (175) cmd ::= SHOW MODULES */ -2, /* (176) cmd ::= SHOW QNODES */ -2, /* (177) cmd ::= SHOW FUNCTIONS */ -5, /* (178) cmd ::= SHOW INDEXES FROM table_name_cond from_db_opt */ -2, /* (179) cmd ::= SHOW STREAMS */ -2, /* (180) cmd ::= SHOW ACCOUNTS */ -2, /* (181) cmd ::= SHOW APPS */ -2, /* (182) cmd ::= SHOW CONNECTIONS */ -2, /* (183) cmd ::= SHOW LICENCE */ -2, /* (184) cmd ::= SHOW GRANTS */ -4, /* (185) cmd ::= SHOW CREATE DATABASE db_name */ -4, /* (186) cmd ::= SHOW CREATE TABLE full_table_name */ -4, /* (187) cmd ::= SHOW CREATE STABLE full_table_name */ -2, /* (188) cmd ::= SHOW QUERIES */ -2, /* (189) cmd ::= SHOW SCORES */ -2, /* (190) cmd ::= SHOW TOPICS */ -2, /* (191) cmd ::= SHOW VARIABLES */ -2, /* (192) cmd ::= SHOW BNODES */ -2, /* (193) cmd ::= SHOW SNODES */ 0, /* (194) db_name_cond_opt ::= */ -2, /* (195) db_name_cond_opt ::= db_name NK_DOT */ 0, /* (196) like_pattern_opt ::= */ -2, /* (197) like_pattern_opt ::= LIKE NK_STRING */ -1, /* (198) table_name_cond ::= table_name */ 0, /* (199) from_db_opt ::= */ -2, /* (200) from_db_opt ::= FROM db_name */ -1, /* (201) func_name_list ::= func_name */ -3, /* (202) func_name_list ::= func_name_list NK_COMMA col_name */ -1, /* (203) func_name ::= function_name */ -8, /* (204) cmd ::= CREATE SMA INDEX not_exists_opt index_name ON table_name index_options */ -10, /* (205) cmd ::= CREATE FULLTEXT INDEX not_exists_opt index_name ON table_name NK_LP col_name_list NK_RP */ -6, /* (206) cmd ::= DROP INDEX exists_opt index_name ON table_name */ 0, /* (207) index_options ::= */ -9, /* (208) index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_RP sliding_opt */ -11, /* (209) index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt */ -1, /* (210) func_list ::= func */ -3, /* (211) func_list ::= func_list NK_COMMA func */ -4, /* (212) func ::= function_name NK_LP expression_list NK_RP */ -6, /* (213) cmd ::= CREATE TOPIC not_exists_opt topic_name AS query_expression */ -6, /* (214) cmd ::= CREATE TOPIC not_exists_opt topic_name AS db_name */ -4, /* (215) cmd ::= DROP TOPIC exists_opt topic_name */ -2, /* (216) cmd ::= DESC full_table_name */ -2, /* (217) cmd ::= DESCRIBE full_table_name */ -3, /* (218) cmd ::= RESET QUERY CACHE */ -4, /* (219) cmd ::= EXPLAIN analyze_opt explain_options query_expression */ 0, /* (220) analyze_opt ::= */ -1, /* (221) analyze_opt ::= ANALYZE */ 0, /* (222) explain_options ::= */ -3, /* (223) explain_options ::= explain_options VERBOSE NK_BOOL */ -3, /* (224) explain_options ::= explain_options RATIO NK_FLOAT */ -6, /* (225) cmd ::= COMPACT VNODES IN NK_LP integer_list NK_RP */ -9, /* (226) cmd ::= CREATE agg_func_opt FUNCTION function_name AS NK_STRING OUTPUTTYPE type_name bufsize_opt */ -3, /* (227) cmd ::= DROP FUNCTION function_name */ 0, /* (228) agg_func_opt ::= */ -1, /* (229) agg_func_opt ::= AGGREGATE */ 0, /* (230) bufsize_opt ::= */ -2, /* (231) bufsize_opt ::= BUFSIZE NK_INTEGER */ -7, /* (232) cmd ::= CREATE STREAM stream_name INTO table_name AS query_expression */ -3, /* (233) cmd ::= DROP STREAM stream_name */ -3, /* (234) cmd ::= KILL CONNECTION NK_INTEGER */ -3, /* (235) cmd ::= KILL QUERY NK_INTEGER */ -4, /* (236) cmd ::= MERGE VGROUP NK_INTEGER NK_INTEGER */ -4, /* (237) cmd ::= REDISTRIBUTE VGROUP NK_INTEGER dnode_list */ -3, /* (238) cmd ::= SPLIT VGROUP NK_INTEGER */ -2, /* (239) dnode_list ::= DNODE NK_INTEGER */ -3, /* (240) dnode_list ::= dnode_list DNODE NK_INTEGER */ -3, /* (241) cmd ::= SYNCDB db_name REPLICA */ -1, /* (242) cmd ::= query_expression */ -1, /* (243) literal ::= NK_INTEGER */ -1, /* (244) literal ::= NK_FLOAT */ -1, /* (245) literal ::= NK_STRING */ -1, /* (246) literal ::= NK_BOOL */ -2, /* (247) literal ::= TIMESTAMP NK_STRING */ -1, /* (248) literal ::= duration_literal */ -1, /* (249) literal ::= NULL */ -1, /* (250) duration_literal ::= NK_VARIABLE */ -1, /* (251) signed ::= NK_INTEGER */ -2, /* (252) signed ::= NK_PLUS NK_INTEGER */ -2, /* (253) signed ::= NK_MINUS NK_INTEGER */ -1, /* (254) signed ::= NK_FLOAT */ -2, /* (255) signed ::= NK_PLUS NK_FLOAT */ -2, /* (256) signed ::= NK_MINUS NK_FLOAT */ -1, /* (257) signed_literal ::= signed */ -1, /* (258) signed_literal ::= NK_STRING */ -1, /* (259) signed_literal ::= NK_BOOL */ -2, /* (260) signed_literal ::= TIMESTAMP NK_STRING */ -1, /* (261) signed_literal ::= duration_literal */ -1, /* (262) signed_literal ::= NULL */ -1, /* (263) literal_list ::= signed_literal */ -3, /* (264) literal_list ::= literal_list NK_COMMA signed_literal */ -1, /* (265) db_name ::= NK_ID */ -1, /* (266) table_name ::= NK_ID */ -1, /* (267) column_name ::= NK_ID */ -1, /* (268) function_name ::= NK_ID */ -1, /* (269) function_name ::= FIRST */ -1, /* (270) function_name ::= LAST */ -1, /* (271) function_name ::= NOW */ -1, /* (272) function_name ::= TODAY */ -1, /* (273) table_alias ::= NK_ID */ -1, /* (274) column_alias ::= NK_ID */ -1, /* (275) user_name ::= NK_ID */ -1, /* (276) index_name ::= NK_ID */ -1, /* (277) topic_name ::= NK_ID */ -1, /* (278) stream_name ::= NK_ID */ -1, /* (279) expression ::= literal */ -1, /* (280) expression ::= pseudo_column */ -1, /* (281) expression ::= column_reference */ -4, /* (282) expression ::= function_name NK_LP expression_list NK_RP */ -4, /* (283) expression ::= function_name NK_LP NK_STAR NK_RP */ -3, /* (284) expression ::= function_name NK_LP NK_RP */ -6, /* (285) expression ::= function_name NK_LP expression AS type_name NK_RP */ -1, /* (286) expression ::= subquery */ -3, /* (287) expression ::= NK_LP expression NK_RP */ -2, /* (288) expression ::= NK_PLUS expression */ -2, /* (289) expression ::= NK_MINUS expression */ -3, /* (290) expression ::= expression NK_PLUS expression */ -3, /* (291) expression ::= expression NK_MINUS expression */ -3, /* (292) expression ::= expression NK_STAR expression */ -3, /* (293) expression ::= expression NK_SLASH expression */ -3, /* (294) expression ::= expression NK_REM expression */ -1, /* (295) expression_list ::= expression */ -3, /* (296) expression_list ::= expression_list NK_COMMA expression */ -1, /* (297) column_reference ::= column_name */ -3, /* (298) column_reference ::= table_name NK_DOT column_name */ -1, /* (299) pseudo_column ::= ROWTS */ -1, /* (300) pseudo_column ::= TBNAME */ -1, /* (301) pseudo_column ::= QSTARTTS */ -1, /* (302) pseudo_column ::= QENDTS */ -1, /* (303) pseudo_column ::= WSTARTTS */ -1, /* (304) pseudo_column ::= WENDTS */ -1, /* (305) pseudo_column ::= WDURATION */ -3, /* (306) predicate ::= expression compare_op expression */ -5, /* (307) predicate ::= expression BETWEEN expression AND expression */ -6, /* (308) predicate ::= expression NOT BETWEEN expression AND expression */ -3, /* (309) predicate ::= expression IS NULL */ -4, /* (310) predicate ::= expression IS NOT NULL */ -3, /* (311) predicate ::= expression in_op in_predicate_value */ -1, /* (312) compare_op ::= NK_LT */ -1, /* (313) compare_op ::= NK_GT */ -1, /* (314) compare_op ::= NK_LE */ -1, /* (315) compare_op ::= NK_GE */ -1, /* (316) compare_op ::= NK_NE */ -1, /* (317) compare_op ::= NK_EQ */ -1, /* (318) compare_op ::= LIKE */ -2, /* (319) compare_op ::= NOT LIKE */ -1, /* (320) compare_op ::= MATCH */ -1, /* (321) compare_op ::= NMATCH */ -1, /* (322) in_op ::= IN */ -2, /* (323) in_op ::= NOT IN */ -3, /* (324) in_predicate_value ::= NK_LP expression_list NK_RP */ -1, /* (325) boolean_value_expression ::= boolean_primary */ -2, /* (326) boolean_value_expression ::= NOT boolean_primary */ -3, /* (327) boolean_value_expression ::= boolean_value_expression OR boolean_value_expression */ -3, /* (328) boolean_value_expression ::= boolean_value_expression AND boolean_value_expression */ -1, /* (329) boolean_primary ::= predicate */ -3, /* (330) boolean_primary ::= NK_LP boolean_value_expression NK_RP */ -1, /* (331) common_expression ::= expression */ -1, /* (332) common_expression ::= boolean_value_expression */ -2, /* (333) from_clause ::= FROM table_reference_list */ -1, /* (334) table_reference_list ::= table_reference */ -3, /* (335) table_reference_list ::= table_reference_list NK_COMMA table_reference */ -1, /* (336) table_reference ::= table_primary */ -1, /* (337) table_reference ::= joined_table */ -2, /* (338) table_primary ::= table_name alias_opt */ -4, /* (339) table_primary ::= db_name NK_DOT table_name alias_opt */ -2, /* (340) table_primary ::= subquery alias_opt */ -1, /* (341) table_primary ::= parenthesized_joined_table */ 0, /* (342) alias_opt ::= */ -1, /* (343) alias_opt ::= table_alias */ -2, /* (344) alias_opt ::= AS table_alias */ -3, /* (345) parenthesized_joined_table ::= NK_LP joined_table NK_RP */ -3, /* (346) parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP */ -6, /* (347) joined_table ::= table_reference join_type JOIN table_reference ON search_condition */ 0, /* (348) join_type ::= */ -1, /* (349) join_type ::= INNER */ -9, /* (350) 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 */ 0, /* (351) set_quantifier_opt ::= */ -1, /* (352) set_quantifier_opt ::= DISTINCT */ -1, /* (353) set_quantifier_opt ::= ALL */ -1, /* (354) select_list ::= NK_STAR */ -1, /* (355) select_list ::= select_sublist */ -1, /* (356) select_sublist ::= select_item */ -3, /* (357) select_sublist ::= select_sublist NK_COMMA select_item */ -1, /* (358) select_item ::= common_expression */ -2, /* (359) select_item ::= common_expression column_alias */ -3, /* (360) select_item ::= common_expression AS column_alias */ -3, /* (361) select_item ::= table_name NK_DOT NK_STAR */ 0, /* (362) where_clause_opt ::= */ -2, /* (363) where_clause_opt ::= WHERE search_condition */ 0, /* (364) partition_by_clause_opt ::= */ -3, /* (365) partition_by_clause_opt ::= PARTITION BY expression_list */ 0, /* (366) twindow_clause_opt ::= */ -6, /* (367) twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA duration_literal NK_RP */ -4, /* (368) twindow_clause_opt ::= STATE_WINDOW NK_LP expression NK_RP */ -6, /* (369) twindow_clause_opt ::= INTERVAL NK_LP duration_literal NK_RP sliding_opt fill_opt */ -8, /* (370) twindow_clause_opt ::= INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt fill_opt */ 0, /* (371) sliding_opt ::= */ -4, /* (372) sliding_opt ::= SLIDING NK_LP duration_literal NK_RP */ 0, /* (373) fill_opt ::= */ -4, /* (374) fill_opt ::= FILL NK_LP fill_mode NK_RP */ -6, /* (375) fill_opt ::= FILL NK_LP VALUE NK_COMMA literal_list NK_RP */ -1, /* (376) fill_mode ::= NONE */ -1, /* (377) fill_mode ::= PREV */ -1, /* (378) fill_mode ::= NULL */ -1, /* (379) fill_mode ::= LINEAR */ -1, /* (380) fill_mode ::= NEXT */ 0, /* (381) group_by_clause_opt ::= */ -3, /* (382) group_by_clause_opt ::= GROUP BY group_by_list */ -1, /* (383) group_by_list ::= expression */ -3, /* (384) group_by_list ::= group_by_list NK_COMMA expression */ 0, /* (385) having_clause_opt ::= */ -2, /* (386) having_clause_opt ::= HAVING search_condition */ -4, /* (387) query_expression ::= query_expression_body order_by_clause_opt slimit_clause_opt limit_clause_opt */ -1, /* (388) query_expression_body ::= query_primary */ -4, /* (389) query_expression_body ::= query_expression_body UNION ALL query_expression_body */ -1, /* (390) query_primary ::= query_specification */ 0, /* (391) order_by_clause_opt ::= */ -3, /* (392) order_by_clause_opt ::= ORDER BY sort_specification_list */ 0, /* (393) slimit_clause_opt ::= */ -2, /* (394) slimit_clause_opt ::= SLIMIT NK_INTEGER */ -4, /* (395) slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER */ -4, /* (396) slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER */ 0, /* (397) limit_clause_opt ::= */ -2, /* (398) limit_clause_opt ::= LIMIT NK_INTEGER */ -4, /* (399) limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER */ -4, /* (400) limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER */ -3, /* (401) subquery ::= NK_LP query_expression NK_RP */ -1, /* (402) search_condition ::= common_expression */ -1, /* (403) sort_specification_list ::= sort_specification */ -3, /* (404) sort_specification_list ::= sort_specification_list NK_COMMA sort_specification */ -3, /* (405) sort_specification ::= expression ordering_specification_opt null_ordering_opt */ 0, /* (406) ordering_specification_opt ::= */ -1, /* (407) ordering_specification_opt ::= ASC */ -1, /* (408) ordering_specification_opt ::= DESC */ 0, /* (409) null_ordering_opt ::= */ -2, /* (410) null_ordering_opt ::= NULLS FIRST */ -2, /* (411) null_ordering_opt ::= NULLS LAST */ }; static void yy_accept(yyParser*); /* Forward Declaration */ /* ** Perform a reduce action and the shift that must immediately ** follow the reduce. ** ** The yyLookahead and yyLookaheadToken parameters provide reduce actions ** access to the lookahead token (if any). The yyLookahead will be YYNOCODE ** if the lookahead token has already been consumed. As this procedure is ** only called from one place, optimizing compilers will in-line it, which ** means that the extra parameters have no performance impact. */ static YYACTIONTYPE yy_reduce( yyParser *yypParser, /* The parser */ unsigned int yyruleno, /* Number of the rule by which to reduce */ int yyLookahead, /* Lookahead token, or YYNOCODE if none */ ParseTOKENTYPE yyLookaheadToken /* Value of the lookahead token */ ParseCTX_PDECL /* %extra_context */ ){ int yygoto; /* The next state */ YYACTIONTYPE yyact; /* The next action */ yyStackEntry *yymsp; /* The top of the parser's stack */ int yysize; /* Amount to pop the stack */ ParseARG_FETCH (void)yyLookahead; (void)yyLookaheadToken; yymsp = yypParser->yytos; #ifndef NDEBUG if( yyTraceFILE && yyruleno<(int)(sizeof(yyRuleName)/sizeof(yyRuleName[0])) ){ yysize = yyRuleInfoNRhs[yyruleno]; if( yysize ){ fprintf(yyTraceFILE, "%sReduce %d [%s]%s, pop back to state %d.\n", yyTracePrompt, yyruleno, yyRuleName[yyruleno], yyrulenoyytos - yypParser->yystack)>yypParser->yyhwm ){ yypParser->yyhwm++; assert( yypParser->yyhwm == (int)(yypParser->yytos - yypParser->yystack)); } #endif #if YYSTACKDEPTH>0 if( yypParser->yytos>=yypParser->yystackEnd ){ yyStackOverflow(yypParser); /* The call to yyStackOverflow() above pops the stack until it is ** empty, causing the main parser loop to exit. So the return value ** is never used and does not matter. */ return 0; } #else if( yypParser->yytos>=&yypParser->yystack[yypParser->yystksz-1] ){ if( yyGrowStack(yypParser) ){ yyStackOverflow(yypParser); /* The call to yyStackOverflow() above pops the stack until it is ** empty, causing the main parser loop to exit. So the return value ** is never used and does not matter. */ return 0; } yymsp = yypParser->yytos; } #endif } switch( yyruleno ){ /* Beginning here are the reduction cases. A typical example ** follows: ** case 0: ** #line ** { ... } // User supplied code ** #line ** break; */ /********** Begin reduce actions **********************************************/ 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,210,&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,211,&yymsp[0].minor); break; case 2: /* account_options ::= */ { } break; case 3: /* account_options ::= account_options PPS literal */ case 4: /* account_options ::= account_options TSERIES literal */ yytestcase(yyruleno==4); case 5: /* account_options ::= account_options STORAGE literal */ yytestcase(yyruleno==5); case 6: /* account_options ::= account_options STREAMS literal */ yytestcase(yyruleno==6); case 7: /* account_options ::= account_options QTIME literal */ yytestcase(yyruleno==7); case 8: /* account_options ::= account_options DBS literal */ yytestcase(yyruleno==8); 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,210,&yymsp[-2].minor); { } yy_destructor(yypParser,212,&yymsp[0].minor); } break; case 12: /* alter_account_options ::= alter_account_option */ { yy_destructor(yypParser,213,&yymsp[0].minor); { } } break; case 13: /* alter_account_options ::= alter_account_options alter_account_option */ { yy_destructor(yypParser,211,&yymsp[-1].minor); { } yy_destructor(yypParser,213,&yymsp[0].minor); } break; case 14: /* alter_account_option ::= PASS literal */ case 15: /* alter_account_option ::= PPS literal */ yytestcase(yyruleno==15); case 16: /* alter_account_option ::= TSERIES literal */ yytestcase(yyruleno==16); case 17: /* alter_account_option ::= STORAGE literal */ yytestcase(yyruleno==17); case 18: /* alter_account_option ::= STREAMS literal */ yytestcase(yyruleno==18); case 19: /* alter_account_option ::= QTIME literal */ yytestcase(yyruleno==19); case 20: /* alter_account_option ::= DBS literal */ yytestcase(yyruleno==20); case 21: /* alter_account_option ::= USERS literal */ yytestcase(yyruleno==21); case 22: /* alter_account_option ::= CONNS literal */ yytestcase(yyruleno==22); case 23: /* alter_account_option ::= STATE literal */ yytestcase(yyruleno==23); { } yy_destructor(yypParser,212,&yymsp[0].minor); break; case 24: /* cmd ::= CREATE USER user_name PASS NK_STRING */ { pCxt->pRootNode = createCreateUserStmt(pCxt, &yymsp[-2].minor.yy29, &yymsp[0].minor.yy0); } break; case 25: /* cmd ::= ALTER USER user_name PASS NK_STRING */ { pCxt->pRootNode = createAlterUserStmt(pCxt, &yymsp[-2].minor.yy29, 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.yy29, TSDB_ALTER_USER_PRIVILEGES, &yymsp[0].minor.yy0); } break; case 27: /* cmd ::= DROP USER user_name */ { pCxt->pRootNode = createDropUserStmt(pCxt, &yymsp[0].minor.yy29); } break; case 28: /* cmd ::= CREATE DNODE dnode_endpoint */ { pCxt->pRootNode = createCreateDnodeStmt(pCxt, &yymsp[0].minor.yy29, NULL); } break; case 29: /* cmd ::= CREATE DNODE dnode_host_name PORT NK_INTEGER */ { pCxt->pRootNode = createCreateDnodeStmt(pCxt, &yymsp[-2].minor.yy29, &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.yy29); } break; case 32: /* cmd ::= ALTER DNODE NK_INTEGER NK_STRING */ { pCxt->pRootNode = createAlterDnodeStmt(pCxt, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0, NULL); } break; case 33: /* cmd ::= ALTER DNODE NK_INTEGER NK_STRING NK_STRING */ { pCxt->pRootNode = createAlterDnodeStmt(pCxt, &yymsp[-2].minor.yy0, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0); } break; case 34: /* cmd ::= ALTER ALL DNODES NK_STRING */ { pCxt->pRootNode = createAlterDnodeStmt(pCxt, NULL, &yymsp[0].minor.yy0, NULL); } break; case 35: /* cmd ::= ALTER ALL DNODES NK_STRING NK_STRING */ { pCxt->pRootNode = createAlterDnodeStmt(pCxt, NULL, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0); } break; 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 265: /* db_name ::= NK_ID */ yytestcase(yyruleno==265); case 266: /* table_name ::= NK_ID */ yytestcase(yyruleno==266); case 267: /* column_name ::= NK_ID */ yytestcase(yyruleno==267); case 268: /* function_name ::= NK_ID */ yytestcase(yyruleno==268); case 269: /* function_name ::= FIRST */ yytestcase(yyruleno==269); case 270: /* function_name ::= LAST */ yytestcase(yyruleno==270); case 271: /* function_name ::= NOW */ yytestcase(yyruleno==271); case 272: /* function_name ::= TODAY */ yytestcase(yyruleno==272); case 273: /* table_alias ::= NK_ID */ yytestcase(yyruleno==273); case 274: /* column_alias ::= NK_ID */ yytestcase(yyruleno==274); case 275: /* user_name ::= NK_ID */ yytestcase(yyruleno==275); case 276: /* index_name ::= NK_ID */ yytestcase(yyruleno==276); case 277: /* topic_name ::= NK_ID */ yytestcase(yyruleno==277); case 278: /* stream_name ::= NK_ID */ yytestcase(yyruleno==278); { yylhsminor.yy29 = yymsp[0].minor.yy0; } yymsp[0].minor.yy29 = yylhsminor.yy29; break; case 39: /* cmd ::= ALTER LOCAL NK_STRING */ { pCxt->pRootNode = createAlterLocalStmt(pCxt, &yymsp[0].minor.yy0, NULL); } break; case 40: /* cmd ::= ALTER LOCAL NK_STRING NK_STRING */ { pCxt->pRootNode = createAlterLocalStmt(pCxt, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0); } break; case 41: /* cmd ::= CREATE QNODE ON DNODE NK_INTEGER */ { pCxt->pRootNode = createCreateComponentNodeStmt(pCxt, QUERY_NODE_CREATE_QNODE_STMT, &yymsp[0].minor.yy0); } break; case 42: /* cmd ::= DROP QNODE ON DNODE NK_INTEGER */ { pCxt->pRootNode = createDropComponentNodeStmt(pCxt, QUERY_NODE_DROP_QNODE_STMT, &yymsp[0].minor.yy0); } break; case 43: /* cmd ::= CREATE BNODE ON DNODE NK_INTEGER */ { pCxt->pRootNode = createCreateComponentNodeStmt(pCxt, QUERY_NODE_CREATE_BNODE_STMT, &yymsp[0].minor.yy0); } break; case 44: /* cmd ::= DROP BNODE ON DNODE NK_INTEGER */ { pCxt->pRootNode = createDropComponentNodeStmt(pCxt, QUERY_NODE_DROP_BNODE_STMT, &yymsp[0].minor.yy0); } break; case 45: /* cmd ::= CREATE SNODE ON DNODE NK_INTEGER */ { pCxt->pRootNode = createCreateComponentNodeStmt(pCxt, QUERY_NODE_CREATE_SNODE_STMT, &yymsp[0].minor.yy0); } break; case 46: /* cmd ::= DROP SNODE ON DNODE NK_INTEGER */ { pCxt->pRootNode = createDropComponentNodeStmt(pCxt, QUERY_NODE_DROP_SNODE_STMT, &yymsp[0].minor.yy0); } break; case 47: /* cmd ::= CREATE MNODE ON DNODE NK_INTEGER */ { pCxt->pRootNode = createCreateComponentNodeStmt(pCxt, QUERY_NODE_CREATE_MNODE_STMT, &yymsp[0].minor.yy0); } break; case 48: /* cmd ::= DROP MNODE ON DNODE NK_INTEGER */ { pCxt->pRootNode = createDropComponentNodeStmt(pCxt, QUERY_NODE_DROP_MNODE_STMT, &yymsp[0].minor.yy0); } break; case 49: /* cmd ::= CREATE DATABASE not_exists_opt db_name db_options */ { pCxt->pRootNode = createCreateDatabaseStmt(pCxt, yymsp[-2].minor.yy47, &yymsp[-1].minor.yy29, yymsp[0].minor.yy182); } break; case 50: /* cmd ::= DROP DATABASE exists_opt db_name */ { pCxt->pRootNode = createDropDatabaseStmt(pCxt, yymsp[-1].minor.yy47, &yymsp[0].minor.yy29); } break; case 51: /* cmd ::= USE db_name */ { pCxt->pRootNode = createUseDatabaseStmt(pCxt, &yymsp[0].minor.yy29); } break; case 52: /* cmd ::= ALTER DATABASE db_name alter_db_options */ { pCxt->pRootNode = createAlterDatabaseStmt(pCxt, &yymsp[-1].minor.yy29, yymsp[0].minor.yy182); } break; case 53: /* not_exists_opt ::= IF NOT EXISTS */ { yymsp[-2].minor.yy47 = true; } break; case 54: /* not_exists_opt ::= */ case 56: /* exists_opt ::= */ yytestcase(yyruleno==56); case 220: /* analyze_opt ::= */ yytestcase(yyruleno==220); case 228: /* agg_func_opt ::= */ yytestcase(yyruleno==228); case 351: /* set_quantifier_opt ::= */ yytestcase(yyruleno==351); { yymsp[1].minor.yy47 = false; } break; case 55: /* exists_opt ::= IF EXISTS */ { yymsp[-1].minor.yy47 = true; } break; case 57: /* db_options ::= */ { yymsp[1].minor.yy182 = createDatabaseOptions(pCxt); } break; case 58: /* db_options ::= db_options BLOCKS NK_INTEGER */ { ((SDatabaseOptions*)yymsp[-2].minor.yy182)->pNumOfBlocks = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); yylhsminor.yy182 = yymsp[-2].minor.yy182; } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 59: /* db_options ::= db_options CACHE NK_INTEGER */ { ((SDatabaseOptions*)yymsp[-2].minor.yy182)->pCacheBlockSize = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); yylhsminor.yy182 = yymsp[-2].minor.yy182; } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 60: /* db_options ::= db_options CACHELAST NK_INTEGER */ { ((SDatabaseOptions*)yymsp[-2].minor.yy182)->pCachelast = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); yylhsminor.yy182 = yymsp[-2].minor.yy182; } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 61: /* db_options ::= db_options COMP NK_INTEGER */ { ((SDatabaseOptions*)yymsp[-2].minor.yy182)->pCompressionLevel = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); yylhsminor.yy182 = yymsp[-2].minor.yy182; } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 62: /* db_options ::= db_options DAYS NK_INTEGER */ { ((SDatabaseOptions*)yymsp[-2].minor.yy182)->pDaysPerFile = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); yylhsminor.yy182 = yymsp[-2].minor.yy182; } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 63: /* db_options ::= db_options DAYS NK_VARIABLE */ { ((SDatabaseOptions*)yymsp[-2].minor.yy182)->pDaysPerFile = (SValueNode*)createDurationValueNode(pCxt, &yymsp[0].minor.yy0); yylhsminor.yy182 = yymsp[-2].minor.yy182; } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 64: /* db_options ::= db_options FSYNC NK_INTEGER */ { ((SDatabaseOptions*)yymsp[-2].minor.yy182)->pFsyncPeriod = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); yylhsminor.yy182 = yymsp[-2].minor.yy182; } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 65: /* db_options ::= db_options MAXROWS NK_INTEGER */ { ((SDatabaseOptions*)yymsp[-2].minor.yy182)->pMaxRowsPerBlock = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); yylhsminor.yy182 = yymsp[-2].minor.yy182; } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 66: /* db_options ::= db_options MINROWS NK_INTEGER */ { ((SDatabaseOptions*)yymsp[-2].minor.yy182)->pMinRowsPerBlock = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); yylhsminor.yy182 = yymsp[-2].minor.yy182; } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 67: /* db_options ::= db_options KEEP integer_list */ case 68: /* db_options ::= db_options KEEP variable_list */ yytestcase(yyruleno==68); { ((SDatabaseOptions*)yymsp[-2].minor.yy182)->pKeep = yymsp[0].minor.yy334; yylhsminor.yy182 = yymsp[-2].minor.yy182; } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 69: /* db_options ::= db_options PRECISION NK_STRING */ { ((SDatabaseOptions*)yymsp[-2].minor.yy182)->pPrecision = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0); yylhsminor.yy182 = yymsp[-2].minor.yy182; } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 70: /* db_options ::= db_options QUORUM NK_INTEGER */ { ((SDatabaseOptions*)yymsp[-2].minor.yy182)->pQuorum = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); yylhsminor.yy182 = yymsp[-2].minor.yy182; } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 71: /* db_options ::= db_options REPLICA NK_INTEGER */ { ((SDatabaseOptions*)yymsp[-2].minor.yy182)->pReplica = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); yylhsminor.yy182 = yymsp[-2].minor.yy182; } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 72: /* db_options ::= db_options TTL NK_INTEGER */ { ((SDatabaseOptions*)yymsp[-2].minor.yy182)->pTtl = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); yylhsminor.yy182 = yymsp[-2].minor.yy182; } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 73: /* db_options ::= db_options WAL NK_INTEGER */ { ((SDatabaseOptions*)yymsp[-2].minor.yy182)->pWalLevel = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); yylhsminor.yy182 = yymsp[-2].minor.yy182; } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 74: /* db_options ::= db_options VGROUPS NK_INTEGER */ { ((SDatabaseOptions*)yymsp[-2].minor.yy182)->pNumOfVgroups = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); yylhsminor.yy182 = yymsp[-2].minor.yy182; } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 75: /* db_options ::= db_options SINGLE_STABLE NK_INTEGER */ { ((SDatabaseOptions*)yymsp[-2].minor.yy182)->pSingleStable = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); yylhsminor.yy182 = yymsp[-2].minor.yy182; } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 76: /* db_options ::= db_options STREAM_MODE NK_INTEGER */ { ((SDatabaseOptions*)yymsp[-2].minor.yy182)->pStreamMode = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); yylhsminor.yy182 = yymsp[-2].minor.yy182; } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 77: /* db_options ::= db_options RETENTIONS retention_list */ { ((SDatabaseOptions*)yymsp[-2].minor.yy182)->pRetentions = yymsp[0].minor.yy334; yylhsminor.yy182 = yymsp[-2].minor.yy182; } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 78: /* alter_db_options ::= alter_db_option */ { yylhsminor.yy182 = createDatabaseOptions(pCxt); yylhsminor.yy182 = setDatabaseAlterOption(pCxt, yylhsminor.yy182, &yymsp[0].minor.yy515); } yymsp[0].minor.yy182 = yylhsminor.yy182; break; case 79: /* alter_db_options ::= alter_db_options alter_db_option */ { yylhsminor.yy182 = setDatabaseAlterOption(pCxt, yymsp[-1].minor.yy182, &yymsp[0].minor.yy515); } yymsp[-1].minor.yy182 = yylhsminor.yy182; break; case 80: /* alter_db_option ::= BLOCKS NK_INTEGER */ { yymsp[-1].minor.yy515.type = DB_OPTION_BLOCKS; yymsp[-1].minor.yy515.pVal = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); } break; case 81: /* alter_db_option ::= FSYNC NK_INTEGER */ { yymsp[-1].minor.yy515.type = DB_OPTION_FSYNC; yymsp[-1].minor.yy515.pVal = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); } break; case 82: /* alter_db_option ::= KEEP integer_list */ case 83: /* alter_db_option ::= KEEP variable_list */ yytestcase(yyruleno==83); { yymsp[-1].minor.yy515.type = DB_OPTION_KEEP; yymsp[-1].minor.yy515.pList = yymsp[0].minor.yy334; } break; case 84: /* alter_db_option ::= WAL NK_INTEGER */ { yymsp[-1].minor.yy515.type = DB_OPTION_WAL; yymsp[-1].minor.yy515.pVal = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); } break; case 85: /* alter_db_option ::= QUORUM NK_INTEGER */ { yymsp[-1].minor.yy515.type = DB_OPTION_QUORUM; yymsp[-1].minor.yy515.pVal = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); } break; case 86: /* alter_db_option ::= CACHELAST NK_INTEGER */ { yymsp[-1].minor.yy515.type = DB_OPTION_CACHELAST; yymsp[-1].minor.yy515.pVal = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); } break; case 87: /* alter_db_option ::= REPLICA NK_INTEGER */ { yymsp[-1].minor.yy515.type = DB_OPTION_REPLICA; yymsp[-1].minor.yy515.pVal = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); } break; case 88: /* integer_list ::= NK_INTEGER */ { yylhsminor.yy334 = createNodeList(pCxt, createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0)); } yymsp[0].minor.yy334 = yylhsminor.yy334; break; case 89: /* integer_list ::= integer_list NK_COMMA NK_INTEGER */ case 240: /* dnode_list ::= dnode_list DNODE NK_INTEGER */ yytestcase(yyruleno==240); { yylhsminor.yy334 = addNodeToList(pCxt, yymsp[-2].minor.yy334, createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0)); } yymsp[-2].minor.yy334 = yylhsminor.yy334; break; case 90: /* variable_list ::= NK_VARIABLE */ { yylhsminor.yy334 = createNodeList(pCxt, createDurationValueNode(pCxt, &yymsp[0].minor.yy0)); } yymsp[0].minor.yy334 = yylhsminor.yy334; break; case 91: /* variable_list ::= variable_list NK_COMMA NK_VARIABLE */ { yylhsminor.yy334 = addNodeToList(pCxt, yymsp[-2].minor.yy334, createDurationValueNode(pCxt, &yymsp[0].minor.yy0)); } yymsp[-2].minor.yy334 = yylhsminor.yy334; break; case 92: /* retention_list ::= retention */ case 112: /* multi_create_clause ::= create_subtable_clause */ yytestcase(yyruleno==112); case 115: /* multi_drop_clause ::= drop_table_clause */ yytestcase(yyruleno==115); case 122: /* column_def_list ::= column_def */ yytestcase(yyruleno==122); case 165: /* col_name_list ::= col_name */ yytestcase(yyruleno==165); case 201: /* func_name_list ::= func_name */ yytestcase(yyruleno==201); case 210: /* func_list ::= func */ yytestcase(yyruleno==210); case 263: /* literal_list ::= signed_literal */ yytestcase(yyruleno==263); case 356: /* select_sublist ::= select_item */ yytestcase(yyruleno==356); case 403: /* sort_specification_list ::= sort_specification */ yytestcase(yyruleno==403); { yylhsminor.yy334 = createNodeList(pCxt, yymsp[0].minor.yy182); } yymsp[0].minor.yy334 = yylhsminor.yy334; break; case 93: /* retention_list ::= retention_list NK_COMMA retention */ case 123: /* column_def_list ::= column_def_list NK_COMMA column_def */ yytestcase(yyruleno==123); case 166: /* col_name_list ::= col_name_list NK_COMMA col_name */ yytestcase(yyruleno==166); case 202: /* func_name_list ::= func_name_list NK_COMMA col_name */ yytestcase(yyruleno==202); case 211: /* func_list ::= func_list NK_COMMA func */ yytestcase(yyruleno==211); case 264: /* literal_list ::= literal_list NK_COMMA signed_literal */ yytestcase(yyruleno==264); case 357: /* select_sublist ::= select_sublist NK_COMMA select_item */ yytestcase(yyruleno==357); case 404: /* sort_specification_list ::= sort_specification_list NK_COMMA sort_specification */ yytestcase(yyruleno==404); { yylhsminor.yy334 = addNodeToList(pCxt, yymsp[-2].minor.yy334, yymsp[0].minor.yy182); } yymsp[-2].minor.yy334 = yylhsminor.yy334; break; case 94: /* retention ::= NK_VARIABLE NK_COLON NK_VARIABLE */ { yylhsminor.yy182 = createNodeListNodeEx(pCxt, createDurationValueNode(pCxt, &yymsp[-2].minor.yy0), createDurationValueNode(pCxt, &yymsp[0].minor.yy0)); } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 95: /* cmd ::= CREATE TABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def_opt table_options */ case 97: /* cmd ::= CREATE STABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def table_options */ yytestcase(yyruleno==97); { pCxt->pRootNode = createCreateTableStmt(pCxt, yymsp[-6].minor.yy47, yymsp[-5].minor.yy182, yymsp[-3].minor.yy334, yymsp[-1].minor.yy334, yymsp[0].minor.yy182); } break; case 96: /* cmd ::= CREATE TABLE multi_create_clause */ { pCxt->pRootNode = createCreateMultiTableStmt(pCxt, yymsp[0].minor.yy334); } break; case 98: /* cmd ::= DROP TABLE multi_drop_clause */ { pCxt->pRootNode = createDropTableStmt(pCxt, yymsp[0].minor.yy334); } break; case 99: /* cmd ::= DROP STABLE exists_opt full_table_name */ { pCxt->pRootNode = createDropSuperTableStmt(pCxt, yymsp[-1].minor.yy47, yymsp[0].minor.yy182); } break; case 100: /* cmd ::= ALTER TABLE alter_table_clause */ case 101: /* cmd ::= ALTER STABLE alter_table_clause */ yytestcase(yyruleno==101); case 242: /* cmd ::= query_expression */ yytestcase(yyruleno==242); { pCxt->pRootNode = yymsp[0].minor.yy182; } break; case 102: /* alter_table_clause ::= full_table_name alter_table_options */ { yylhsminor.yy182 = createAlterTableOption(pCxt, yymsp[-1].minor.yy182, yymsp[0].minor.yy182); } yymsp[-1].minor.yy182 = yylhsminor.yy182; break; case 103: /* alter_table_clause ::= full_table_name ADD COLUMN column_name type_name */ { yylhsminor.yy182 = createAlterTableAddModifyCol(pCxt, yymsp[-4].minor.yy182, TSDB_ALTER_TABLE_ADD_COLUMN, &yymsp[-1].minor.yy29, yymsp[0].minor.yy574); } yymsp[-4].minor.yy182 = yylhsminor.yy182; break; case 104: /* alter_table_clause ::= full_table_name DROP COLUMN column_name */ { yylhsminor.yy182 = createAlterTableDropCol(pCxt, yymsp[-3].minor.yy182, TSDB_ALTER_TABLE_DROP_COLUMN, &yymsp[0].minor.yy29); } yymsp[-3].minor.yy182 = yylhsminor.yy182; break; case 105: /* alter_table_clause ::= full_table_name MODIFY COLUMN column_name type_name */ { yylhsminor.yy182 = createAlterTableAddModifyCol(pCxt, yymsp[-4].minor.yy182, TSDB_ALTER_TABLE_UPDATE_COLUMN_BYTES, &yymsp[-1].minor.yy29, yymsp[0].minor.yy574); } yymsp[-4].minor.yy182 = yylhsminor.yy182; break; case 106: /* alter_table_clause ::= full_table_name RENAME COLUMN column_name column_name */ { yylhsminor.yy182 = createAlterTableRenameCol(pCxt, yymsp[-4].minor.yy182, TSDB_ALTER_TABLE_UPDATE_COLUMN_NAME, &yymsp[-1].minor.yy29, &yymsp[0].minor.yy29); } yymsp[-4].minor.yy182 = yylhsminor.yy182; break; case 107: /* alter_table_clause ::= full_table_name ADD TAG column_name type_name */ { yylhsminor.yy182 = createAlterTableAddModifyCol(pCxt, yymsp[-4].minor.yy182, TSDB_ALTER_TABLE_ADD_TAG, &yymsp[-1].minor.yy29, yymsp[0].minor.yy574); } yymsp[-4].minor.yy182 = yylhsminor.yy182; break; case 108: /* alter_table_clause ::= full_table_name DROP TAG column_name */ { yylhsminor.yy182 = createAlterTableDropCol(pCxt, yymsp[-3].minor.yy182, TSDB_ALTER_TABLE_DROP_TAG, &yymsp[0].minor.yy29); } yymsp[-3].minor.yy182 = yylhsminor.yy182; break; case 109: /* alter_table_clause ::= full_table_name MODIFY TAG column_name type_name */ { yylhsminor.yy182 = createAlterTableAddModifyCol(pCxt, yymsp[-4].minor.yy182, TSDB_ALTER_TABLE_UPDATE_TAG_BYTES, &yymsp[-1].minor.yy29, yymsp[0].minor.yy574); } yymsp[-4].minor.yy182 = yylhsminor.yy182; break; case 110: /* alter_table_clause ::= full_table_name RENAME TAG column_name column_name */ { yylhsminor.yy182 = createAlterTableRenameCol(pCxt, yymsp[-4].minor.yy182, TSDB_ALTER_TABLE_UPDATE_TAG_NAME, &yymsp[-1].minor.yy29, &yymsp[0].minor.yy29); } yymsp[-4].minor.yy182 = yylhsminor.yy182; break; case 111: /* alter_table_clause ::= full_table_name SET TAG column_name NK_EQ literal */ { yylhsminor.yy182 = createAlterTableSetTag(pCxt, yymsp[-5].minor.yy182, &yymsp[-2].minor.yy29, yymsp[0].minor.yy182); } yymsp[-5].minor.yy182 = yylhsminor.yy182; break; case 113: /* multi_create_clause ::= multi_create_clause create_subtable_clause */ case 116: /* multi_drop_clause ::= multi_drop_clause drop_table_clause */ yytestcase(yyruleno==116); { yylhsminor.yy334 = addNodeToList(pCxt, yymsp[-1].minor.yy334, yymsp[0].minor.yy182); } yymsp[-1].minor.yy334 = yylhsminor.yy334; break; case 114: /* create_subtable_clause ::= not_exists_opt full_table_name USING full_table_name specific_tags_opt TAGS NK_LP literal_list NK_RP */ { yylhsminor.yy182 = createCreateSubTableClause(pCxt, yymsp[-8].minor.yy47, yymsp[-7].minor.yy182, yymsp[-5].minor.yy182, yymsp[-4].minor.yy334, yymsp[-1].minor.yy334); } yymsp[-8].minor.yy182 = yylhsminor.yy182; break; case 117: /* drop_table_clause ::= exists_opt full_table_name */ { yylhsminor.yy182 = createDropTableClause(pCxt, yymsp[-1].minor.yy47, yymsp[0].minor.yy182); } yymsp[-1].minor.yy182 = yylhsminor.yy182; break; case 118: /* specific_tags_opt ::= */ case 149: /* tags_def_opt ::= */ yytestcase(yyruleno==149); case 364: /* partition_by_clause_opt ::= */ yytestcase(yyruleno==364); case 381: /* group_by_clause_opt ::= */ yytestcase(yyruleno==381); case 391: /* order_by_clause_opt ::= */ yytestcase(yyruleno==391); { yymsp[1].minor.yy334 = NULL; } break; case 119: /* specific_tags_opt ::= NK_LP col_name_list NK_RP */ { yymsp[-2].minor.yy334 = yymsp[-1].minor.yy334; } break; case 120: /* full_table_name ::= table_name */ { yylhsminor.yy182 = createRealTableNode(pCxt, NULL, &yymsp[0].minor.yy29, NULL); } yymsp[0].minor.yy182 = yylhsminor.yy182; break; case 121: /* full_table_name ::= db_name NK_DOT table_name */ { yylhsminor.yy182 = createRealTableNode(pCxt, &yymsp[-2].minor.yy29, &yymsp[0].minor.yy29, NULL); } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 124: /* column_def ::= column_name type_name */ { yylhsminor.yy182 = createColumnDefNode(pCxt, &yymsp[-1].minor.yy29, yymsp[0].minor.yy574, NULL); } yymsp[-1].minor.yy182 = yylhsminor.yy182; break; case 125: /* column_def ::= column_name type_name COMMENT NK_STRING */ { yylhsminor.yy182 = createColumnDefNode(pCxt, &yymsp[-3].minor.yy29, yymsp[-2].minor.yy574, &yymsp[0].minor.yy0); } yymsp[-3].minor.yy182 = yylhsminor.yy182; break; case 126: /* type_name ::= BOOL */ { yymsp[0].minor.yy574 = createDataType(TSDB_DATA_TYPE_BOOL); } break; case 127: /* type_name ::= TINYINT */ { yymsp[0].minor.yy574 = createDataType(TSDB_DATA_TYPE_TINYINT); } break; case 128: /* type_name ::= SMALLINT */ { yymsp[0].minor.yy574 = createDataType(TSDB_DATA_TYPE_SMALLINT); } break; case 129: /* type_name ::= INT */ case 130: /* type_name ::= INTEGER */ yytestcase(yyruleno==130); { yymsp[0].minor.yy574 = createDataType(TSDB_DATA_TYPE_INT); } break; case 131: /* type_name ::= BIGINT */ { yymsp[0].minor.yy574 = createDataType(TSDB_DATA_TYPE_BIGINT); } break; case 132: /* type_name ::= FLOAT */ { yymsp[0].minor.yy574 = createDataType(TSDB_DATA_TYPE_FLOAT); } break; case 133: /* type_name ::= DOUBLE */ { yymsp[0].minor.yy574 = createDataType(TSDB_DATA_TYPE_DOUBLE); } break; case 134: /* type_name ::= BINARY NK_LP NK_INTEGER NK_RP */ { yymsp[-3].minor.yy574 = createVarLenDataType(TSDB_DATA_TYPE_BINARY, &yymsp[-1].minor.yy0); } break; case 135: /* type_name ::= TIMESTAMP */ { yymsp[0].minor.yy574 = createDataType(TSDB_DATA_TYPE_TIMESTAMP); } break; case 136: /* type_name ::= NCHAR NK_LP NK_INTEGER NK_RP */ { yymsp[-3].minor.yy574 = createVarLenDataType(TSDB_DATA_TYPE_NCHAR, &yymsp[-1].minor.yy0); } break; case 137: /* type_name ::= TINYINT UNSIGNED */ { yymsp[-1].minor.yy574 = createDataType(TSDB_DATA_TYPE_UTINYINT); } break; case 138: /* type_name ::= SMALLINT UNSIGNED */ { yymsp[-1].minor.yy574 = createDataType(TSDB_DATA_TYPE_USMALLINT); } break; case 139: /* type_name ::= INT UNSIGNED */ { yymsp[-1].minor.yy574 = createDataType(TSDB_DATA_TYPE_UINT); } break; case 140: /* type_name ::= BIGINT UNSIGNED */ { yymsp[-1].minor.yy574 = createDataType(TSDB_DATA_TYPE_UBIGINT); } break; case 141: /* type_name ::= JSON */ { yymsp[0].minor.yy574 = createDataType(TSDB_DATA_TYPE_JSON); } break; case 142: /* type_name ::= VARCHAR NK_LP NK_INTEGER NK_RP */ { yymsp[-3].minor.yy574 = createVarLenDataType(TSDB_DATA_TYPE_VARCHAR, &yymsp[-1].minor.yy0); } break; case 143: /* type_name ::= MEDIUMBLOB */ { yymsp[0].minor.yy574 = createDataType(TSDB_DATA_TYPE_MEDIUMBLOB); } break; case 144: /* type_name ::= BLOB */ { yymsp[0].minor.yy574 = createDataType(TSDB_DATA_TYPE_BLOB); } break; case 145: /* type_name ::= VARBINARY NK_LP NK_INTEGER NK_RP */ { yymsp[-3].minor.yy574 = createVarLenDataType(TSDB_DATA_TYPE_VARBINARY, &yymsp[-1].minor.yy0); } break; case 146: /* type_name ::= DECIMAL */ { yymsp[0].minor.yy574 = createDataType(TSDB_DATA_TYPE_DECIMAL); } break; case 147: /* type_name ::= DECIMAL NK_LP NK_INTEGER NK_RP */ { yymsp[-3].minor.yy574 = createDataType(TSDB_DATA_TYPE_DECIMAL); } break; case 148: /* type_name ::= DECIMAL NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP */ { yymsp[-5].minor.yy574 = createDataType(TSDB_DATA_TYPE_DECIMAL); } break; case 150: /* tags_def_opt ::= tags_def */ case 355: /* select_list ::= select_sublist */ yytestcase(yyruleno==355); { yylhsminor.yy334 = yymsp[0].minor.yy334; } yymsp[0].minor.yy334 = yylhsminor.yy334; break; case 151: /* tags_def ::= TAGS NK_LP column_def_list NK_RP */ { yymsp[-3].minor.yy334 = yymsp[-1].minor.yy334; } break; case 152: /* table_options ::= */ { yymsp[1].minor.yy182 = createTableOptions(pCxt); } break; case 153: /* table_options ::= table_options COMMENT NK_STRING */ { ((STableOptions*)yymsp[-2].minor.yy182)->pComments = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0); yylhsminor.yy182 = yymsp[-2].minor.yy182; } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 154: /* table_options ::= table_options KEEP integer_list */ { ((STableOptions*)yymsp[-2].minor.yy182)->pKeep = yymsp[0].minor.yy334; yylhsminor.yy182 = yymsp[-2].minor.yy182; } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 155: /* table_options ::= table_options TTL NK_INTEGER */ { ((STableOptions*)yymsp[-2].minor.yy182)->pTtl = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); yylhsminor.yy182 = yymsp[-2].minor.yy182; } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 156: /* table_options ::= table_options SMA NK_LP col_name_list NK_RP */ { ((STableOptions*)yymsp[-4].minor.yy182)->pSma = yymsp[-1].minor.yy334; yylhsminor.yy182 = yymsp[-4].minor.yy182; } yymsp[-4].minor.yy182 = yylhsminor.yy182; break; case 157: /* table_options ::= table_options ROLLUP NK_LP func_name_list NK_RP */ { ((STableOptions*)yymsp[-4].minor.yy182)->pFuncs = yymsp[-1].minor.yy334; yylhsminor.yy182 = yymsp[-4].minor.yy182; } yymsp[-4].minor.yy182 = yylhsminor.yy182; break; case 158: /* table_options ::= table_options FILE_FACTOR NK_FLOAT */ { ((STableOptions*)yymsp[-2].minor.yy182)->pFilesFactor = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &yymsp[0].minor.yy0); yylhsminor.yy182 = yymsp[-2].minor.yy182; } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 159: /* table_options ::= table_options DELAY NK_INTEGER */ { ((STableOptions*)yymsp[-2].minor.yy182)->pDelay = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); yylhsminor.yy182 = yymsp[-2].minor.yy182; } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 160: /* alter_table_options ::= alter_table_option */ { yylhsminor.yy182 = createTableOptions(pCxt); yylhsminor.yy182 = setTableAlterOption(pCxt, yylhsminor.yy182, &yymsp[0].minor.yy515); } yymsp[0].minor.yy182 = yylhsminor.yy182; break; case 161: /* alter_table_options ::= alter_table_options alter_table_option */ { yylhsminor.yy182 = setTableAlterOption(pCxt, yymsp[-1].minor.yy182, &yymsp[0].minor.yy515); } yymsp[-1].minor.yy182 = yylhsminor.yy182; break; case 162: /* alter_table_option ::= COMMENT NK_STRING */ { yymsp[-1].minor.yy515.type = TABLE_OPTION_COMMENT; yymsp[-1].minor.yy515.pVal = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0); } break; case 163: /* alter_table_option ::= KEEP integer_list */ { yymsp[-1].minor.yy515.type = TABLE_OPTION_KEEP; yymsp[-1].minor.yy515.pList = yymsp[0].minor.yy334; } break; case 164: /* alter_table_option ::= TTL NK_INTEGER */ { yymsp[-1].minor.yy515.type = TABLE_OPTION_TTL; yymsp[-1].minor.yy515.pVal = (SValueNode*)createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); } break; case 167: /* col_name ::= column_name */ { yylhsminor.yy182 = createColumnNode(pCxt, NULL, &yymsp[0].minor.yy29); } yymsp[0].minor.yy182 = yylhsminor.yy182; break; case 168: /* cmd ::= SHOW DNODES */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_DNODES_STMT, NULL, NULL); } break; case 169: /* cmd ::= SHOW USERS */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_USERS_STMT, NULL, NULL); } break; case 170: /* cmd ::= SHOW DATABASES */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_DATABASES_STMT, NULL, NULL); } break; case 171: /* cmd ::= SHOW db_name_cond_opt TABLES like_pattern_opt */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_TABLES_STMT, yymsp[-2].minor.yy182, yymsp[0].minor.yy182); } break; case 172: /* cmd ::= SHOW db_name_cond_opt STABLES like_pattern_opt */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_STABLES_STMT, yymsp[-2].minor.yy182, yymsp[0].minor.yy182); } break; case 173: /* cmd ::= SHOW db_name_cond_opt VGROUPS */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_VGROUPS_STMT, yymsp[-1].minor.yy182, NULL); } break; case 174: /* cmd ::= SHOW MNODES */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_MNODES_STMT, NULL, NULL); } break; case 175: /* cmd ::= SHOW MODULES */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_MODULES_STMT, NULL, NULL); } break; case 176: /* cmd ::= SHOW QNODES */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_QNODES_STMT, NULL, NULL); } break; case 177: /* cmd ::= SHOW FUNCTIONS */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_FUNCTIONS_STMT, NULL, NULL); } break; case 178: /* cmd ::= SHOW INDEXES FROM table_name_cond from_db_opt */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_INDEXES_STMT, yymsp[-1].minor.yy182, yymsp[0].minor.yy182); } break; case 179: /* cmd ::= SHOW STREAMS */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_STREAMS_STMT, NULL, NULL); } break; case 180: /* cmd ::= SHOW ACCOUNTS */ { pCxt->valid = false; generateSyntaxErrMsg(&pCxt->msgBuf, TSDB_CODE_PAR_EXPRIE_STATEMENT); } break; case 181: /* cmd ::= SHOW APPS */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_APPS_STMT, NULL, NULL); } break; case 182: /* cmd ::= SHOW CONNECTIONS */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_CONNECTIONS_STMT, NULL, NULL); } break; case 183: /* cmd ::= SHOW LICENCE */ case 184: /* cmd ::= SHOW GRANTS */ yytestcase(yyruleno==184); { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_LICENCE_STMT, NULL, NULL); } break; case 185: /* cmd ::= SHOW CREATE DATABASE db_name */ { pCxt->pRootNode = createShowCreateDatabaseStmt(pCxt, &yymsp[0].minor.yy29); } break; case 186: /* cmd ::= SHOW CREATE TABLE full_table_name */ { pCxt->pRootNode = createShowCreateTableStmt(pCxt, QUERY_NODE_SHOW_CREATE_TABLE_STMT, yymsp[0].minor.yy182); } break; case 187: /* cmd ::= SHOW CREATE STABLE full_table_name */ { pCxt->pRootNode = createShowCreateTableStmt(pCxt, QUERY_NODE_SHOW_CREATE_STABLE_STMT, yymsp[0].minor.yy182); } break; case 188: /* cmd ::= SHOW QUERIES */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_QUERIES_STMT, NULL, NULL); } break; case 189: /* cmd ::= SHOW SCORES */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_SCORES_STMT, NULL, NULL); } break; case 190: /* cmd ::= SHOW TOPICS */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_TOPICS_STMT, NULL, NULL); } break; case 191: /* cmd ::= SHOW VARIABLES */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_VARIABLE_STMT, NULL, NULL); } break; case 192: /* cmd ::= SHOW BNODES */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_BNODES_STMT, NULL, NULL); } break; case 193: /* cmd ::= SHOW SNODES */ { pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_SNODES_STMT, NULL, NULL); } break; case 194: /* db_name_cond_opt ::= */ case 199: /* from_db_opt ::= */ yytestcase(yyruleno==199); { yymsp[1].minor.yy182 = createDefaultDatabaseCondValue(pCxt); } break; case 195: /* db_name_cond_opt ::= db_name NK_DOT */ { yylhsminor.yy182 = createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[-1].minor.yy29); } yymsp[-1].minor.yy182 = yylhsminor.yy182; break; case 196: /* like_pattern_opt ::= */ case 207: /* index_options ::= */ yytestcase(yyruleno==207); case 362: /* where_clause_opt ::= */ yytestcase(yyruleno==362); case 366: /* twindow_clause_opt ::= */ yytestcase(yyruleno==366); case 371: /* sliding_opt ::= */ yytestcase(yyruleno==371); case 373: /* fill_opt ::= */ yytestcase(yyruleno==373); case 385: /* having_clause_opt ::= */ yytestcase(yyruleno==385); case 393: /* slimit_clause_opt ::= */ yytestcase(yyruleno==393); case 397: /* limit_clause_opt ::= */ yytestcase(yyruleno==397); { yymsp[1].minor.yy182 = NULL; } break; case 197: /* like_pattern_opt ::= LIKE NK_STRING */ { yymsp[-1].minor.yy182 = createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0); } break; case 198: /* table_name_cond ::= table_name */ { yylhsminor.yy182 = createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy29); } yymsp[0].minor.yy182 = yylhsminor.yy182; break; case 200: /* from_db_opt ::= FROM db_name */ { yymsp[-1].minor.yy182 = createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy29); } break; case 203: /* func_name ::= function_name */ { yylhsminor.yy182 = createFunctionNode(pCxt, &yymsp[0].minor.yy29, NULL); } yymsp[0].minor.yy182 = yylhsminor.yy182; break; case 204: /* cmd ::= CREATE SMA INDEX not_exists_opt index_name ON table_name index_options */ { pCxt->pRootNode = createCreateIndexStmt(pCxt, INDEX_TYPE_SMA, yymsp[-4].minor.yy47, &yymsp[-3].minor.yy29, &yymsp[-1].minor.yy29, NULL, yymsp[0].minor.yy182); } break; case 205: /* 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.yy47, &yymsp[-5].minor.yy29, &yymsp[-3].minor.yy29, yymsp[-1].minor.yy334, NULL); } break; case 206: /* cmd ::= DROP INDEX exists_opt index_name ON table_name */ { pCxt->pRootNode = createDropIndexStmt(pCxt, yymsp[-3].minor.yy47, &yymsp[-2].minor.yy29, &yymsp[0].minor.yy29); } break; case 208: /* index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_RP sliding_opt */ { yymsp[-8].minor.yy182 = createIndexOption(pCxt, yymsp[-6].minor.yy334, releaseRawExprNode(pCxt, yymsp[-2].minor.yy182), NULL, yymsp[0].minor.yy182); } break; case 209: /* 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.yy182 = createIndexOption(pCxt, yymsp[-8].minor.yy334, releaseRawExprNode(pCxt, yymsp[-4].minor.yy182), releaseRawExprNode(pCxt, yymsp[-2].minor.yy182), yymsp[0].minor.yy182); } break; case 212: /* func ::= function_name NK_LP expression_list NK_RP */ { yylhsminor.yy182 = createFunctionNode(pCxt, &yymsp[-3].minor.yy29, yymsp[-1].minor.yy334); } yymsp[-3].minor.yy182 = yylhsminor.yy182; break; case 213: /* cmd ::= CREATE TOPIC not_exists_opt topic_name AS query_expression */ { pCxt->pRootNode = createCreateTopicStmt(pCxt, yymsp[-3].minor.yy47, &yymsp[-2].minor.yy29, yymsp[0].minor.yy182, NULL); } break; case 214: /* cmd ::= CREATE TOPIC not_exists_opt topic_name AS db_name */ { pCxt->pRootNode = createCreateTopicStmt(pCxt, yymsp[-3].minor.yy47, &yymsp[-2].minor.yy29, NULL, &yymsp[0].minor.yy29); } break; case 215: /* cmd ::= DROP TOPIC exists_opt topic_name */ { pCxt->pRootNode = createDropTopicStmt(pCxt, yymsp[-1].minor.yy47, &yymsp[0].minor.yy29); } break; case 216: /* cmd ::= DESC full_table_name */ case 217: /* cmd ::= DESCRIBE full_table_name */ yytestcase(yyruleno==217); { pCxt->pRootNode = createDescribeStmt(pCxt, yymsp[0].minor.yy182); } break; case 218: /* cmd ::= RESET QUERY CACHE */ { pCxt->pRootNode = createResetQueryCacheStmt(pCxt); } break; case 219: /* cmd ::= EXPLAIN analyze_opt explain_options query_expression */ { pCxt->pRootNode = createExplainStmt(pCxt, yymsp[-2].minor.yy47, yymsp[-1].minor.yy182, yymsp[0].minor.yy182); } break; case 221: /* analyze_opt ::= ANALYZE */ case 229: /* agg_func_opt ::= AGGREGATE */ yytestcase(yyruleno==229); case 352: /* set_quantifier_opt ::= DISTINCT */ yytestcase(yyruleno==352); { yymsp[0].minor.yy47 = true; } break; case 222: /* explain_options ::= */ { yymsp[1].minor.yy182 = createDefaultExplainOptions(pCxt); } break; case 223: /* explain_options ::= explain_options VERBOSE NK_BOOL */ { yylhsminor.yy182 = setExplainVerbose(pCxt, yymsp[-2].minor.yy182, &yymsp[0].minor.yy0); } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 224: /* explain_options ::= explain_options RATIO NK_FLOAT */ { yylhsminor.yy182 = setExplainRatio(pCxt, yymsp[-2].minor.yy182, &yymsp[0].minor.yy0); } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 225: /* cmd ::= COMPACT VNODES IN NK_LP integer_list NK_RP */ { pCxt->pRootNode = createCompactStmt(pCxt, yymsp[-1].minor.yy334); } break; case 226: /* cmd ::= CREATE agg_func_opt FUNCTION function_name AS NK_STRING OUTPUTTYPE type_name bufsize_opt */ { pCxt->pRootNode = createCreateFunctionStmt(pCxt, yymsp[-7].minor.yy47, &yymsp[-5].minor.yy29, &yymsp[-3].minor.yy0, yymsp[-1].minor.yy574, yymsp[0].minor.yy550); } break; case 227: /* cmd ::= DROP FUNCTION function_name */ { pCxt->pRootNode = createDropFunctionStmt(pCxt, &yymsp[0].minor.yy29); } break; case 230: /* bufsize_opt ::= */ { yymsp[1].minor.yy550 = 0; } break; case 231: /* bufsize_opt ::= BUFSIZE NK_INTEGER */ { yymsp[-1].minor.yy550 = strtol(yymsp[0].minor.yy0.z, NULL, 10); } break; case 232: /* cmd ::= CREATE STREAM stream_name INTO table_name AS query_expression */ { pCxt->pRootNode = createCreateStreamStmt(pCxt, &yymsp[-4].minor.yy29, &yymsp[-2].minor.yy29, yymsp[0].minor.yy182); } break; case 233: /* cmd ::= DROP STREAM stream_name */ { pCxt->pRootNode = createDropStreamStmt(pCxt, &yymsp[0].minor.yy29); } break; case 234: /* cmd ::= KILL CONNECTION NK_INTEGER */ { pCxt->pRootNode = createKillStmt(pCxt, QUERY_NODE_KILL_CONNECTION_STMT, &yymsp[0].minor.yy0); } break; case 235: /* cmd ::= KILL QUERY NK_INTEGER */ { pCxt->pRootNode = createKillStmt(pCxt, QUERY_NODE_KILL_QUERY_STMT, &yymsp[0].minor.yy0); } break; case 236: /* cmd ::= MERGE VGROUP NK_INTEGER NK_INTEGER */ { pCxt->pRootNode = createMergeVgroupStmt(pCxt, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0); } break; case 237: /* cmd ::= REDISTRIBUTE VGROUP NK_INTEGER dnode_list */ { pCxt->pRootNode = createRedistributeVgroupStmt(pCxt, &yymsp[-1].minor.yy0, yymsp[0].minor.yy334); } break; case 238: /* cmd ::= SPLIT VGROUP NK_INTEGER */ { pCxt->pRootNode = createSplitVgroupStmt(pCxt, &yymsp[0].minor.yy0); } break; case 239: /* dnode_list ::= DNODE NK_INTEGER */ { yymsp[-1].minor.yy334 = createNodeList(pCxt, createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0)); } break; case 241: /* cmd ::= SYNCDB db_name REPLICA */ { pCxt->pRootNode = createSyncdbStmt(pCxt, &yymsp[-1].minor.yy29); } break; case 243: /* literal ::= NK_INTEGER */ { yylhsminor.yy182 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0)); } yymsp[0].minor.yy182 = yylhsminor.yy182; break; case 244: /* literal ::= NK_FLOAT */ { yylhsminor.yy182 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &yymsp[0].minor.yy0)); } yymsp[0].minor.yy182 = yylhsminor.yy182; break; case 245: /* literal ::= NK_STRING */ { yylhsminor.yy182 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0)); } yymsp[0].minor.yy182 = yylhsminor.yy182; break; case 246: /* literal ::= NK_BOOL */ { yylhsminor.yy182 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_BOOL, &yymsp[0].minor.yy0)); } yymsp[0].minor.yy182 = yylhsminor.yy182; break; case 247: /* literal ::= TIMESTAMP NK_STRING */ { yylhsminor.yy182 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_TIMESTAMP, &yymsp[0].minor.yy0)); } yymsp[-1].minor.yy182 = yylhsminor.yy182; break; case 248: /* literal ::= duration_literal */ case 257: /* signed_literal ::= signed */ yytestcase(yyruleno==257); case 279: /* expression ::= literal */ yytestcase(yyruleno==279); case 280: /* expression ::= pseudo_column */ yytestcase(yyruleno==280); case 281: /* expression ::= column_reference */ yytestcase(yyruleno==281); case 286: /* expression ::= subquery */ yytestcase(yyruleno==286); case 325: /* boolean_value_expression ::= boolean_primary */ yytestcase(yyruleno==325); case 329: /* boolean_primary ::= predicate */ yytestcase(yyruleno==329); case 331: /* common_expression ::= expression */ yytestcase(yyruleno==331); case 332: /* common_expression ::= boolean_value_expression */ yytestcase(yyruleno==332); case 334: /* table_reference_list ::= table_reference */ yytestcase(yyruleno==334); case 336: /* table_reference ::= table_primary */ yytestcase(yyruleno==336); case 337: /* table_reference ::= joined_table */ yytestcase(yyruleno==337); case 341: /* table_primary ::= parenthesized_joined_table */ yytestcase(yyruleno==341); case 388: /* query_expression_body ::= query_primary */ yytestcase(yyruleno==388); case 390: /* query_primary ::= query_specification */ yytestcase(yyruleno==390); { yylhsminor.yy182 = yymsp[0].minor.yy182; } yymsp[0].minor.yy182 = yylhsminor.yy182; break; case 249: /* literal ::= NULL */ { yylhsminor.yy182 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_NULL, NULL)); } yymsp[0].minor.yy182 = yylhsminor.yy182; break; case 250: /* duration_literal ::= NK_VARIABLE */ { yylhsminor.yy182 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createDurationValueNode(pCxt, &yymsp[0].minor.yy0)); } yymsp[0].minor.yy182 = yylhsminor.yy182; break; case 251: /* signed ::= NK_INTEGER */ { yylhsminor.yy182 = createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); } yymsp[0].minor.yy182 = yylhsminor.yy182; break; case 252: /* signed ::= NK_PLUS NK_INTEGER */ { yymsp[-1].minor.yy182 = createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0); } break; case 253: /* 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.yy182 = createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &t); } yymsp[-1].minor.yy182 = yylhsminor.yy182; break; case 254: /* signed ::= NK_FLOAT */ { yylhsminor.yy182 = createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &yymsp[0].minor.yy0); } yymsp[0].minor.yy182 = yylhsminor.yy182; break; case 255: /* signed ::= NK_PLUS NK_FLOAT */ { yymsp[-1].minor.yy182 = createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &yymsp[0].minor.yy0); } break; case 256: /* 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.yy182 = createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &t); } yymsp[-1].minor.yy182 = yylhsminor.yy182; break; case 258: /* signed_literal ::= NK_STRING */ { yylhsminor.yy182 = createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0); } yymsp[0].minor.yy182 = yylhsminor.yy182; break; case 259: /* signed_literal ::= NK_BOOL */ { yylhsminor.yy182 = createValueNode(pCxt, TSDB_DATA_TYPE_BOOL, &yymsp[0].minor.yy0); } yymsp[0].minor.yy182 = yylhsminor.yy182; break; case 260: /* signed_literal ::= TIMESTAMP NK_STRING */ { yymsp[-1].minor.yy182 = createValueNode(pCxt, TSDB_DATA_TYPE_TIMESTAMP, &yymsp[0].minor.yy0); } break; case 261: /* signed_literal ::= duration_literal */ case 358: /* select_item ::= common_expression */ yytestcase(yyruleno==358); case 402: /* search_condition ::= common_expression */ yytestcase(yyruleno==402); { yylhsminor.yy182 = releaseRawExprNode(pCxt, yymsp[0].minor.yy182); } yymsp[0].minor.yy182 = yylhsminor.yy182; break; case 262: /* signed_literal ::= NULL */ { yymsp[0].minor.yy182 = createValueNode(pCxt, TSDB_DATA_TYPE_NULL, NULL); } break; case 282: /* expression ::= function_name NK_LP expression_list NK_RP */ { yylhsminor.yy182 = createRawExprNodeExt(pCxt, &yymsp[-3].minor.yy29, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[-3].minor.yy29, yymsp[-1].minor.yy334)); } yymsp[-3].minor.yy182 = yylhsminor.yy182; break; case 283: /* expression ::= function_name NK_LP NK_STAR NK_RP */ { yylhsminor.yy182 = createRawExprNodeExt(pCxt, &yymsp[-3].minor.yy29, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[-3].minor.yy29, createNodeList(pCxt, createColumnNode(pCxt, NULL, &yymsp[-1].minor.yy0)))); } yymsp[-3].minor.yy182 = yylhsminor.yy182; break; case 284: /* expression ::= function_name NK_LP NK_RP */ { yylhsminor.yy182 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy29, &yymsp[0].minor.yy0, createFunctionNodeNoParam(pCxt, &yymsp[-2].minor.yy29)); } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 285: /* expression ::= function_name NK_LP expression AS type_name NK_RP */ { SNodeList *p = createNodeList(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy182)); p = addValueNodeFromTypeToList(pCxt, yymsp[-1].minor.yy574, p); yylhsminor.yy182 = createRawExprNodeExt(pCxt, &yymsp[-5].minor.yy29, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[-5].minor.yy29, p)); } yymsp[-5].minor.yy182 = yylhsminor.yy182; break; case 287: /* expression ::= NK_LP expression NK_RP */ case 330: /* boolean_primary ::= NK_LP boolean_value_expression NK_RP */ yytestcase(yyruleno==330); { yylhsminor.yy182 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0, releaseRawExprNode(pCxt, yymsp[-1].minor.yy182)); } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 288: /* expression ::= NK_PLUS expression */ { SToken t = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy182); yylhsminor.yy182 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &t, releaseRawExprNode(pCxt, yymsp[0].minor.yy182)); } yymsp[-1].minor.yy182 = yylhsminor.yy182; break; case 289: /* expression ::= NK_MINUS expression */ { SToken t = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy182); yylhsminor.yy182 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &t, createOperatorNode(pCxt, OP_TYPE_MINUS, releaseRawExprNode(pCxt, yymsp[0].minor.yy182), NULL)); } yymsp[-1].minor.yy182 = yylhsminor.yy182; break; case 290: /* expression ::= expression NK_PLUS expression */ { SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy182); SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy182); yylhsminor.yy182 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_ADD, releaseRawExprNode(pCxt, yymsp[-2].minor.yy182), releaseRawExprNode(pCxt, yymsp[0].minor.yy182))); } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 291: /* expression ::= expression NK_MINUS expression */ { SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy182); SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy182); yylhsminor.yy182 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_SUB, releaseRawExprNode(pCxt, yymsp[-2].minor.yy182), releaseRawExprNode(pCxt, yymsp[0].minor.yy182))); } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 292: /* expression ::= expression NK_STAR expression */ { SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy182); SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy182); yylhsminor.yy182 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_MULTI, releaseRawExprNode(pCxt, yymsp[-2].minor.yy182), releaseRawExprNode(pCxt, yymsp[0].minor.yy182))); } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 293: /* expression ::= expression NK_SLASH expression */ { SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy182); SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy182); yylhsminor.yy182 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_DIV, releaseRawExprNode(pCxt, yymsp[-2].minor.yy182), releaseRawExprNode(pCxt, yymsp[0].minor.yy182))); } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 294: /* expression ::= expression NK_REM expression */ { SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy182); SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy182); yylhsminor.yy182 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_MOD, releaseRawExprNode(pCxt, yymsp[-2].minor.yy182), releaseRawExprNode(pCxt, yymsp[0].minor.yy182))); } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 295: /* expression_list ::= expression */ { yylhsminor.yy334 = createNodeList(pCxt, releaseRawExprNode(pCxt, yymsp[0].minor.yy182)); } yymsp[0].minor.yy334 = yylhsminor.yy334; break; case 296: /* expression_list ::= expression_list NK_COMMA expression */ { yylhsminor.yy334 = addNodeToList(pCxt, yymsp[-2].minor.yy334, releaseRawExprNode(pCxt, yymsp[0].minor.yy182)); } yymsp[-2].minor.yy334 = yylhsminor.yy334; break; case 297: /* column_reference ::= column_name */ { yylhsminor.yy182 = createRawExprNode(pCxt, &yymsp[0].minor.yy29, createColumnNode(pCxt, NULL, &yymsp[0].minor.yy29)); } yymsp[0].minor.yy182 = yylhsminor.yy182; break; case 298: /* column_reference ::= table_name NK_DOT column_name */ { yylhsminor.yy182 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy29, &yymsp[0].minor.yy29, createColumnNode(pCxt, &yymsp[-2].minor.yy29, &yymsp[0].minor.yy29)); } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 299: /* pseudo_column ::= ROWTS */ case 300: /* pseudo_column ::= TBNAME */ yytestcase(yyruleno==300); case 301: /* pseudo_column ::= QSTARTTS */ yytestcase(yyruleno==301); case 302: /* pseudo_column ::= QENDTS */ yytestcase(yyruleno==302); case 303: /* pseudo_column ::= WSTARTTS */ yytestcase(yyruleno==303); case 304: /* pseudo_column ::= WENDTS */ yytestcase(yyruleno==304); case 305: /* pseudo_column ::= WDURATION */ yytestcase(yyruleno==305); { yylhsminor.yy182 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[0].minor.yy0, NULL)); } yymsp[0].minor.yy182 = yylhsminor.yy182; break; case 306: /* predicate ::= expression compare_op expression */ case 311: /* predicate ::= expression in_op in_predicate_value */ yytestcase(yyruleno==311); { SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy182); SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy182); yylhsminor.yy182 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, yymsp[-1].minor.yy380, releaseRawExprNode(pCxt, yymsp[-2].minor.yy182), releaseRawExprNode(pCxt, yymsp[0].minor.yy182))); } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 307: /* predicate ::= expression BETWEEN expression AND expression */ { SToken s = getTokenFromRawExprNode(pCxt, yymsp[-4].minor.yy182); SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy182); yylhsminor.yy182 = createRawExprNodeExt(pCxt, &s, &e, createBetweenAnd(pCxt, releaseRawExprNode(pCxt, yymsp[-4].minor.yy182), releaseRawExprNode(pCxt, yymsp[-2].minor.yy182), releaseRawExprNode(pCxt, yymsp[0].minor.yy182))); } yymsp[-4].minor.yy182 = yylhsminor.yy182; break; case 308: /* predicate ::= expression NOT BETWEEN expression AND expression */ { SToken s = getTokenFromRawExprNode(pCxt, yymsp[-5].minor.yy182); SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy182); yylhsminor.yy182 = createRawExprNodeExt(pCxt, &s, &e, createNotBetweenAnd(pCxt, releaseRawExprNode(pCxt, yymsp[-2].minor.yy182), releaseRawExprNode(pCxt, yymsp[-5].minor.yy182), releaseRawExprNode(pCxt, yymsp[0].minor.yy182))); } yymsp[-5].minor.yy182 = yylhsminor.yy182; break; case 309: /* predicate ::= expression IS NULL */ { SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy182); yylhsminor.yy182 = createRawExprNodeExt(pCxt, &s, &yymsp[0].minor.yy0, createOperatorNode(pCxt, OP_TYPE_IS_NULL, releaseRawExprNode(pCxt, yymsp[-2].minor.yy182), NULL)); } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 310: /* predicate ::= expression IS NOT NULL */ { SToken s = getTokenFromRawExprNode(pCxt, yymsp[-3].minor.yy182); yylhsminor.yy182 = createRawExprNodeExt(pCxt, &s, &yymsp[0].minor.yy0, createOperatorNode(pCxt, OP_TYPE_IS_NOT_NULL, releaseRawExprNode(pCxt, yymsp[-3].minor.yy182), NULL)); } yymsp[-3].minor.yy182 = yylhsminor.yy182; break; case 312: /* compare_op ::= NK_LT */ { yymsp[0].minor.yy380 = OP_TYPE_LOWER_THAN; } break; case 313: /* compare_op ::= NK_GT */ { yymsp[0].minor.yy380 = OP_TYPE_GREATER_THAN; } break; case 314: /* compare_op ::= NK_LE */ { yymsp[0].minor.yy380 = OP_TYPE_LOWER_EQUAL; } break; case 315: /* compare_op ::= NK_GE */ { yymsp[0].minor.yy380 = OP_TYPE_GREATER_EQUAL; } break; case 316: /* compare_op ::= NK_NE */ { yymsp[0].minor.yy380 = OP_TYPE_NOT_EQUAL; } break; case 317: /* compare_op ::= NK_EQ */ { yymsp[0].minor.yy380 = OP_TYPE_EQUAL; } break; case 318: /* compare_op ::= LIKE */ { yymsp[0].minor.yy380 = OP_TYPE_LIKE; } break; case 319: /* compare_op ::= NOT LIKE */ { yymsp[-1].minor.yy380 = OP_TYPE_NOT_LIKE; } break; case 320: /* compare_op ::= MATCH */ { yymsp[0].minor.yy380 = OP_TYPE_MATCH; } break; case 321: /* compare_op ::= NMATCH */ { yymsp[0].minor.yy380 = OP_TYPE_NMATCH; } break; case 322: /* in_op ::= IN */ { yymsp[0].minor.yy380 = OP_TYPE_IN; } break; case 323: /* in_op ::= NOT IN */ { yymsp[-1].minor.yy380 = OP_TYPE_NOT_IN; } break; case 324: /* in_predicate_value ::= NK_LP expression_list NK_RP */ { yylhsminor.yy182 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0, createNodeListNode(pCxt, yymsp[-1].minor.yy334)); } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 326: /* boolean_value_expression ::= NOT boolean_primary */ { SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy182); yylhsminor.yy182 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &e, createLogicConditionNode(pCxt, LOGIC_COND_TYPE_NOT, releaseRawExprNode(pCxt, yymsp[0].minor.yy182), NULL)); } yymsp[-1].minor.yy182 = yylhsminor.yy182; break; case 327: /* boolean_value_expression ::= boolean_value_expression OR boolean_value_expression */ { SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy182); SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy182); yylhsminor.yy182 = createRawExprNodeExt(pCxt, &s, &e, createLogicConditionNode(pCxt, LOGIC_COND_TYPE_OR, releaseRawExprNode(pCxt, yymsp[-2].minor.yy182), releaseRawExprNode(pCxt, yymsp[0].minor.yy182))); } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 328: /* boolean_value_expression ::= boolean_value_expression AND boolean_value_expression */ { SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy182); SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy182); yylhsminor.yy182 = createRawExprNodeExt(pCxt, &s, &e, createLogicConditionNode(pCxt, LOGIC_COND_TYPE_AND, releaseRawExprNode(pCxt, yymsp[-2].minor.yy182), releaseRawExprNode(pCxt, yymsp[0].minor.yy182))); } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 333: /* from_clause ::= FROM table_reference_list */ case 363: /* where_clause_opt ::= WHERE search_condition */ yytestcase(yyruleno==363); case 386: /* having_clause_opt ::= HAVING search_condition */ yytestcase(yyruleno==386); { yymsp[-1].minor.yy182 = yymsp[0].minor.yy182; } break; case 335: /* table_reference_list ::= table_reference_list NK_COMMA table_reference */ { yylhsminor.yy182 = createJoinTableNode(pCxt, JOIN_TYPE_INNER, yymsp[-2].minor.yy182, yymsp[0].minor.yy182, NULL); } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 338: /* table_primary ::= table_name alias_opt */ { yylhsminor.yy182 = createRealTableNode(pCxt, NULL, &yymsp[-1].minor.yy29, &yymsp[0].minor.yy29); } yymsp[-1].minor.yy182 = yylhsminor.yy182; break; case 339: /* table_primary ::= db_name NK_DOT table_name alias_opt */ { yylhsminor.yy182 = createRealTableNode(pCxt, &yymsp[-3].minor.yy29, &yymsp[-1].minor.yy29, &yymsp[0].minor.yy29); } yymsp[-3].minor.yy182 = yylhsminor.yy182; break; case 340: /* table_primary ::= subquery alias_opt */ { yylhsminor.yy182 = createTempTableNode(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy182), &yymsp[0].minor.yy29); } yymsp[-1].minor.yy182 = yylhsminor.yy182; break; case 342: /* alias_opt ::= */ { yymsp[1].minor.yy29 = nil_token; } break; case 343: /* alias_opt ::= table_alias */ { yylhsminor.yy29 = yymsp[0].minor.yy29; } yymsp[0].minor.yy29 = yylhsminor.yy29; break; case 344: /* alias_opt ::= AS table_alias */ { yymsp[-1].minor.yy29 = yymsp[0].minor.yy29; } break; case 345: /* parenthesized_joined_table ::= NK_LP joined_table NK_RP */ case 346: /* parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP */ yytestcase(yyruleno==346); { yymsp[-2].minor.yy182 = yymsp[-1].minor.yy182; } break; case 347: /* joined_table ::= table_reference join_type JOIN table_reference ON search_condition */ { yylhsminor.yy182 = createJoinTableNode(pCxt, yymsp[-4].minor.yy162, yymsp[-5].minor.yy182, yymsp[-2].minor.yy182, yymsp[0].minor.yy182); } yymsp[-5].minor.yy182 = yylhsminor.yy182; break; case 348: /* join_type ::= */ { yymsp[1].minor.yy162 = JOIN_TYPE_INNER; } break; case 349: /* join_type ::= INNER */ { yymsp[0].minor.yy162 = JOIN_TYPE_INNER; } break; case 350: /* 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.yy182 = createSelectStmt(pCxt, yymsp[-7].minor.yy47, yymsp[-6].minor.yy334, yymsp[-5].minor.yy182); yymsp[-8].minor.yy182 = addWhereClause(pCxt, yymsp[-8].minor.yy182, yymsp[-4].minor.yy182); yymsp[-8].minor.yy182 = addPartitionByClause(pCxt, yymsp[-8].minor.yy182, yymsp[-3].minor.yy334); yymsp[-8].minor.yy182 = addWindowClauseClause(pCxt, yymsp[-8].minor.yy182, yymsp[-2].minor.yy182); yymsp[-8].minor.yy182 = addGroupByClause(pCxt, yymsp[-8].minor.yy182, yymsp[-1].minor.yy334); yymsp[-8].minor.yy182 = addHavingClause(pCxt, yymsp[-8].minor.yy182, yymsp[0].minor.yy182); } break; case 353: /* set_quantifier_opt ::= ALL */ { yymsp[0].minor.yy47 = false; } break; case 354: /* select_list ::= NK_STAR */ { yymsp[0].minor.yy334 = NULL; } break; case 359: /* select_item ::= common_expression column_alias */ { yylhsminor.yy182 = setProjectionAlias(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy182), &yymsp[0].minor.yy29); } yymsp[-1].minor.yy182 = yylhsminor.yy182; break; case 360: /* select_item ::= common_expression AS column_alias */ { yylhsminor.yy182 = setProjectionAlias(pCxt, releaseRawExprNode(pCxt, yymsp[-2].minor.yy182), &yymsp[0].minor.yy29); } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 361: /* select_item ::= table_name NK_DOT NK_STAR */ { yylhsminor.yy182 = createColumnNode(pCxt, &yymsp[-2].minor.yy29, &yymsp[0].minor.yy0); } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 365: /* partition_by_clause_opt ::= PARTITION BY expression_list */ case 382: /* group_by_clause_opt ::= GROUP BY group_by_list */ yytestcase(yyruleno==382); case 392: /* order_by_clause_opt ::= ORDER BY sort_specification_list */ yytestcase(yyruleno==392); { yymsp[-2].minor.yy334 = yymsp[0].minor.yy334; } break; case 367: /* twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA duration_literal NK_RP */ { yymsp[-5].minor.yy182 = createSessionWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy182), releaseRawExprNode(pCxt, yymsp[-1].minor.yy182)); } break; case 368: /* twindow_clause_opt ::= STATE_WINDOW NK_LP expression NK_RP */ { yymsp[-3].minor.yy182 = createStateWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy182)); } break; case 369: /* twindow_clause_opt ::= INTERVAL NK_LP duration_literal NK_RP sliding_opt fill_opt */ { yymsp[-5].minor.yy182 = createIntervalWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy182), NULL, yymsp[-1].minor.yy182, yymsp[0].minor.yy182); } break; case 370: /* twindow_clause_opt ::= INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt fill_opt */ { yymsp[-7].minor.yy182 = createIntervalWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-5].minor.yy182), releaseRawExprNode(pCxt, yymsp[-3].minor.yy182), yymsp[-1].minor.yy182, yymsp[0].minor.yy182); } break; case 372: /* sliding_opt ::= SLIDING NK_LP duration_literal NK_RP */ { yymsp[-3].minor.yy182 = releaseRawExprNode(pCxt, yymsp[-1].minor.yy182); } break; case 374: /* fill_opt ::= FILL NK_LP fill_mode NK_RP */ { yymsp[-3].minor.yy182 = createFillNode(pCxt, yymsp[-1].minor.yy144, NULL); } break; case 375: /* fill_opt ::= FILL NK_LP VALUE NK_COMMA literal_list NK_RP */ { yymsp[-5].minor.yy182 = createFillNode(pCxt, FILL_MODE_VALUE, createNodeListNode(pCxt, yymsp[-1].minor.yy334)); } break; case 376: /* fill_mode ::= NONE */ { yymsp[0].minor.yy144 = FILL_MODE_NONE; } break; case 377: /* fill_mode ::= PREV */ { yymsp[0].minor.yy144 = FILL_MODE_PREV; } break; case 378: /* fill_mode ::= NULL */ { yymsp[0].minor.yy144 = FILL_MODE_NULL; } break; case 379: /* fill_mode ::= LINEAR */ { yymsp[0].minor.yy144 = FILL_MODE_LINEAR; } break; case 380: /* fill_mode ::= NEXT */ { yymsp[0].minor.yy144 = FILL_MODE_NEXT; } break; case 383: /* group_by_list ::= expression */ { yylhsminor.yy334 = createNodeList(pCxt, createGroupingSetNode(pCxt, releaseRawExprNode(pCxt, yymsp[0].minor.yy182))); } yymsp[0].minor.yy334 = yylhsminor.yy334; break; case 384: /* group_by_list ::= group_by_list NK_COMMA expression */ { yylhsminor.yy334 = addNodeToList(pCxt, yymsp[-2].minor.yy334, createGroupingSetNode(pCxt, releaseRawExprNode(pCxt, yymsp[0].minor.yy182))); } yymsp[-2].minor.yy334 = yylhsminor.yy334; break; case 387: /* query_expression ::= query_expression_body order_by_clause_opt slimit_clause_opt limit_clause_opt */ { yylhsminor.yy182 = addOrderByClause(pCxt, yymsp[-3].minor.yy182, yymsp[-2].minor.yy334); yylhsminor.yy182 = addSlimitClause(pCxt, yylhsminor.yy182, yymsp[-1].minor.yy182); yylhsminor.yy182 = addLimitClause(pCxt, yylhsminor.yy182, yymsp[0].minor.yy182); } yymsp[-3].minor.yy182 = yylhsminor.yy182; break; case 389: /* query_expression_body ::= query_expression_body UNION ALL query_expression_body */ { yylhsminor.yy182 = createSetOperator(pCxt, SET_OP_TYPE_UNION_ALL, yymsp[-3].minor.yy182, yymsp[0].minor.yy182); } yymsp[-3].minor.yy182 = yylhsminor.yy182; break; case 394: /* slimit_clause_opt ::= SLIMIT NK_INTEGER */ case 398: /* limit_clause_opt ::= LIMIT NK_INTEGER */ yytestcase(yyruleno==398); { yymsp[-1].minor.yy182 = createLimitNode(pCxt, &yymsp[0].minor.yy0, NULL); } break; case 395: /* slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER */ case 399: /* limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER */ yytestcase(yyruleno==399); { yymsp[-3].minor.yy182 = createLimitNode(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0); } break; case 396: /* slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER */ case 400: /* limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER */ yytestcase(yyruleno==400); { yymsp[-3].minor.yy182 = createLimitNode(pCxt, &yymsp[0].minor.yy0, &yymsp[-2].minor.yy0); } break; case 401: /* subquery ::= NK_LP query_expression NK_RP */ { yylhsminor.yy182 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0, yymsp[-1].minor.yy182); } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 405: /* sort_specification ::= expression ordering_specification_opt null_ordering_opt */ { yylhsminor.yy182 = createOrderByExprNode(pCxt, releaseRawExprNode(pCxt, yymsp[-2].minor.yy182), yymsp[-1].minor.yy218, yymsp[0].minor.yy487); } yymsp[-2].minor.yy182 = yylhsminor.yy182; break; case 406: /* ordering_specification_opt ::= */ { yymsp[1].minor.yy218 = ORDER_ASC; } break; case 407: /* ordering_specification_opt ::= ASC */ { yymsp[0].minor.yy218 = ORDER_ASC; } break; case 408: /* ordering_specification_opt ::= DESC */ { yymsp[0].minor.yy218 = ORDER_DESC; } break; case 409: /* null_ordering_opt ::= */ { yymsp[1].minor.yy487 = NULL_ORDER_DEFAULT; } break; case 410: /* null_ordering_opt ::= NULLS FIRST */ { yymsp[-1].minor.yy487 = NULL_ORDER_FIRST; } break; case 411: /* null_ordering_opt ::= NULLS LAST */ { yymsp[-1].minor.yy487 = NULL_ORDER_LAST; } break; default: break; /********** End reduce actions ************************************************/ }; assert( yyrulenoYY_MAX_SHIFT && yyact<=YY_MAX_SHIFTREDUCE) ); /* It is not possible for a REDUCE to be followed by an error */ assert( yyact!=YY_ERROR_ACTION ); yymsp += yysize+1; yypParser->yytos = yymsp; yymsp->stateno = (YYACTIONTYPE)yyact; yymsp->major = (YYCODETYPE)yygoto; yyTraceShift(yypParser, yyact, "... then shift"); return yyact; } /* ** The following code executes when the parse fails */ #ifndef YYNOERRORRECOVERY static void yy_parse_failed( yyParser *yypParser /* The parser */ ){ ParseARG_FETCH ParseCTX_FETCH #ifndef NDEBUG if( yyTraceFILE ){ fprintf(yyTraceFILE,"%sFail!\n",yyTracePrompt); } #endif while( yypParser->yytos>yypParser->yystack ) yy_pop_parser_stack(yypParser); /* Here code is inserted which will be executed whenever the ** parser fails */ /************ Begin %parse_failure code ***************************************/ /************ End %parse_failure code *****************************************/ ParseARG_STORE /* Suppress warning about unused %extra_argument variable */ ParseCTX_STORE } #endif /* YYNOERRORRECOVERY */ /* ** The following code executes when a syntax error first occurs. */ static void yy_syntax_error( yyParser *yypParser, /* The parser */ int yymajor, /* The major type of the error token */ ParseTOKENTYPE yyminor /* The minor type of the error token */ ){ ParseARG_FETCH ParseCTX_FETCH #define TOKEN yyminor /************ Begin %syntax_error code ****************************************/ if (pCxt->valid) { if(TOKEN.z) { generateSyntaxErrMsg(&pCxt->msgBuf, TSDB_CODE_PAR_SYNTAX_ERROR, TOKEN.z); } else { generateSyntaxErrMsg(&pCxt->msgBuf, TSDB_CODE_PAR_INCOMPLETE_SQL); } pCxt->valid = false; } /************ End %syntax_error code ******************************************/ ParseARG_STORE /* Suppress warning about unused %extra_argument variable */ ParseCTX_STORE } /* ** The following is executed when the parser accepts */ static void yy_accept( yyParser *yypParser /* The parser */ ){ ParseARG_FETCH ParseCTX_FETCH #ifndef NDEBUG if( yyTraceFILE ){ fprintf(yyTraceFILE,"%sAccept!\n",yyTracePrompt); } #endif #ifndef YYNOERRORRECOVERY yypParser->yyerrcnt = -1; #endif assert( yypParser->yytos==yypParser->yystack ); /* Here code is inserted which will be executed whenever the ** parser accepts */ /*********** Begin %parse_accept code *****************************************/ /*********** End %parse_accept code *******************************************/ ParseARG_STORE /* Suppress warning about unused %extra_argument variable */ ParseCTX_STORE } /* The main parser program. ** The first argument is a pointer to a structure obtained from ** "ParseAlloc" which describes the current state of the parser. ** The second argument is the major token number. The third is ** the minor token. The fourth optional argument is whatever the ** user wants (and specified in the grammar) and is available for ** use by the action routines. ** ** Inputs: **
    **
  • A pointer to the parser (an opaque structure.) **
  • The major token number. **
  • The minor token number. **
  • An option argument of a grammar-specified type. **
** ** Outputs: ** None. */ void Parse( void *yyp, /* The parser */ int yymajor, /* The major token code number */ ParseTOKENTYPE yyminor /* The value for the token */ ParseARG_PDECL /* Optional %extra_argument parameter */ ){ YYMINORTYPE yyminorunion; YYACTIONTYPE yyact; /* The parser action. */ #if !defined(YYERRORSYMBOL) && !defined(YYNOERRORRECOVERY) int yyendofinput; /* True if we are at the end of input */ #endif #ifdef YYERRORSYMBOL int yyerrorhit = 0; /* True if yymajor has invoked an error */ #endif yyParser *yypParser = (yyParser*)yyp; /* The parser */ ParseCTX_FETCH ParseARG_STORE assert( yypParser->yytos!=0 ); #if !defined(YYERRORSYMBOL) && !defined(YYNOERRORRECOVERY) yyendofinput = (yymajor==0); #endif yyact = yypParser->yytos->stateno; #ifndef NDEBUG if( yyTraceFILE ){ if( yyact < YY_MIN_REDUCE ){ fprintf(yyTraceFILE,"%sInput '%s' in state %d\n", yyTracePrompt,yyTokenName[yymajor],yyact); }else{ fprintf(yyTraceFILE,"%sInput '%s' with pending reduce %d\n", yyTracePrompt,yyTokenName[yymajor],yyact-YY_MIN_REDUCE); } } #endif do{ assert( yyact==yypParser->yytos->stateno ); yyact = yy_find_shift_action((YYCODETYPE)yymajor,yyact); if( yyact >= YY_MIN_REDUCE ){ yyact = yy_reduce(yypParser,yyact-YY_MIN_REDUCE,yymajor, yyminor ParseCTX_PARAM); }else if( yyact <= YY_MAX_SHIFTREDUCE ){ yy_shift(yypParser,yyact,(YYCODETYPE)yymajor,yyminor); #ifndef YYNOERRORRECOVERY yypParser->yyerrcnt--; #endif break; }else if( yyact==YY_ACCEPT_ACTION ){ yypParser->yytos--; yy_accept(yypParser); return; }else{ assert( yyact == YY_ERROR_ACTION ); yyminorunion.yy0 = yyminor; #ifdef YYERRORSYMBOL int yymx; #endif #ifndef NDEBUG if( yyTraceFILE ){ fprintf(yyTraceFILE,"%sSyntax Error!\n",yyTracePrompt); } #endif #ifdef YYERRORSYMBOL /* A syntax error has occurred. ** The response to an error depends upon whether or not the ** grammar defines an error token "ERROR". ** ** This is what we do if the grammar does define ERROR: ** ** * Call the %syntax_error function. ** ** * Begin popping the stack until we enter a state where ** it is legal to shift the error symbol, then shift ** the error symbol. ** ** * Set the error count to three. ** ** * Begin accepting and shifting new tokens. No new error ** processing will occur until three tokens have been ** shifted successfully. ** */ if( yypParser->yyerrcnt<0 ){ yy_syntax_error(yypParser,yymajor,yyminor); } yymx = yypParser->yytos->major; if( yymx==YYERRORSYMBOL || yyerrorhit ){ #ifndef NDEBUG if( yyTraceFILE ){ fprintf(yyTraceFILE,"%sDiscard input token %s\n", yyTracePrompt,yyTokenName[yymajor]); } #endif yy_destructor(yypParser, (YYCODETYPE)yymajor, &yyminorunion); yymajor = YYNOCODE; }else{ while( yypParser->yytos >= yypParser->yystack && (yyact = yy_find_reduce_action( yypParser->yytos->stateno, YYERRORSYMBOL)) > YY_MAX_SHIFTREDUCE ){ yy_pop_parser_stack(yypParser); } if( yypParser->yytos < yypParser->yystack || yymajor==0 ){ yy_destructor(yypParser,(YYCODETYPE)yymajor,&yyminorunion); yy_parse_failed(yypParser); #ifndef YYNOERRORRECOVERY yypParser->yyerrcnt = -1; #endif yymajor = YYNOCODE; }else if( yymx!=YYERRORSYMBOL ){ yy_shift(yypParser,yyact,YYERRORSYMBOL,yyminor); } } yypParser->yyerrcnt = 3; yyerrorhit = 1; if( yymajor==YYNOCODE ) break; yyact = yypParser->yytos->stateno; #elif defined(YYNOERRORRECOVERY) /* If the YYNOERRORRECOVERY macro is defined, then do not attempt to ** do any kind of error recovery. Instead, simply invoke the syntax ** error routine and continue going as if nothing had happened. ** ** Applications can set this macro (for example inside %include) if ** they intend to abandon the parse upon the first syntax error seen. */ yy_syntax_error(yypParser,yymajor, yyminor); yy_destructor(yypParser,(YYCODETYPE)yymajor,&yyminorunion); break; #else /* YYERRORSYMBOL is not defined */ /* This is what we do if the grammar does not define ERROR: ** ** * Report an error message, and throw away the input token. ** ** * If the input token is $, then fail the parse. ** ** As before, subsequent error messages are suppressed until ** three input tokens have been successfully shifted. */ if( yypParser->yyerrcnt<=0 ){ yy_syntax_error(yypParser,yymajor, yyminor); } yypParser->yyerrcnt = 3; yy_destructor(yypParser,(YYCODETYPE)yymajor,&yyminorunion); if( yyendofinput ){ yy_parse_failed(yypParser); #ifndef YYNOERRORRECOVERY yypParser->yyerrcnt = -1; #endif } break; #endif } }while( yypParser->yytos>yypParser->yystack ); #ifndef NDEBUG if( yyTraceFILE ){ yyStackEntry *i; char cDiv = '['; fprintf(yyTraceFILE,"%sReturn. Stack=",yyTracePrompt); for(i=&yypParser->yystack[1]; i<=yypParser->yytos; i++){ fprintf(yyTraceFILE,"%c%s", cDiv, yyTokenName[i->major]); cDiv = ' '; } fprintf(yyTraceFILE,"]\n"); } #endif return; } /* ** Return the fallback token corresponding to canonical token iToken, or ** 0 if iToken has no fallback. */ int ParseFallback(int iToken){ #ifdef YYFALLBACK assert( iToken<(int)(sizeof(yyFallback)/sizeof(yyFallback[0])) ); return yyFallback[iToken]; #else (void)iToken; return 0; #endif }