sql.c 287.3 KB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24
/*
** 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:
*/
X
Xiaoyu Wang 已提交
25 26
#include <stdio.h>
#include <assert.h>
27
/************ Begin %include sections from the grammar ************************/
X
Xiaoyu Wang 已提交
28

29 30 31 32 33 34
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <assert.h>
#include <stdbool.h>

D
dapan1121 已提交
35 36
#define ALLOW_FORBID_FUNC

37
#include "functionMgt.h"
38
#include "nodes.h"
X
Xiaoyu Wang 已提交
39
#include "parToken.h"
40
#include "ttokendef.h"
X
Xiaoyu Wang 已提交
41
#include "parAst.h"
D
dapan1121 已提交
42 43

#define YYSTACKDEPTH 0
44
/**************** End of %include directives **********************************/
X
Xiaoyu Wang 已提交
45 46 47 48 49
/* 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 ***************************/
50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66

/* 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.
X
Xiaoyu Wang 已提交
67
**    ParseTOKENTYPE     is the data type used for minor type for terminal
68 69 70 71 72 73 74 75 76 77
**                       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
X
Xiaoyu Wang 已提交
78
**                       which is ParseTOKENTYPE.  The entry in the union
79 80
**                       for terminal symbols is called "yy0".
**    YYSTACKDEPTH       is the maximum depth of the parser's stack.  If
X
Xiaoyu Wang 已提交
81
**                       zero the stack is dynamically sized using realloc()
X
Xiaoyu Wang 已提交
82 83 84 85 86 87
**    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
88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105
**    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 *****************************************/
X
Xiaoyu Wang 已提交
106
#define YYCODETYPE unsigned short int
107
#define YYNOCODE 460
108
#define YYACTIONTYPE unsigned short int
X
Xiaoyu Wang 已提交
109
#define ParseTOKENTYPE  SToken 
110 111
typedef union {
  int yyinit;
X
Xiaoyu Wang 已提交
112
  ParseTOKENTYPE yy0;
113 114 115 116 117 118 119 120 121 122 123 124 125 126
  SAlterOption yy5;
  bool yy57;
  EFillMode yy214;
  EJoinType yy332;
  int32_t yy340;
  int8_t yy383;
  SDataType yy384;
  SNodeList* yy424;
  EOrder yy538;
  EOperatorType yy620;
  SNode* yy752;
  ENullOrder yy777;
  SToken yy849;
  int64_t yy869;
127 128 129 130
} YYMINORTYPE;
#ifndef YYSTACKDEPTH
#define YYSTACKDEPTH 100
#endif
X
Xiaoyu Wang 已提交
131 132 133 134 135 136 137 138 139 140
#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
X
Xiaoyu Wang 已提交
141
#define YYFALLBACK 1
X
Xiaoyu Wang 已提交
142
#define YYNSTATE             714
143
#define YYNRULE              544
X
Xiaoyu Wang 已提交
144
#define YYNTOKEN             324
X
Xiaoyu Wang 已提交
145
#define YY_MAX_SHIFT         713
146 147 148 149 150 151 152
#define YY_MIN_SHIFTREDUCE   1060
#define YY_MAX_SHIFTREDUCE   1603
#define YY_ERROR_ACTION      1604
#define YY_ACCEPT_ACTION     1605
#define YY_NO_ACTION         1606
#define YY_MIN_REDUCE        1607
#define YY_MAX_REDUCE        2150
153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218
/************* 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 **********************************************/
219
#define YY_ACTTAB_COUNT (3067)
220
static const YYACTIONTYPE yy_action[] = {
221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527
 /*     0 */  1749,  407,  460, 1874,  461, 1643,  469,  367,  461, 1643,
 /*    10 */  1806, 1808,   45,   43, 1533, 1952, 1872,  590, 1630,  466,
 /*    20 */   362, 1745, 1384,   38,   37,  462, 1948,   44,   42,   41,
 /*    30 */    40,   39,  169, 1463,  459, 1382,  229,  464, 1649, 1790,
 /*    40 */   571,  320,   38,   37, 2121, 1813,   44,   42,   41,   40,
 /*    50 */    39,  602,  355,  334, 1860, 1944, 1950,  345, 1458,  570,
 /*    60 */   175, 1811, 1934,   18, 2122,  572,  613,   38,   37, 1965,
 /*    70 */  1390,   44,   42,   41,   40,   39,  468, 1410,  583,  464,
 /*    80 */  1649,   38,   37,   45,   43,   44,   42,   41,   40,   39,
 /*    90 */   354,  362,  171, 1384, 1607,   14,  603,  327,  157, 1112,
 /*   100 */  1983, 1111, 2125,   27, 1463, 1800, 1382, 1762,  586,  134,
 /*   110 */    54, 1570,  602, 1934,  603,  619, 1410,  710,  125,  124,
 /*   120 */   123,  122,  121,  120,  119,  118,  117, 1760,  126, 1458,
 /*   130 */  1113, 1605, 1465, 1466,   18,  499,   35,  276, 1492, 1964,
 /*   140 */    84, 1390,  478, 1999,   64, 1760,  103, 1966,  623, 1968,
 /*   150 */  1969,  618,  602,  613,  130, 2126, 1807, 1808,  172, 2121,
 /*   160 */  2052, 1439, 1448, 1755,  356, 2048,   14, 1464, 1467,  257,
 /*   170 */  2060,  582, 1738,  127,  581, 2125,   84, 2121,  177, 2122,
 /*   180 */  2124, 2126, 1385, 2126, 1383, 2121, 2078,   48,  710, 1262,
 /*   190 */  1263,  160,  570,  175, 1493,  377, 1714, 2122,  572, 1756,
 /*   200 */  1411, 2125, 1409, 1465, 1466, 2122, 2123, 1388, 1389,  396,
 /*   210 */  1438, 1441, 1442, 1443, 1444, 1445, 1446, 1447,  615,  611,
 /*   220 */  1456, 1457, 1459, 1460, 1461, 1462,    2,   48, 1329, 1330,
 /*   230 */   398,  394, 1439, 1448,  478,   60,  156,  547, 1464, 1467,
 /*   240 */   116, 2121,  648,  115,  114,  113,  112,  111,  110,  109,
 /*   250 */   108,  107,  339, 1385, 1560, 1383, 2127,  175,   41,   40,
 /*   260 */    39, 2122,  572, 1328, 1331,   34,  360, 1487, 1488, 1489,
 /*   270 */  1490, 1491, 1495, 1496, 1497, 1498, 1593,   60, 1388, 1389,
 /*   280 */   260, 1438, 1441, 1442, 1443, 1444, 1445, 1446, 1447,  615,
 /*   290 */   611, 1456, 1457, 1459, 1460, 1461, 1462,    2,  169,   11,
 /*   300 */    45,   43,  558, 1558, 1559, 1561, 1562,  159,  362, 1619,
 /*   310 */  1384, 1093,  227,  340,  566,  338,  337,   60,  501,   89,
 /*   320 */  1861, 1463,  503, 1382, 1219,  645,  644,  643, 1223,  642,
 /*   330 */  1225, 1226,  641, 1228,  638, 1676, 1234,  635, 1236, 1237,
 /*   340 */   632,  629,  213,  259,  502, 1952, 1458, 1409, 1751,  401,
 /*   350 */  1095,   18, 1098, 1099, 1813,   11, 1948,  164, 1390, 1948,
 /*   360 */   365,  366,  574,  495,  491,  487,  483,  210,  157,   60,
 /*   370 */  1811,   45,   43, 1468,   86,  322,  178, 1762,  532,  362,
 /*   380 */   530, 1384, 1983,   14,  178, 1944, 1950,  357, 1944, 1950,
 /*   390 */   565,  547, 1463,   49, 1382, 2121,  613,  510,  509,  613,
 /*   400 */   514,  513,  512,   85, 1411,  710,  208, 1608,  131,  508,
 /*   410 */  2127,  175,   11,  507,    9, 2122,  572, 1458,  506,  511,
 /*   420 */  1465, 1466,  267,  268,  505, 1737,  178,  266,  116, 1390,
 /*   430 */   564,  115,  114,  113,  112,  111,  110,  109,  108,  107,
 /*   440 */    38,   37,  681,  679,   44,   42,   41,   40,   39, 1439,
 /*   450 */  1448,  368, 1412, 1813,   46, 1464, 1467,   38,   37,  157,
 /*   460 */   331,   44,   42,   41,   40,   39,  178, 2067, 1762, 1811,
 /*   470 */  1385, 1537, 1383,  207,  201,   60,  710, 1409,  206,   38,
 /*   480 */    37,  474,  657,   44,   42,   41,   40,   39, 1315, 1316,
 /*   490 */  1393, 1465, 1466, 2064, 1629, 1388, 1389,  199, 1438, 1441,
 /*   500 */  1442, 1443, 1444, 1445, 1446, 1447,  615,  611, 1456, 1457,
 /*   510 */  1459, 1460, 1461, 1462,    2,  514,  513,  512,  178, 1409,
 /*   520 */  1439, 1448,  528,  131,  508,  571, 1464, 1467,  507, 2121,
 /*   530 */  1179, 2067,  655,  506,  511,  526, 2067,  524, 1934,  505,
 /*   540 */  1408, 1385,  178, 1383,  570,  175,  100,  259, 1628, 2122,
 /*   550 */   572,  148,  147,  652,  651,  650,  145, 2063,  583,  589,
 /*   560 */   135,  400, 2062,  399, 1627, 1181, 1388, 1389, 1752, 1438,
 /*   570 */  1441, 1442, 1443, 1444, 1445, 1446, 1447,  615,  611, 1456,
 /*   580 */  1457, 1459, 1460, 1461, 1462,    2,   45,   43,  603,  134,
 /*   590 */  1384, 1473, 1934, 1843,  362,  237, 1384, 1409,  713,   52,
 /*   600 */  1874,  547,  180, 1382,  187, 2121,  546, 1463, 1934, 1382,
 /*   610 */   353,  146,  283, 1871,  590,  603, 1965, 1736, 1440, 1760,
 /*   620 */  2127,  175,  375, 1600,  178, 2122,  572,  168,  583,  405,
 /*   630 */  1953, 1856, 1458,  703,  699,  695,  691,  281, 1390, 1396,
 /*   640 */    81, 1948,  183,   80, 1390, 1856, 1760, 1983,  585,  173,
 /*   650 */  2060, 2061,   94,  132, 2065,  617,  185,   45,   43,  134,
 /*   660 */  1934,  603,  619,   53,  547,  362, 1494, 1384, 2121,   46,
 /*   670 */  1944, 1950, 1626,  101, 1753,  126,  274,  583, 1463,  657,
 /*   680 */  1382,  613,  504, 2127,  175,  710, 1964,  443, 2122,  572,
 /*   690 */  1999,  710, 1760,  312, 1966,  623, 1968, 1969,  618,  616,
 /*   700 */   613,  604, 2017, 1458, 1735, 1625, 1465, 1466,  134,  599,
 /*   710 */    44,   42,   41,   40,   39, 1390, 1934, 1599,  561,  174,
 /*   720 */  2060, 2061, 1624,  132, 2065,  136,   38,   37, 2023, 1747,
 /*   730 */    44,   42,   41,   40,   39, 1439, 1448,   32, 1440, 1623,
 /*   740 */    14, 1464, 1467,  603,  424,  191,  190, 1499,  262, 1934,
 /*   750 */  1385,  605, 1383, 2024,   13,   12, 1385,  406, 1383,  228,
 /*   760 */  1622,  607,  710, 2024, 1412, 1355, 1934,  231,  176, 2060,
 /*   770 */  2061, 1412,  132, 2065, 1760, 1388, 1389, 1465, 1466,    8,
 /*   780 */   374, 1388, 1389, 1934, 1438, 1441, 1442, 1443, 1444, 1445,
 /*   790 */  1446, 1447,  615,  611, 1456, 1457, 1459, 1460, 1461, 1462,
 /*   800 */     2,  567,  562,  556, 1934,  603, 1439, 1448,  319,  157,
 /*   810 */  1407,  655, 1464, 1467, 1549, 2072, 1526,  437, 1763,  415,
 /*   820 */   450, 1813,  547,  449, 1361, 1362, 2121, 1385, 1856, 1383,
 /*   830 */   148,  147,  652,  651,  650,  145, 1760, 1812,  421,  189,
 /*   840 */   451, 2127,  175,  423, 1409, 1621, 2122,  572,  649, 1506,
 /*   850 */   575, 1804, 1388, 1389,  610, 1438, 1441, 1442, 1443, 1444,
 /*   860 */  1445, 1446, 1447,  615,  611, 1456, 1457, 1459, 1460, 1461,
 /*   870 */  1462,    2, 1618,  653, 1617,  670, 1804, 1730,  158,  654,
 /*   880 */  1616,   31, 1804,  296,  335, 1673,  603,   38,   37, 1934,
 /*   890 */  1530,   44,   42,   41,   40,   39,  411,  294,   70,   33,
 /*   900 */   429,   69, 1615, 1098, 1099,   38,   37,  184, 1390,   44,
 /*   910 */    42,   41,   40,   39,  236,  408, 1934, 1760, 1934,  195,
 /*   920 */   456,  454,  290,  669, 1934, 1790,  447,  542,  409,  442,
 /*   930 */   441,  440,  439,  436,  435,  434,  433,  432,  428,  427,
 /*   940 */   426,  425,  336,  418,  417,  416, 1934,  413,  412,  333,
 /*   950 */   687,  686,  685,  684,  372,   60,  683,  682,  138,  677,
 /*   960 */   676,  675,  674,  673,  672,  671,  150,  667,  666,  665,
 /*   970 */   371,  370,  662,  661,  660,  659,  658, 1112,  503, 1111,
 /*   980 */    50, 1921,    3, 1526,  235, 1440, 1614,  578, 1613, 1612,
 /*   990 */   603,  603,  212,  603,  102,  603,  655, 1611, 1484,  519,
 /*  1000 */   502,  140, 1392,  128,  430,  476, 1965,  477, 1113, 1757,
 /*  1010 */  1743,  603,  535,  603,  529,  148,  147,  652,  651,  650,
 /*  1020 */   145, 1760, 1760,   87, 1760,  142, 1760,  543,  226,  384,
 /*  1030 */  1934,  232, 1934, 1934,   78,   77,  404, 1983, 1610,  182,
 /*  1040 */   614, 1934, 1760,  522, 1760,  620,  218,  647,  516,  216,
 /*  1050 */  1934, 1650,  619,  225,  547, 1602, 1603,  318, 2121, 1141,
 /*  1060 */   392,   71,  390,  386,  382,  379,  376,  603, 1965,  220,
 /*  1070 */  1715,  576,  219, 2127,  175,   62, 1964,  603, 2122,  572,
 /*  1080 */  1999,  587, 1934,  103, 1966,  623, 1968, 1969,  618,   67,
 /*  1090 */   613,  271,   66,  137, 1142,  143, 2023, 2052, 1760, 1983,
 /*  1100 */   705,  356, 2048,  603,  178,  603,  603,  586, 1760,  603,
 /*  1110 */   603,   79, 1934,  222,  619,  224,  221,  598,  223,  600,
 /*  1120 */   601, 1663, 1965,  277,  369,  241,   47, 1557,  264,   99,
 /*  1130 */    68, 1529, 1656, 1654, 1760,  144, 1760, 1760, 1964,   96,
 /*  1140 */  1760, 1760, 1999,  515, 1620,  103, 1966,  623, 1968, 1969,
 /*  1150 */   618, 1395,  613, 1983,  517,  520,  146,  172, 2092, 2052,
 /*  1160 */   254,  620,   62,  356, 2048,  211, 1934,   47,  619,  663,
 /*  1170 */    13,   12,   47, 1955,  559,  664,  248,  243, 1326,  627,
 /*  1180 */   269, 1965,  595,  144, 1984, 2079,  146,  273,  129,  373,
 /*  1190 */   144, 1160, 1964, 1865, 2082, 1644, 1999, 1158,  584,  103,
 /*  1200 */  1966,  623, 1968, 1969,  618, 1801,  613,  256, 1212,  253,
 /*  1210 */   579, 2141, 1983, 2052, 1500,    1,  378,  356, 2048, 1449,
 /*  1220 */   620, 1957,    4,  383,  289, 1934, 1348,  619, 2086,  332,
 /*  1230 */   284, 1240,  188,  410, 1412, 1244,  445, 1866, 1251, 1407,
 /*  1240 */  1249,  414,  149,  419,  431, 1858,  438, 1965,  444,  446,
 /*  1250 */   452, 1964,  192,  455,  453, 1999,  457, 1413,  103, 1966,
 /*  1260 */   623, 1968, 1969,  618,  458,  613,  467, 1965,  470, 1415,
 /*  1270 */  2141,  198, 2052, 1410,  471,  200,  356, 2048, 1983, 1414,
 /*  1280 */   472, 1416,  203,  473,  475,  479,  620, 2099, 1115,  498,
 /*  1290 */   205, 1934,   82,  619,   83,  209,  496,  500, 1983,  497,
 /*  1300 */  1750,  106,  321,  215, 1746,  534,  620, 1911,  536,  285,
 /*  1310 */   217, 1934,  537,  619,  151,  538,  230, 1964,  544,  233,
 /*  1320 */   152, 1999, 1748, 1744,  103, 1966,  623, 1968, 1969,  618,
 /*  1330 */   153,  613,  154,  560, 1910, 2098, 2141, 1964, 2052,  551,
 /*  1340 */   593, 1999,  356, 2048,  103, 1966,  623, 1968, 1969,  618,
 /*  1350 */  2083,  613,  541,  554, 2097,  239, 2141,  557, 2052,  359,
 /*  1360 */   358,  346,  356, 2048, 1965, 2093,  242,  563,    7, 1398,
 /*  1370 */  2074,  569,  552, 2115,  247,  550,  549,  580, 2144, 1526,
 /*  1380 */  1463, 2120, 1391,  577,  347,  255,  252,  133, 1411,  588,
 /*  1390 */   286,  350, 2068,  591,  592, 1983,  261, 1882, 1881, 1880,
 /*  1400 */   352,  287,  597,  620,  596, 1458,   91,  288, 1934,   93,
 /*  1410 */   619, 1761,   59, 2033,   95,  165,  250, 1390,  625, 1805,
 /*  1420 */  1731,  706,  280, 1965,  249,  251,  709,  291,  707,   51,
 /*  1430 */   315,  295,  323,  293, 1964,  324, 1928,  300, 1999, 1927,
 /*  1440 */   314,  103, 1966,  623, 1968, 1969,  618,  304,  613,   75,
 /*  1450 */  1926, 1925,   76, 2141, 1983, 2052, 1922,  380,  381,  356,
 /*  1460 */  2048, 1376,  620, 1377,  609,  181,  385, 1934, 1920,  619,
 /*  1470 */  2071,  389,  387,  388, 1919,  391, 1918,  393, 1917,  395,
 /*  1480 */  1916,  397, 1351, 1350, 1893, 1892,  402,  403, 1891, 1890,
 /*  1490 */  1306, 1851, 1850, 1964, 1848,  139, 1847, 1999, 1846, 1849,
 /*  1500 */   103, 1966,  623, 1968, 1969,  618, 1845,  613, 1844, 1842,
 /*  1510 */  1841, 1840, 2027, 1965, 2052,  186,  420, 1839,  356, 2048,
 /*  1520 */   422, 1838, 1837, 1836, 1835, 1834, 1833, 1832, 1831, 1399,
 /*  1530 */  1830, 1394, 1829, 1828, 1827, 1826, 1825, 1824, 1823,  141,
 /*  1540 */  1822, 1821, 1820, 1819, 1983, 1818, 1817, 1816,  448, 1815,
 /*  1550 */  1814, 1308,  620, 1187, 1402, 1404, 1678, 1934,  193,  619,
 /*  1560 */  1677,  194, 1675, 1639,  170, 1101,  611, 1456, 1457, 1459,
 /*  1570 */  1460, 1461, 1462,  196, 1638, 1965, 1906, 1900,   73, 1100,
 /*  1580 */  1889,  204, 1888, 1964,  197, 1868, 1739, 1999, 1674, 1672,
 /*  1590 */   103, 1966,  623, 1968, 1969,  618,   74,  613, 1965, 1954,
 /*  1600 */   463,  465, 2025,  202, 2052,  480, 1983,  481,  356, 2048,
 /*  1610 */   482, 1670, 1134,  484,  620, 1668,  485,  489,  486, 1934,
 /*  1620 */   490,  619,  488, 1666, 1653,  492, 1652, 1635, 1741, 1983,
 /*  1630 */   494,  493, 1256, 1740, 1255, 1178, 1177,  620, 1176, 1175,
 /*  1640 */   678, 1172, 1934,  680,  619, 1964, 1664, 1170, 1171, 1999,
 /*  1650 */  1657, 1169,  103, 1966,  623, 1968, 1969,  618,  341,  613,
 /*  1660 */   518,  342,   61,  214,  606, 1965, 2052, 1655, 1964,  343,
 /*  1670 */   356, 2048, 1999, 1634, 1633,  104, 1966,  623, 1968, 1969,
 /*  1680 */   618, 1632,  613,  521,  523,  527,  525, 1366, 1965, 2052,
 /*  1690 */   105, 1368, 1365, 2051, 2048,  531, 1983,   26, 1905, 1357,
 /*  1700 */  1899,  155,  539, 1887,  620, 1885,   19, 2126,   16, 1934,
 /*  1710 */  1572,  619,   28,  238,  553,  555,  240, 1556,   55, 1983,
 /*  1720 */    58,  245,  246,   30,  163,  244,   29,  620, 1548,  540,
 /*  1730 */  1955,   20, 1934, 1592,  619, 1964,  344,  234,   88, 1999,
 /*  1740 */  1593,   63,  104, 1966,  623, 1968, 1969,  618, 1587,  613,
 /*  1750 */    21, 1965,   17, 1586,  348, 1591, 2052, 1590,  621,  349,
 /*  1760 */   608, 2048, 1999,  545,    5,  104, 1966,  623, 1968, 1969,
 /*  1770 */   618, 1965,  613,  258, 1523,    6,   57,  166, 1522, 2052,
 /*  1780 */  1886, 1884, 1983,  326, 2048, 1883,   22, 1867,  263, 1554,
 /*  1790 */   620,  265,  270,   90,   65, 1934,   92,  619,  275,  272,
 /*  1800 */   594,   23, 1983,   12,   10, 1485, 1400,   96, 1453, 2002,
 /*  1810 */   620,  612,  167, 1451,  179, 1934,   36,  619, 1431, 1450,
 /*  1820 */  1475, 1964,   15,  626,   24, 1999,  364, 1423,  161, 1966,
 /*  1830 */   623, 1968, 1969,  618, 1474,  613,   25,  630, 1241,  624,
 /*  1840 */  1965, 1964,  628,  633, 1238, 1999, 1235,  631,  162, 1966,
 /*  1850 */   623, 1968, 1969,  618,  622,  613,  634,  636, 1229,  637,
 /*  1860 */   639,   56, 1227,  640, 1233, 1232, 1218,  646, 1231,  548,
 /*  1870 */  2089, 1983, 1230,   97,  278, 1250, 1246,   98, 1132,  620,
 /*  1880 */   656,   72, 1166, 1165, 1934, 1164,  619, 1163, 1162, 1185,
 /*  1890 */  1161, 1159, 1157, 1156, 1965, 1155,  668, 1153, 1152, 1151,
 /*  1900 */   573, 2142, 1150,  279, 1149, 1182, 1148, 1147, 1180, 1144,
 /*  1910 */  1964, 1965, 1143, 1140, 1999, 1138, 1139,  104, 1966,  623,
 /*  1920 */  1968, 1969,  618, 1137,  613, 1983, 1671,  688,  690, 1669,
 /*  1930 */   689, 2052,  692,  620,  693,  694, 2049, 1667, 1934,  696,
 /*  1940 */   619,  698, 1983, 1665,  700,  702,  697,  701, 1651,  704,
 /*  1950 */   620, 1090, 1631,  282,  708, 1934, 1386,  619,  292,  711,
 /*  1960 */   712, 1606, 1606, 1606, 1964, 1965, 1606, 1606, 1999, 1606,
 /*  1970 */  1606,  161, 1966,  623, 1968, 1969,  618, 1606,  613, 1606,
 /*  1980 */  1606, 1964, 1606, 1965, 1606, 1999, 1606, 1606,  306, 1966,
 /*  1990 */   623, 1968, 1969,  618, 1606,  613, 1983, 1606, 1606, 1606,
 /*  2000 */  1606, 1606, 1606, 1606,  620, 1606, 1606, 1606, 1606, 1934,
 /*  2010 */  1606,  619, 1606, 2090, 1983, 1606, 1606, 1606, 1606,  351,
 /*  2020 */  1606, 1606,  620, 1606, 1606, 1606, 1606, 1934, 1606,  619,
 /*  2030 */  1606, 1606,  568, 1606, 1606, 1964, 1606, 1965, 1606, 1999,
 /*  2040 */  1606, 1606,  162, 1966,  623, 1968, 1969,  618, 1606,  613,
 /*  2050 */  1606, 1606, 1606, 1964, 1606, 1965, 1606, 1999, 1606, 1606,
 /*  2060 */   313, 1966,  623, 1968, 1969,  618, 1606,  613, 1983, 1606,
 /*  2070 */  1606, 1606, 1606, 1606, 1606, 1606,  617, 1606, 1606, 1606,
 /*  2080 */  1606, 1934, 1606,  619, 1606, 1606, 1983, 1606, 1606, 1606,
 /*  2090 */  1606,  361, 1606, 1606,  620, 2143, 1606, 1606, 1606, 1934,
 /*  2100 */  1606,  619, 1606, 1606, 1606, 1606, 1606, 1964, 1606, 1606,
 /*  2110 */  1965, 1999, 1606, 1606,  312, 1966,  623, 1968, 1969,  618,
 /*  2120 */  1606,  613, 1606, 2018, 1606, 1964, 1606, 1606, 1606, 1999,
 /*  2130 */  1965, 1606,  313, 1966,  623, 1968, 1969,  618, 1606,  613,
 /*  2140 */  1606, 1983, 1606, 1606, 1606, 1606,  363, 1606, 1606,  620,
 /*  2150 */  1606, 1606, 1606, 1606, 1934, 1606,  619, 1606, 1606, 1606,
 /*  2160 */  1606, 1983, 1606, 1606, 1606, 1606, 1606, 1606, 1606,  620,
 /*  2170 */  1606, 1606, 1606, 1606, 1934, 1606,  619, 1606, 1606, 1606,
 /*  2180 */  1964, 1606, 1606, 1606, 1999, 1606, 1606,  313, 1966,  623,
 /*  2190 */  1968, 1969,  618, 1606,  613, 1606, 1606, 1965, 1606, 1606,
 /*  2200 */   533, 1606, 1606, 1606, 1999, 1606, 1606,  308, 1966,  623,
 /*  2210 */  1968, 1969,  618, 1606,  613, 1606, 1606, 1606, 1606, 1606,
 /*  2220 */  1606, 1606, 1965, 1606, 1606, 1606, 1606, 1606, 1983, 1606,
 /*  2230 */  1606, 1606, 1606, 1606, 1606, 1606,  620, 1606, 1606, 1606,
 /*  2240 */  1606, 1934, 1606,  619, 1606, 1606, 1606, 1606, 1606, 1965,
 /*  2250 */  1606, 1606, 1606, 1983, 1606, 1606, 1606, 1606, 1606, 1606,
 /*  2260 */  1606,  620, 1606, 1606, 1606, 1606, 1934, 1964,  619, 1606,
 /*  2270 */  1606, 1999, 1606, 1606,  297, 1966,  623, 1968, 1969,  618,
 /*  2280 */  1983,  613, 1606, 1606, 1606, 1606, 1606, 1606,  620, 1606,
 /*  2290 */  1606, 1606, 1964, 1934, 1606,  619, 1999, 1606, 1606,  298,
 /*  2300 */  1966,  623, 1968, 1969,  618, 1606,  613, 1606, 1606, 1965,
 /*  2310 */  1606, 1606, 1606, 1606, 1606, 1606, 1606, 1606, 1606, 1964,
 /*  2320 */  1606, 1606, 1606, 1999, 1606, 1606,  299, 1966,  623, 1968,
 /*  2330 */  1969,  618, 1965,  613, 1606, 1606, 1606, 1606, 1606, 1606,
 /*  2340 */  1983, 1606, 1606, 1606, 1606, 1606, 1606, 1606,  620, 1606,
 /*  2350 */  1606, 1606, 1606, 1934, 1606,  619, 1606, 1606, 1606, 1606,
 /*  2360 */  1606, 1606, 1606, 1983, 1606, 1606, 1606, 1606, 1606, 1606,
 /*  2370 */  1606,  620, 1606, 1606, 1606, 1606, 1934, 1606,  619, 1964,
 /*  2380 */  1606, 1606, 1606, 1999, 1606, 1606,  305, 1966,  623, 1968,
 /*  2390 */  1969,  618, 1965,  613, 1606, 1606, 1606, 1606, 1606, 1606,
 /*  2400 */  1606, 1606, 1964, 1606, 1606, 1606, 1999, 1606, 1606,  309,
 /*  2410 */  1966,  623, 1968, 1969,  618, 1606,  613, 1606, 1606, 1965,
 /*  2420 */  1606, 1606, 1606, 1983, 1606, 1606, 1606, 1606, 1606, 1606,
 /*  2430 */  1606,  620, 1606, 1606, 1606, 1606, 1934, 1606,  619, 1606,
 /*  2440 */  1606, 1606, 1606, 1606, 1965, 1606, 1606, 1606, 1606, 1606,
 /*  2450 */  1983, 1606, 1606, 1606, 1606, 1606, 1606, 1606,  620, 1606,
 /*  2460 */  1606, 1606, 1964, 1934, 1606,  619, 1999, 1606, 1606,  301,
 /*  2470 */  1966,  623, 1968, 1969,  618, 1983,  613, 1606, 1606, 1606,
 /*  2480 */  1606, 1606, 1606,  620, 1606, 1606, 1606, 1606, 1934, 1964,
 /*  2490 */   619, 1606, 1606, 1999, 1606, 1606,  310, 1966,  623, 1968,
 /*  2500 */  1969,  618, 1965,  613, 1606, 1606, 1606, 1606, 1606, 1606,
 /*  2510 */  1606, 1606, 1606, 1606, 1964, 1606, 1606, 1606, 1999, 1965,
 /*  2520 */  1606,  302, 1966,  623, 1968, 1969,  618, 1606,  613, 1606,
 /*  2530 */  1606, 1606, 1606, 1983, 1606, 1606, 1606, 1606, 1606, 1606,
 /*  2540 */  1606,  620, 1606, 1606, 1606, 1606, 1934, 1606,  619, 1606,
 /*  2550 */  1983, 1606, 1606, 1606, 1606, 1606, 1606, 1606,  620, 1606,
 /*  2560 */  1606, 1606, 1606, 1934, 1606,  619, 1606, 1606, 1606, 1606,
 /*  2570 */  1606, 1965, 1964, 1606, 1606, 1606, 1999, 1606, 1606,  311,
 /*  2580 */  1966,  623, 1968, 1969,  618, 1606,  613, 1606, 1606, 1964,
 /*  2590 */  1606, 1606, 1606, 1999, 1965, 1606,  303, 1966,  623, 1968,
 /*  2600 */  1969,  618, 1983,  613, 1606, 1606, 1606, 1606, 1606, 1606,
 /*  2610 */   620, 1606, 1606, 1606, 1606, 1934, 1606,  619, 1606, 1606,
 /*  2620 */  1606, 1606, 1606, 1965, 1606, 1983, 1606, 1606, 1606, 1606,
 /*  2630 */  1606, 1606, 1606,  620, 1606, 1606, 1606, 1606, 1934, 1606,
 /*  2640 */   619, 1964, 1606, 1606, 1606, 1999, 1606, 1606,  316, 1966,
 /*  2650 */   623, 1968, 1969,  618, 1983,  613, 1606, 1606, 1606, 1606,
 /*  2660 */  1606, 1606,  620, 1606, 1964, 1606, 1606, 1934, 1999,  619,
 /*  2670 */  1606,  317, 1966,  623, 1968, 1969,  618, 1606,  613, 1606,
 /*  2680 */  1606, 1965, 1606, 1606, 1606, 1606, 1606, 1606, 1606, 1606,
 /*  2690 */  1606, 1606, 1606, 1964, 1606, 1606, 1606, 1999, 1606, 1965,
 /*  2700 */  1977, 1966,  623, 1968, 1969,  618, 1606,  613, 1606, 1606,
 /*  2710 */  1606, 1606, 1983, 1606, 1606, 1606, 1606, 1606, 1606, 1606,
 /*  2720 */   620, 1606, 1606, 1606, 1606, 1934, 1606,  619, 1606, 1606,
 /*  2730 */  1983, 1606, 1606, 1606, 1606, 1606, 1606, 1606,  620, 1606,
 /*  2740 */  1606, 1606, 1606, 1934, 1606,  619, 1606, 1606, 1606, 1606,
 /*  2750 */  1606, 1964, 1606, 1606, 1606, 1999, 1606, 1606, 1976, 1966,
 /*  2760 */   623, 1968, 1969,  618, 1965,  613, 1606, 1606, 1606, 1964,
 /*  2770 */  1606, 1606, 1606, 1999, 1606, 1606, 1975, 1966,  623, 1968,
 /*  2780 */  1969,  618, 1606,  613, 1606, 1606, 1965, 1606, 1606, 1606,
 /*  2790 */  1606, 1606, 1606, 1606, 1606, 1983, 1606, 1606, 1606, 1606,
 /*  2800 */  1606, 1606, 1606,  620, 1606, 1606, 1606, 1606, 1934, 1606,
 /*  2810 */   619, 1606, 1606, 1606, 1606, 1606, 1606, 1983, 1606, 1606,
 /*  2820 */  1606, 1606, 1606, 1606, 1606,  620, 1606, 1606, 1606, 1606,
 /*  2830 */  1934, 1606,  619, 1606, 1964, 1606, 1606, 1606, 1999, 1606,
 /*  2840 */  1606,  328, 1966,  623, 1968, 1969,  618, 1965,  613, 1606,
 /*  2850 */  1606, 1606, 1606, 1606, 1606, 1606, 1964, 1606, 1606, 1606,
 /*  2860 */  1999, 1606, 1606,  329, 1966,  623, 1968, 1969,  618, 1965,
 /*  2870 */   613, 1606, 1606, 1606, 1606, 1606, 1606, 1606, 1983, 1606,
 /*  2880 */  1606, 1606, 1606, 1606, 1606, 1606,  620, 1606, 1606, 1606,
 /*  2890 */  1606, 1934, 1606,  619, 1606, 1606, 1606, 1606, 1606, 1606,
 /*  2900 */  1983, 1606, 1606, 1606, 1606, 1606, 1606, 1606,  620, 1606,
 /*  2910 */  1606, 1606, 1606, 1934, 1606,  619, 1606, 1964, 1606, 1606,
 /*  2920 */  1606, 1999, 1606, 1606,  325, 1966,  623, 1968, 1969,  618,
 /*  2930 */  1965,  613, 1606, 1606, 1606, 1606, 1606, 1606, 1606, 1964,
 /*  2940 */  1606, 1606, 1606, 1999, 1606, 1606,  330, 1966,  623, 1968,
 /*  2950 */  1969,  618, 1606,  613, 1606, 1606, 1606, 1606, 1606, 1606,
 /*  2960 */  1606, 1983, 1606, 1606, 1606, 1606, 1606, 1606, 1606,  620,
 /*  2970 */  1606, 1606, 1606, 1606, 1934, 1606,  619, 1606, 1606, 1606,
 /*  2980 */  1606, 1606, 1965, 1606, 1606, 1606, 1606, 1606, 1606, 1606,
 /*  2990 */  1606, 1606, 1606, 1606, 1606, 1606, 1606, 1606, 1606, 1606,
 /*  3000 */   621, 1606, 1606, 1606, 1999, 1606, 1606,  308, 1966,  623,
 /*  3010 */  1968, 1969,  618, 1983,  613, 1606, 1606, 1606, 1606, 1606,
 /*  3020 */  1606,  620, 1606, 1606, 1606, 1606, 1934, 1606,  619, 1606,
 /*  3030 */  1606, 1606, 1606, 1606, 1606, 1606, 1606, 1606, 1606, 1606,
 /*  3040 */  1606, 1606, 1606, 1606, 1606, 1606, 1606, 1606, 1606, 1606,
 /*  3050 */  1606, 1606, 1964, 1606, 1606, 1606, 1999, 1606, 1606,  307,
 /*  3060 */  1966,  623, 1968, 1969,  618, 1606,  613,
528 529
};
static const YYCODETYPE yy_lookahead[] = {
530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550
 /*     0 */   359,  335,  331,  373,  333,  334,  331,  369,  333,  334,
 /*    10 */   372,  373,   12,   13,   14,  360,  386,  387,  327,   14,
 /*    20 */    20,  359,   22,    8,    9,   20,  371,   12,   13,   14,
 /*    30 */    15,   16,  358,   33,  332,   35,  351,  335,  336,  354,
 /*    40 */   430,  375,    8,    9,  434,  358,   12,   13,   14,   15,
 /*    50 */    16,   20,  365,  379,  380,  400,  401,  402,   58,  449,
 /*    60 */   450,  374,  371,   63,  454,  455,  411,    8,    9,  327,
 /*    70 */    70,   12,   13,   14,   15,   16,  332,   20,  335,  335,
 /*    80 */   336,    8,    9,   12,   13,   12,   13,   14,   15,   16,
 /*    90 */   350,   20,  357,   22,    0,   95,  335,   63,  358,   20,
 /*   100 */   358,   22,    3,   44,   33,  370,   35,  367,  366,  366,
 /*   110 */   349,   96,   20,  371,  335,  373,   20,  117,   24,   25,
 /*   120 */    26,   27,   28,   29,   30,   31,   32,  366,  349,   58,
 /*   130 */    51,  324,  132,  133,   63,  356,  419,  420,  104,  397,
 /*   140 */   341,   70,   62,  401,    4,  366,  404,  405,  406,  407,
 /*   150 */   408,  409,   20,  411,  355,  430,  372,  373,  416,  434,
 /*   160 */   418,  161,  162,  364,  422,  423,   95,  167,  168,  426,
 /*   170 */   427,  428,    0,  430,  431,  450,  341,  434,  436,  454,
 /*   180 */   455,  430,  182,    3,  184,  434,  444,   95,  117,  132,
 /*   190 */   133,  342,  449,  450,  160,  388,  347,  454,  455,  364,
 /*   200 */    20,  450,   20,  132,  133,  454,  455,  207,  208,  177,
X
Xiaoyu Wang 已提交
551
 /*   210 */   210,  211,  212,  213,  214,  215,  216,  217,  218,  219,
552 553 554 555 556 557 558 559 560 561 562
 /*   220 */   220,  221,  222,  223,  224,  225,  226,   95,  132,  133,
 /*   230 */   198,  199,  161,  162,   62,   95,  163,  430,  167,  168,
 /*   240 */    21,  434,  106,   24,   25,   26,   27,   28,   29,   30,
 /*   250 */    31,   32,   37,  182,  207,  184,  449,  450,   14,   15,
 /*   260 */    16,  454,  455,  167,  168,  231,  232,  233,  234,  235,
 /*   270 */   236,  237,  238,  239,  240,  241,   96,   95,  207,  208,
 /*   280 */    58,  210,  211,  212,  213,  214,  215,  216,  217,  218,
 /*   290 */   219,  220,  221,  222,  223,  224,  225,  226,  358,  228,
 /*   300 */    12,   13,  255,  256,  257,  258,  259,  326,   20,  328,
 /*   310 */    22,    4,  127,   98,   20,  100,  101,   95,  103,   97,
 /*   320 */   380,   33,  107,   35,  108,  109,  110,  111,  112,  113,
563
 /*   330 */   114,  115,  116,  117,  118,    0,  120,  121,  122,  123,
564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579
 /*   340 */   124,  125,   33,  163,  129,  360,   58,   20,  360,  388,
 /*   350 */    43,   63,   45,   46,  358,  228,  371,   48,   70,  371,
 /*   360 */   350,  365,  263,   54,   55,   56,   57,   58,  358,   95,
 /*   370 */   374,   12,   13,   14,  189,  190,  244,  367,  193,   20,
 /*   380 */   195,   22,  358,   95,  244,  400,  401,  402,  400,  401,
 /*   390 */   366,  430,   33,   95,   35,  434,  411,  344,  345,  411,
 /*   400 */    65,   66,   67,   94,   20,  117,   97,    0,   73,   74,
 /*   410 */   449,  450,  228,   78,  230,  454,  455,   58,   83,   84,
 /*   420 */   132,  133,  126,  127,   89,    0,  244,  131,   21,   70,
 /*   430 */   406,   24,   25,   26,   27,   28,   29,   30,   31,   32,
 /*   440 */     8,    9,  344,  345,   12,   13,   14,   15,   16,  161,
 /*   450 */   162,  350,   20,  358,   95,  167,  168,    8,    9,  358,
 /*   460 */   365,   12,   13,   14,   15,   16,  244,  403,  367,  374,
 /*   470 */   182,   14,  184,  164,  165,   95,  117,   20,  169,    8,
 /*   480 */     9,  172,   62,   12,   13,   14,   15,   16,  161,  162,
 /*   490 */    35,  132,  133,  429,  327,  207,  208,  188,  210,  211,
580
 /*   500 */   212,  213,  214,  215,  216,  217,  218,  219,  220,  221,
581 582 583 584 585 586
 /*   510 */   222,  223,  224,  225,  226,   65,   66,   67,  244,   20,
 /*   520 */   161,  162,   21,   73,   74,  430,  167,  168,   78,  434,
 /*   530 */    35,  403,  107,   83,   84,   34,  403,   36,  371,   89,
 /*   540 */    20,  182,  244,  184,  449,  450,  339,  163,  327,  454,
 /*   550 */   455,  126,  127,  128,  129,  130,  131,  429,  335,  388,
 /*   560 */   353,  181,  429,  183,  327,   70,  207,  208,  361,  210,
587
 /*   570 */   211,  212,  213,  214,  215,  216,  217,  218,  219,  220,
588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608
 /*   580 */   221,  222,  223,  224,  225,  226,   12,   13,  335,  366,
 /*   590 */    22,   14,  371,    0,   20,  163,   22,   20,   19,  163,
 /*   600 */   373,  430,  349,   35,   58,  434,  170,   33,  371,   35,
 /*   610 */   383,   44,   33,  386,  387,  335,  327,    0,  161,  366,
 /*   620 */   449,  450,  388,  174,  244,  454,  455,   48,  335,  349,
 /*   630 */   360,  366,   58,   54,   55,   56,   57,   58,   70,  184,
 /*   640 */    94,  371,  377,   97,   70,  366,  366,  358,  425,  426,
 /*   650 */   427,  428,  339,  430,  431,  366,  377,   12,   13,  366,
 /*   660 */   371,  335,  373,   96,  430,   20,  160,   22,  434,   95,
 /*   670 */   400,  401,  327,   94,  361,  349,   97,  335,   33,   62,
 /*   680 */    35,  411,  356,  449,  450,  117,  397,   79,  454,  455,
 /*   690 */   401,  117,  366,  404,  405,  406,  407,  408,  409,  410,
 /*   700 */   411,  412,  413,   58,    0,  327,  132,  133,  366,  130,
 /*   710 */    12,   13,   14,   15,   16,   70,  371,  268,  166,  426,
 /*   720 */   427,  428,  327,  430,  431,  414,    8,    9,  417,  359,
 /*   730 */    12,   13,   14,   15,   16,  161,  162,  231,  161,  327,
 /*   740 */    95,  167,  168,  335,  151,  137,  138,  241,  169,  371,
 /*   750 */   182,  415,  184,  417,    1,    2,  182,  349,  184,  126,
 /*   760 */   327,  415,  117,  417,   20,  186,  371,  188,  426,  427,
 /*   770 */   428,   20,  430,  431,  366,  207,  208,  132,  133,   39,
 /*   780 */   388,  207,  208,  371,  210,  211,  212,  213,  214,  215,
609
 /*   790 */   216,  217,  218,  219,  220,  221,  222,  223,  224,  225,
610 611 612 613 614 615
 /*   800 */   226,  249,  250,  251,  371,  335,  161,  162,   18,  358,
 /*   810 */    20,  107,  167,  168,   96,  242,  243,   27,  367,  349,
 /*   820 */    30,  358,  430,   33,  191,  192,  434,  182,  366,  184,
 /*   830 */   126,  127,  128,  129,  130,  131,  366,  374,   48,  377,
 /*   840 */    50,  449,  450,   53,   20,  327,  454,  455,  368,   96,
 /*   850 */    44,  371,  207,  208,   63,  210,  211,  212,  213,  214,
616
 /*   860 */   215,  216,  217,  218,  219,  220,  221,  222,  223,  224,
617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836
 /*   870 */   225,  226,  327,  368,  327,  346,  371,  348,   18,  368,
 /*   880 */   327,    2,  371,   23,   94,    0,  335,    8,    9,  371,
 /*   890 */     4,   12,   13,   14,   15,   16,  106,   37,   38,    2,
 /*   900 */   349,   41,  327,   45,   46,    8,    9,  163,   70,   12,
 /*   910 */    13,   14,   15,   16,  163,   22,  371,  366,  371,   59,
 /*   920 */    60,   61,  351,   70,  371,  354,  136,  392,   35,  139,
 /*   930 */   140,  141,  142,  143,  144,  145,  146,  147,  148,  149,
 /*   940 */   150,  151,  152,  153,  154,  155,  371,  157,  158,  159,
 /*   950 */    65,   66,   67,   68,   69,   95,   71,   72,   73,   74,
 /*   960 */    75,   76,   77,   78,   79,   80,   81,   82,   83,   84,
 /*   970 */    85,   86,   87,   88,   89,   90,   91,   20,  107,   22,
 /*   980 */    42,    0,   44,  243,   58,  161,  327,   44,  327,  327,
 /*   990 */   335,  335,   35,  335,  134,  335,  107,  327,  207,    4,
 /*  1000 */   129,   42,   35,   44,  349,  349,  327,  349,   51,  349,
 /*  1010 */   359,  335,  388,  335,   19,  126,  127,  128,  129,  130,
 /*  1020 */   131,  366,  366,   97,  366,  349,  366,  349,   33,   48,
 /*  1030 */   371,  359,  371,  371,  174,  175,  176,  358,  327,  179,
 /*  1040 */   359,  371,  366,   48,  366,  366,   99,  359,   53,  102,
 /*  1050 */   371,    0,  373,   58,  430,  132,  133,  197,  434,   35,
 /*  1060 */   200,  106,  202,  203,  204,  205,  206,  335,  327,   99,
 /*  1070 */   347,  265,  102,  449,  450,   44,  397,  335,  454,  455,
 /*  1080 */   401,  349,  371,  404,  405,  406,  407,  408,  409,   94,
 /*  1090 */   411,  349,   97,  414,   70,  416,  417,  418,  366,  358,
 /*  1100 */    49,  422,  423,  335,  244,  335,  335,  366,  366,  335,
 /*  1110 */   335,  156,  371,   99,  373,   99,  102,  349,  102,  349,
 /*  1120 */   349,    0,  327,  349,  349,   44,   44,   96,   44,   95,
 /*  1130 */    44,  245,    0,    0,  366,   44,  366,  366,  397,  105,
 /*  1140 */   366,  366,  401,   22,  328,  404,  405,  406,  407,  408,
 /*  1150 */   409,  184,  411,  358,   22,   22,   44,  416,  381,  418,
 /*  1160 */   458,  366,   44,  422,  423,  337,  371,   44,  373,   13,
 /*  1170 */     1,    2,   44,   47,  447,   13,  441,   96,   96,   44,
 /*  1180 */    96,  327,   96,   44,  358,  444,   44,   96,   44,  337,
 /*  1190 */    44,   35,  397,  381,  381,  334,  401,   35,  432,  404,
 /*  1200 */   405,  406,  407,  408,  409,  370,  411,  451,   96,  424,
 /*  1210 */   267,  416,  358,  418,   96,  435,  399,  422,  423,   96,
 /*  1220 */   366,   95,  246,   48,   96,  371,  180,  373,  433,  398,
 /*  1230 */   390,   96,   42,  378,   20,   96,  160,  381,   96,   20,
 /*  1240 */    96,  378,   96,  376,  335,  335,  378,  327,  376,  376,
 /*  1250 */    93,  397,  335,  335,  343,  401,  335,   20,  404,  405,
 /*  1260 */   406,  407,  408,  409,  329,  411,  329,  327,  394,   20,
 /*  1270 */   416,  341,  418,   20,  373,  341,  422,  423,  358,   20,
 /*  1280 */   336,   20,  341,  389,  336,  335,  366,  433,   52,  329,
 /*  1290 */   341,  371,  341,  373,  341,  341,  338,  358,  358,  338,
 /*  1300 */   358,  335,  329,  358,  358,  196,  366,  371,  396,  394,
 /*  1310 */   358,  371,  187,  373,  358,  393,  339,  397,  335,  339,
 /*  1320 */   358,  401,  358,  358,  404,  405,  406,  407,  408,  409,
 /*  1330 */   358,  411,  358,  254,  371,  440,  416,  397,  418,  371,
 /*  1340 */   253,  401,  422,  423,  404,  405,  406,  407,  408,  409,
 /*  1350 */   381,  411,  373,  433,  440,  384,  416,  371,  418,   12,
 /*  1360 */    13,  371,  422,  423,  327,  381,  384,  371,  260,   22,
 /*  1370 */   443,  173,  262,  433,  442,  261,  247,  266,  459,  243,
 /*  1380 */    33,  453,   35,  264,  269,  452,  399,  366,   20,  335,
 /*  1390 */   384,  336,  403,  371,  371,  358,  339,  371,  371,  371,
 /*  1400 */   371,  384,  382,  366,  165,   58,  339,  354,  371,  339,
 /*  1410 */   373,  366,   95,  421,   95,  440,  438,   70,  362,  371,
 /*  1420 */   348,   36,  339,  327,  439,  437,  329,  335,  330,  391,
 /*  1430 */   395,  325,  385,  340,  397,  385,    0,  352,  401,    0,
 /*  1440 */   352,  404,  405,  406,  407,  408,  409,  352,  411,  189,
 /*  1450 */     0,    0,   42,  416,  358,  418,    0,   35,  201,  422,
 /*  1460 */   423,   35,  366,   35,  117,   35,  201,  371,    0,  373,
 /*  1470 */   433,  201,   35,   35,    0,  201,    0,   35,    0,   22,
 /*  1480 */     0,   35,  184,  182,    0,    0,  178,  177,    0,    0,
 /*  1490 */    47,    0,    0,  397,    0,   42,    0,  401,    0,    0,
 /*  1500 */   404,  405,  406,  407,  408,  409,    0,  411,    0,    0,
 /*  1510 */     0,    0,  416,  327,  418,  151,   35,    0,  422,  423,
 /*  1520 */   151,    0,    0,    0,    0,    0,    0,    0,    0,  182,
 /*  1530 */     0,  184,    0,    0,    0,    0,    0,    0,    0,   42,
 /*  1540 */     0,    0,    0,    0,  358,    0,    0,    0,  135,    0,
 /*  1550 */     0,   22,  366,   35,  207,  208,    0,  371,   58,  373,
 /*  1560 */     0,   58,    0,    0,   44,   14,  219,  220,  221,  222,
 /*  1570 */   223,  224,  225,   42,    0,  327,    0,    0,   39,   14,
 /*  1580 */     0,  173,    0,  397,   40,    0,    0,  401,    0,    0,
 /*  1590 */   404,  405,  406,  407,  408,  409,   39,  411,  327,   47,
 /*  1600 */    47,   47,  416,   39,  418,   35,  358,   48,  422,  423,
 /*  1610 */    39,    0,   64,   35,  366,    0,   48,   48,   39,  371,
 /*  1620 */    39,  373,   35,    0,    0,   35,    0,    0,    0,  358,
 /*  1630 */    39,   48,   35,    0,   22,   35,   35,  366,   35,   35,
 /*  1640 */    44,   35,  371,   44,  373,  397,    0,   22,   35,  401,
 /*  1650 */     0,   35,  404,  405,  406,  407,  408,  409,   22,  411,
 /*  1660 */    50,   22,  104,  102,  416,  327,  418,    0,  397,   22,
 /*  1670 */   422,  423,  401,    0,    0,  404,  405,  406,  407,  408,
 /*  1680 */   409,    0,  411,   35,   35,   22,   35,   35,  327,  418,
 /*  1690 */    20,   96,   35,  422,  423,  194,  358,   95,    0,   35,
 /*  1700 */     0,  185,   22,    0,  366,    0,   44,    3,  248,  371,
 /*  1710 */    96,  373,   95,   95,  227,  252,   96,   96,  163,  358,
 /*  1720 */    44,   44,   47,   44,   95,   95,   95,  366,   96,  163,
 /*  1730 */    47,  248,  371,   96,  373,  397,  163,  165,   95,  401,
 /*  1740 */    96,    3,  404,  405,  406,  407,  408,  409,   35,  411,
 /*  1750 */    44,  327,  248,   35,   35,   35,  418,   35,  397,   35,
 /*  1760 */   422,  423,  401,  171,  170,  404,  405,  406,  407,  408,
 /*  1770 */   409,  327,  411,   47,   96,  170,   44,   47,   96,  418,
 /*  1780 */     0,    0,  358,  422,  423,    0,   95,    0,   96,   96,
 /*  1790 */   366,   95,   95,   39,   95,  371,   95,  373,   47,  164,
 /*  1800 */   166,   44,  358,    2,  229,  207,   22,  105,   96,   95,
 /*  1810 */   366,   95,   47,   96,   47,  371,   95,  373,   22,   96,
 /*  1820 */   227,  397,   95,   35,   95,  401,   35,   96,  404,  405,
 /*  1830 */   406,  407,  408,  409,  227,  411,   95,   35,   96,  106,
 /*  1840 */   327,  397,   95,   35,   96,  401,   96,   95,  404,  405,
 /*  1850 */   406,  407,  408,  409,  209,  411,   95,   35,   96,   95,
 /*  1860 */    35,  242,   96,   95,  119,  119,   22,  107,  119,  445,
 /*  1870 */   446,  358,  119,   95,   44,   35,   22,   95,   64,  366,
 /*  1880 */    63,   95,   35,   35,  371,   35,  373,   35,   35,   70,
 /*  1890 */    35,   35,   35,   35,  327,   35,   92,   35,   35,   35,
 /*  1900 */   456,  457,   22,   44,   35,   70,   35,   35,   35,   35,
 /*  1910 */   397,  327,   35,   35,  401,   22,   35,  404,  405,  406,
 /*  1920 */   407,  408,  409,   35,  411,  358,    0,   35,   39,    0,
 /*  1930 */    48,  418,   35,  366,   48,   39,  423,    0,  371,   35,
 /*  1940 */   373,   39,  358,    0,   35,   39,   48,   48,    0,   35,
 /*  1950 */   366,   35,    0,   22,   21,  371,   22,  373,   22,   21,
 /*  1960 */    20,  460,  460,  460,  397,  327,  460,  460,  401,  460,
 /*  1970 */   460,  404,  405,  406,  407,  408,  409,  460,  411,  460,
 /*  1980 */   460,  397,  460,  327,  460,  401,  460,  460,  404,  405,
 /*  1990 */   406,  407,  408,  409,  460,  411,  358,  460,  460,  460,
 /*  2000 */   460,  460,  460,  460,  366,  460,  460,  460,  460,  371,
 /*  2010 */   460,  373,  460,  446,  358,  460,  460,  460,  460,  363,
 /*  2020 */   460,  460,  366,  460,  460,  460,  460,  371,  460,  373,
 /*  2030 */   460,  460,  448,  460,  460,  397,  460,  327,  460,  401,
 /*  2040 */   460,  460,  404,  405,  406,  407,  408,  409,  460,  411,
 /*  2050 */   460,  460,  460,  397,  460,  327,  460,  401,  460,  460,
 /*  2060 */   404,  405,  406,  407,  408,  409,  460,  411,  358,  460,
 /*  2070 */   460,  460,  460,  460,  460,  460,  366,  460,  460,  460,
 /*  2080 */   460,  371,  460,  373,  460,  460,  358,  460,  460,  460,
 /*  2090 */   460,  363,  460,  460,  366,  457,  460,  460,  460,  371,
 /*  2100 */   460,  373,  460,  460,  460,  460,  460,  397,  460,  460,
 /*  2110 */   327,  401,  460,  460,  404,  405,  406,  407,  408,  409,
 /*  2120 */   460,  411,  460,  413,  460,  397,  460,  460,  460,  401,
 /*  2130 */   327,  460,  404,  405,  406,  407,  408,  409,  460,  411,
 /*  2140 */   460,  358,  460,  460,  460,  460,  363,  460,  460,  366,
 /*  2150 */   460,  460,  460,  460,  371,  460,  373,  460,  460,  460,
 /*  2160 */   460,  358,  460,  460,  460,  460,  460,  460,  460,  366,
 /*  2170 */   460,  460,  460,  460,  371,  460,  373,  460,  460,  460,
 /*  2180 */   397,  460,  460,  460,  401,  460,  460,  404,  405,  406,
 /*  2190 */   407,  408,  409,  460,  411,  460,  460,  327,  460,  460,
 /*  2200 */   397,  460,  460,  460,  401,  460,  460,  404,  405,  406,
 /*  2210 */   407,  408,  409,  460,  411,  460,  460,  460,  460,  460,
 /*  2220 */   460,  460,  327,  460,  460,  460,  460,  460,  358,  460,
 /*  2230 */   460,  460,  460,  460,  460,  460,  366,  460,  460,  460,
 /*  2240 */   460,  371,  460,  373,  460,  460,  460,  460,  460,  327,
 /*  2250 */   460,  460,  460,  358,  460,  460,  460,  460,  460,  460,
 /*  2260 */   460,  366,  460,  460,  460,  460,  371,  397,  373,  460,
 /*  2270 */   460,  401,  460,  460,  404,  405,  406,  407,  408,  409,
 /*  2280 */   358,  411,  460,  460,  460,  460,  460,  460,  366,  460,
 /*  2290 */   460,  460,  397,  371,  460,  373,  401,  460,  460,  404,
 /*  2300 */   405,  406,  407,  408,  409,  460,  411,  460,  460,  327,
 /*  2310 */   460,  460,  460,  460,  460,  460,  460,  460,  460,  397,
 /*  2320 */   460,  460,  460,  401,  460,  460,  404,  405,  406,  407,
 /*  2330 */   408,  409,  327,  411,  460,  460,  460,  460,  460,  460,
 /*  2340 */   358,  460,  460,  460,  460,  460,  460,  460,  366,  460,
 /*  2350 */   460,  460,  460,  371,  460,  373,  460,  460,  460,  460,
 /*  2360 */   460,  460,  460,  358,  460,  460,  460,  460,  460,  460,
 /*  2370 */   460,  366,  460,  460,  460,  460,  371,  460,  373,  397,
 /*  2380 */   460,  460,  460,  401,  460,  460,  404,  405,  406,  407,
 /*  2390 */   408,  409,  327,  411,  460,  460,  460,  460,  460,  460,
 /*  2400 */   460,  460,  397,  460,  460,  460,  401,  460,  460,  404,
 /*  2410 */   405,  406,  407,  408,  409,  460,  411,  460,  460,  327,
 /*  2420 */   460,  460,  460,  358,  460,  460,  460,  460,  460,  460,
 /*  2430 */   460,  366,  460,  460,  460,  460,  371,  460,  373,  460,
 /*  2440 */   460,  460,  460,  460,  327,  460,  460,  460,  460,  460,
 /*  2450 */   358,  460,  460,  460,  460,  460,  460,  460,  366,  460,
 /*  2460 */   460,  460,  397,  371,  460,  373,  401,  460,  460,  404,
 /*  2470 */   405,  406,  407,  408,  409,  358,  411,  460,  460,  460,
 /*  2480 */   460,  460,  460,  366,  460,  460,  460,  460,  371,  397,
 /*  2490 */   373,  460,  460,  401,  460,  460,  404,  405,  406,  407,
 /*  2500 */   408,  409,  327,  411,  460,  460,  460,  460,  460,  460,
 /*  2510 */   460,  460,  460,  460,  397,  460,  460,  460,  401,  327,
 /*  2520 */   460,  404,  405,  406,  407,  408,  409,  460,  411,  460,
 /*  2530 */   460,  460,  460,  358,  460,  460,  460,  460,  460,  460,
 /*  2540 */   460,  366,  460,  460,  460,  460,  371,  460,  373,  460,
 /*  2550 */   358,  460,  460,  460,  460,  460,  460,  460,  366,  460,
 /*  2560 */   460,  460,  460,  371,  460,  373,  460,  460,  460,  460,
 /*  2570 */   460,  327,  397,  460,  460,  460,  401,  460,  460,  404,
 /*  2580 */   405,  406,  407,  408,  409,  460,  411,  460,  460,  397,
 /*  2590 */   460,  460,  460,  401,  327,  460,  404,  405,  406,  407,
 /*  2600 */   408,  409,  358,  411,  460,  460,  460,  460,  460,  460,
 /*  2610 */   366,  460,  460,  460,  460,  371,  460,  373,  460,  460,
 /*  2620 */   460,  460,  460,  327,  460,  358,  460,  460,  460,  460,
 /*  2630 */   460,  460,  460,  366,  460,  460,  460,  460,  371,  460,
 /*  2640 */   373,  397,  460,  460,  460,  401,  460,  460,  404,  405,
 /*  2650 */   406,  407,  408,  409,  358,  411,  460,  460,  460,  460,
 /*  2660 */   460,  460,  366,  460,  397,  460,  460,  371,  401,  373,
 /*  2670 */   460,  404,  405,  406,  407,  408,  409,  460,  411,  460,
 /*  2680 */   460,  327,  460,  460,  460,  460,  460,  460,  460,  460,
 /*  2690 */   460,  460,  460,  397,  460,  460,  460,  401,  460,  327,
 /*  2700 */   404,  405,  406,  407,  408,  409,  460,  411,  460,  460,
 /*  2710 */   460,  460,  358,  460,  460,  460,  460,  460,  460,  460,
 /*  2720 */   366,  460,  460,  460,  460,  371,  460,  373,  460,  460,
 /*  2730 */   358,  460,  460,  460,  460,  460,  460,  460,  366,  460,
 /*  2740 */   460,  460,  460,  371,  460,  373,  460,  460,  460,  460,
 /*  2750 */   460,  397,  460,  460,  460,  401,  460,  460,  404,  405,
 /*  2760 */   406,  407,  408,  409,  327,  411,  460,  460,  460,  397,
 /*  2770 */   460,  460,  460,  401,  460,  460,  404,  405,  406,  407,
 /*  2780 */   408,  409,  460,  411,  460,  460,  327,  460,  460,  460,
 /*  2790 */   460,  460,  460,  460,  460,  358,  460,  460,  460,  460,
 /*  2800 */   460,  460,  460,  366,  460,  460,  460,  460,  371,  460,
 /*  2810 */   373,  460,  460,  460,  460,  460,  460,  358,  460,  460,
 /*  2820 */   460,  460,  460,  460,  460,  366,  460,  460,  460,  460,
 /*  2830 */   371,  460,  373,  460,  397,  460,  460,  460,  401,  460,
 /*  2840 */   460,  404,  405,  406,  407,  408,  409,  327,  411,  460,
 /*  2850 */   460,  460,  460,  460,  460,  460,  397,  460,  460,  460,
 /*  2860 */   401,  460,  460,  404,  405,  406,  407,  408,  409,  327,
 /*  2870 */   411,  460,  460,  460,  460,  460,  460,  460,  358,  460,
 /*  2880 */   460,  460,  460,  460,  460,  460,  366,  460,  460,  460,
 /*  2890 */   460,  371,  460,  373,  460,  460,  460,  460,  460,  460,
 /*  2900 */   358,  460,  460,  460,  460,  460,  460,  460,  366,  460,
 /*  2910 */   460,  460,  460,  371,  460,  373,  460,  397,  460,  460,
 /*  2920 */   460,  401,  460,  460,  404,  405,  406,  407,  408,  409,
 /*  2930 */   327,  411,  460,  460,  460,  460,  460,  460,  460,  397,
 /*  2940 */   460,  460,  460,  401,  460,  460,  404,  405,  406,  407,
 /*  2950 */   408,  409,  460,  411,  460,  460,  460,  460,  460,  460,
 /*  2960 */   460,  358,  460,  460,  460,  460,  460,  460,  460,  366,
 /*  2970 */   460,  460,  460,  460,  371,  460,  373,  460,  460,  460,
 /*  2980 */   460,  460,  327,  460,  460,  460,  460,  460,  460,  460,
 /*  2990 */   460,  460,  460,  460,  460,  460,  460,  460,  460,  460,
 /*  3000 */   397,  460,  460,  460,  401,  460,  460,  404,  405,  406,
 /*  3010 */   407,  408,  409,  358,  411,  460,  460,  460,  460,  460,
 /*  3020 */   460,  366,  460,  460,  460,  460,  371,  460,  373,  460,
 /*  3030 */   460,  460,  460,  460,  460,  460,  460,  460,  460,  460,
 /*  3040 */   460,  460,  460,  460,  460,  460,  460,  460,  460,  460,
 /*  3050 */   460,  460,  397,  460,  460,  460,  401,  460,  460,  404,
 /*  3060 */   405,  406,  407,  408,  409,  460,  411,
837
};
X
Xiaoyu Wang 已提交
838
#define YY_SHIFT_COUNT    (713)
839
#define YY_SHIFT_MIN      (0)
840
#define YY_SHIFT_MAX      (1952)
841
static const unsigned short int yy_shift_ofst[] = {
842
 /*     0 */   860,    0,   71,    0,  288,  288,  288,  288,  288,  288,
X
Xiaoyu Wang 已提交
843
 /*    10 */   288,  288,  288,  288,  288,  359,  574,  574,  645,  574,
844 845
 /*    20 */   574,  574,  574,  574,  574,  574,  574,  574,  574,  574,
 /*    30 */   574,  574,  574,  574,  574,  574,  574,  574,  574,  574,
846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913
 /*    40 */   574,  574,  574,  574,  574,  574,  574,  574,  132,  182,
 /*    50 */    92,  380,  222,  274,  298,  274,   92,   92, 1347, 1347,
 /*    60 */   274, 1347, 1347,  140,  274,   96,   31,   31,   96,  307,
 /*    70 */   307,  327,   57,    5,    5,   31,   31,   31,   31,   31,
 /*    80 */    31,   31,   31,   31,   31,   80,   31,   31,  294,   31,
 /*    90 */    31,   31,  499,   31,   31,  499,   31,  499,  499,  499,
 /*   100 */    31,  420,  790,   34,   34,  219,  450,  568,  568,  568,
 /*   110 */   568,  568,  568,  568,  568,  568,  568,  568,  568,  568,
 /*   120 */   568,  568,  568,  568,  568,  568,  215,  180,  327,   57,
 /*   130 */   172,  495,  384,  384,  384,  617,  184,  184,  495,  520,
 /*   140 */   520,  520,  136,  127,  499,  838,  499,  838,  838,  136,
 /*   150 */   853,  216,  216,  216,  216,  216,  216,  216,  579,  407,
 /*   160 */   335,  432,  449,   47,  957,  552,  457,  577,   79,  744,
 /*   170 */   858,  871,  751,  573,  740,   99,  573,  938,  886,  824,
 /*   180 */   976, 1175, 1046, 1190, 1214, 1190, 1076, 1219, 1219, 1190,
 /*   190 */  1076, 1076, 1157, 1219, 1219, 1219, 1237, 1237, 1249,   80,
 /*   200 */  1253,   80, 1259, 1261,   80, 1259,   80,   80,   80, 1219,
 /*   210 */    80, 1236, 1236, 1237,  499,  499,  499,  499,  499,  499,
 /*   220 */   499,  499,  499,  499,  499, 1219, 1237,  838,  838, 1109,
 /*   230 */  1249,  420, 1125, 1253,  420, 1219, 1214, 1214,  838, 1079,
 /*   240 */  1087,  838, 1079, 1087,  838,  838,  499, 1108, 1198, 1079,
 /*   250 */  1110, 1114, 1129,  976, 1115, 1111, 1119, 1136,  520, 1368,
 /*   260 */  1219, 1259,  420, 1087,  838,  838,  838,  838,  838, 1087,
 /*   270 */   838, 1239,  420,  136,  420,  520, 1317, 1319,  838,  853,
 /*   280 */  1219,  420, 1385, 1237, 3067, 3067, 3067, 3067, 3067, 3067,
 /*   290 */  3067, 3067, 3067,  885,  309,   94,  995,   15,   59,  718,
 /*   300 */   425,  879,  897,   73,  704,  471,  471,  471,  471,  471,
 /*   310 */   471,  471,  471,  471,  889,  185,  698,  698,   32,  546,
 /*   320 */   608,  501,  633,  296,  296,  244,  753,  506,  244,  244,
 /*   330 */   244,  567,  981,  893,  959,  955,  593,  947,  970, 1014,
 /*   340 */  1016, 1121, 1132, 1133,  926, 1031, 1081,  923,  806,  943,
 /*   350 */   436, 1082, 1084, 1086, 1091, 1112, 1169, 1118,  455,  967,
 /*   360 */   791, 1123, 1126, 1128, 1135, 1139, 1142, 1144, 1146, 1034,
 /*   370 */  1156, 1162, 1024, 1051, 1436, 1439, 1260, 1450, 1451, 1410,
 /*   380 */  1456, 1422, 1257, 1426, 1428, 1430, 1265, 1468, 1437, 1438,
 /*   390 */  1270, 1474, 1274, 1476, 1442, 1478, 1457, 1480, 1446, 1298,
 /*   400 */  1301, 1484, 1485, 1308, 1310, 1488, 1489, 1443, 1491, 1492,
 /*   410 */  1494, 1453, 1496, 1498, 1499, 1506, 1508, 1509, 1510, 1511,
 /*   420 */  1364, 1481, 1517, 1369, 1521, 1522, 1523, 1524, 1525, 1526,
 /*   430 */  1527, 1528, 1530, 1532, 1533, 1534, 1535, 1536, 1537, 1497,
 /*   440 */  1538, 1540, 1541, 1542, 1543, 1529, 1545, 1546, 1547, 1413,
 /*   450 */  1549, 1550, 1518, 1556, 1500, 1560, 1503, 1562, 1563, 1531,
 /*   460 */  1539, 1520, 1552, 1551, 1553, 1565, 1554, 1574, 1544, 1557,
 /*   470 */  1576, 1577, 1580, 1564, 1408, 1582, 1585, 1586, 1548, 1588,
 /*   480 */  1589, 1570, 1559, 1571, 1611, 1578, 1568, 1579, 1615, 1587,
 /*   490 */  1569, 1581, 1623, 1590, 1583, 1591, 1624, 1626, 1627, 1628,
 /*   500 */  1558, 1561, 1597, 1612, 1633, 1600, 1601, 1603, 1604, 1596,
 /*   510 */  1599, 1606, 1613, 1625, 1616, 1646, 1636, 1650, 1639, 1610,
 /*   520 */  1667, 1647, 1648, 1673, 1649, 1674, 1651, 1681, 1663, 1670,
 /*   530 */  1652, 1657, 1501, 1595, 1602, 1698, 1555, 1664, 1700, 1516,
 /*   540 */  1680, 1566, 1572, 1703, 1705, 1573, 1592, 1704, 1662, 1460,
 /*   550 */  1617, 1614, 1618, 1594, 1487, 1605, 1463, 1620, 1676, 1621,
 /*   560 */  1629, 1630, 1631, 1632, 1677, 1675, 1683, 1643, 1679, 1483,
 /*   570 */  1637, 1644, 1738, 1706, 1504, 1713, 1718, 1719, 1720, 1722,
 /*   580 */  1724, 1678, 1682, 1726, 1619, 1732, 1730, 1780, 1781, 1785,
 /*   590 */  1691, 1692, 1693, 1696, 1697, 1634, 1699, 1787, 1754, 1635,
 /*   600 */  1701, 1702, 1552, 1751, 1757, 1593, 1575, 1607, 1801, 1784,
 /*   610 */  1598, 1714, 1712, 1716, 1717, 1721, 1723, 1765, 1727, 1729,
 /*   620 */  1767, 1731, 1796, 1645, 1741, 1733, 1742, 1788, 1791, 1747,
 /*   630 */  1748, 1802, 1752, 1750, 1808, 1761, 1762, 1822, 1764, 1766,
 /*   640 */  1825, 1768, 1745, 1746, 1749, 1753, 1844, 1760, 1778, 1830,
 /*   650 */  1782, 1840, 1786, 1830, 1830, 1854, 1814, 1817, 1847, 1848,
 /*   660 */  1850, 1852, 1853, 1855, 1856, 1857, 1858, 1860, 1819, 1804,
 /*   670 */  1859, 1862, 1863, 1864, 1880, 1869, 1871, 1872, 1835, 1596,
 /*   680 */  1873, 1599, 1874, 1877, 1878, 1881, 1893, 1888, 1926, 1892,
 /*   690 */  1882, 1889, 1929, 1897, 1886, 1896, 1937, 1904, 1898, 1902,
 /*   700 */  1943, 1909, 1899, 1906, 1948, 1914, 1916, 1952, 1931, 1933,
 /*   710 */  1934, 1936, 1938, 1940,
914
};
X
Xiaoyu Wang 已提交
915
#define YY_REDUCE_COUNT (292)
916 917
#define YY_REDUCE_MIN   (-390)
#define YY_REDUCE_MAX   (2655)
918
static const short yy_reduce_ofst[] = {
919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948
 /*     0 */  -193, -258,  679,  741,  795,  854,  920,  940, 1037, 1096,
 /*    10 */  1186, 1248, 1271, 1338, 1361,  289, 1424, 1444, 1513, 1567,
 /*    20 */  1584, 1638, 1656, 1710, 1728, 1783, 1803, 1870, 1895, 1922,
 /*    30 */  1982, 2005, 2065, 2092, 2117, 2175, 2192, 2244, 2267, 2296,
 /*    40 */  2354, 2372, 2437, 2459, 2520, 2542, 2603, 2655, -257,   95,
 /*    50 */   223,  -39,  171,  234,  392,  624,  293,  342, -345,  -15,
 /*    60 */  -390,  -12,  270, -275, -249,  227, -221,  326, -370, -329,
 /*    70 */  -325, -326, -362, -298, -256, -239,  253,  280,  408,  470,
 /*    80 */   551,  655,  656,  658,  660, -201,  676,  678,   24,  732,
 /*    90 */   742,  768, -260,  770,  771, -313,  774,   10,   -4,  101,
 /*   100 */   775,  207, -334, -283, -283,  -19, -151, -309,  167,  221,
 /*   110 */   237,  345,  378,  395,  412,  433,  518,  545,  547,  553,
 /*   120 */   575,  659,  661,  662,  670,  711, -265,   64,  -60, -216,
 /*   130 */  -165,   53,   64,  128,  133,  313,  336,  346,   98,  265,
 /*   140 */   279,  462, -315,  311,  451,  480,  463,  505,  511,  571,
 /*   150 */   529, -359, -338,  370,  651,  672,  681,  688,  535,  816,
 /*   160 */   723,  777,  702,  727,  828,  735,  826,  826,  852,  812,
 /*   170 */   861,  835,  813,  766,  766,  756,  766,  785,  780,  826,
 /*   180 */   817,  831,  840,  855,  856,  863,  867,  909,  910,  868,
 /*   190 */   872,  873,  911,  917,  918,  921,  935,  937,  874,  930,
 /*   200 */   901,  934,  944,  894,  941,  948,  949,  951,  953,  950,
 /*   210 */   954,  958,  961,  960,  939,  942,  945,  946,  952,  956,
 /*   220 */   962,  964,  965,  972,  974,  966,  973,  936,  963,  912,
 /*   230 */   915,  977,  922,  979,  980,  983,  969,  984,  968,  895,
 /*   240 */   971,  986,  914,  982,  990,  996,  826,  927,  932,  975,
 /*   250 */   985,  978,  988,  987,  919,  928,  933,  766, 1021,  989,
 /*   260 */  1054, 1055, 1057, 1006, 1022, 1023, 1026, 1027, 1028, 1017,
 /*   270 */  1029, 1020, 1067, 1053, 1070, 1045,  992, 1056, 1048, 1072,
 /*   280 */  1092, 1083, 1098, 1097, 1038, 1035, 1047, 1050, 1085, 1088,
 /*   290 */  1095, 1093, 1106,
949 950
};
static const YYACTIONTYPE yy_default[] = {
951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022
 /*     0 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*    10 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*    20 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*    30 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*    40 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*    50 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*    60 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*    70 */  1604, 1859, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*    80 */  1604, 1604, 1604, 1604, 1604, 1682, 1604, 1604, 1604, 1604,
 /*    90 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   100 */  1604, 1680, 1852, 2054, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   110 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   120 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 2066, 1604, 1604,
 /*   130 */  1682, 1604, 2066, 2066, 2066, 1680, 2026, 2026, 1604, 1604,
 /*   140 */  1604, 1604, 1789, 1604, 1604, 1604, 1604, 1604, 1604, 1789,
 /*   150 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1901, 1604,
 /*   160 */  1604, 2091, 2145, 1604, 1604, 2094, 1604, 1604, 1604, 1864,
 /*   170 */  1604, 1742, 2081, 2058, 2072, 2129, 2059, 2056, 2075, 1604,
 /*   180 */  2085, 1604, 1894, 1857, 1604, 1857, 1854, 1604, 1604, 1857,
 /*   190 */  1854, 1854, 1733, 1604, 1604, 1604, 1604, 1604, 1604, 1682,
 /*   200 */  1604, 1682, 1604, 1604, 1682, 1604, 1682, 1682, 1682, 1604,
 /*   210 */  1682, 1661, 1661, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   220 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1914,
 /*   230 */  1604, 1680, 1903, 1604, 1680, 1604, 1604, 1604, 1604, 2102,
 /*   240 */  2100, 1604, 2102, 2100, 1604, 1604, 1604, 2114, 2110, 2102,
 /*   250 */  2118, 2116, 2087, 2085, 2148, 2135, 2131, 2072, 1604, 1604,
 /*   260 */  1604, 1604, 1680, 2100, 1604, 1604, 1604, 1604, 1604, 2100,
 /*   270 */  1604, 1604, 1680, 1604, 1680, 1604, 1604, 1758, 1604, 1604,
 /*   280 */  1604, 1680, 1636, 1604, 1896, 1907, 1879, 1879, 1792, 1792,
 /*   290 */  1792, 1683, 1609, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   300 */  1604, 1604, 1604, 1604, 1604, 2113, 2112, 1982, 1604, 2030,
 /*   310 */  2029, 2028, 2019, 1981, 1754, 1604, 1980, 1979, 1604, 1604,
 /*   320 */  1604, 1604, 1604, 1870, 1869, 1973, 1604, 1604, 1974, 1972,
 /*   330 */  1971, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   340 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 2132, 2136,
 /*   350 */  1604, 1604, 1604, 1604, 1604, 1604, 2055, 1604, 1604, 1604,
 /*   360 */  1604, 1604, 1956, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   370 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   380 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   390 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   400 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   410 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   420 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   430 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   440 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   450 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   460 */  1604, 1641, 1961, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   470 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   480 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   490 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   500 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1721,
 /*   510 */  1720, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   520 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   530 */  1604, 1604, 1604, 1964, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   540 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 2128, 2088, 1604,
 /*   550 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   560 */  1604, 1604, 1604, 1604, 1604, 1604, 1956, 1604, 2111, 1604,
 /*   570 */  1604, 2126, 1604, 2130, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   580 */  1604, 2065, 2061, 1604, 1604, 2057, 1604, 1604, 1604, 1604,
 /*   590 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   600 */  1604, 1604, 1955, 1604, 2016, 1604, 1604, 1604, 2050, 1604,
 /*   610 */  1604, 2001, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   620 */  1604, 1964, 1604, 1967, 1604, 1604, 1604, 1604, 1604, 1786,
 /*   630 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   640 */  1604, 1604, 1771, 1769, 1768, 1767, 1604, 1764, 1604, 1799,
 /*   650 */  1604, 1604, 1604, 1795, 1794, 1604, 1604, 1604, 1604, 1604,
 /*   660 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   670 */  1701, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1693,
 /*   680 */  1604, 1692, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   690 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   700 */  1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604, 1604,
 /*   710 */  1604, 1604, 1604, 1604,
1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041
};
/********** 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[] = {
X
Xiaoyu Wang 已提交
1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075
    0,  /*          $ => nothing */
    0,  /*         OR => nothing */
    0,  /*        AND => nothing */
    0,  /*      UNION => nothing */
    0,  /*        ALL => nothing */
    0,  /*      MINUS => nothing */
    0,  /*     EXCEPT => nothing */
    0,  /*  INTERSECT => nothing */
    0,  /*  NK_BITAND => nothing */
    0,  /*   NK_BITOR => nothing */
    0,  /*  NK_LSHIFT => nothing */
    0,  /*  NK_RSHIFT => nothing */
    0,  /*    NK_PLUS => nothing */
    0,  /*   NK_MINUS => nothing */
    0,  /*    NK_STAR => nothing */
    0,  /*   NK_SLASH => nothing */
    0,  /*     NK_REM => nothing */
    0,  /*  NK_CONCAT => nothing */
    0,  /*     CREATE => nothing */
    0,  /*    ACCOUNT => nothing */
    0,  /*      NK_ID => nothing */
    0,  /*       PASS => nothing */
    0,  /*  NK_STRING => nothing */
    0,  /*      ALTER => nothing */
    0,  /*        PPS => nothing */
    0,  /*    TSERIES => nothing */
    0,  /*    STORAGE => nothing */
    0,  /*    STREAMS => nothing */
    0,  /*      QTIME => nothing */
    0,  /*        DBS => nothing */
    0,  /*      USERS => nothing */
    0,  /*      CONNS => nothing */
    0,  /*      STATE => nothing */
    0,  /*       USER => nothing */
X
Xiaoyu Wang 已提交
1076 1077 1078
    0,  /*     ENABLE => nothing */
    0,  /* NK_INTEGER => nothing */
    0,  /*    SYSINFO => nothing */
X
Xiaoyu Wang 已提交
1079
    0,  /*       DROP => nothing */
1080 1081 1082 1083 1084
    0,  /*      GRANT => nothing */
    0,  /*         ON => nothing */
    0,  /*         TO => nothing */
    0,  /*     REVOKE => nothing */
    0,  /*       FROM => nothing */
1085
    0,  /*  SUBSCRIBE => nothing */
1086 1087 1088 1089
    0,  /*   NK_COMMA => nothing */
    0,  /*       READ => nothing */
    0,  /*      WRITE => nothing */
    0,  /*     NK_DOT => nothing */
X
Xiaoyu Wang 已提交
1090 1091 1092
    0,  /*      DNODE => nothing */
    0,  /*       PORT => nothing */
    0,  /*     DNODES => nothing */
1093
    0,  /* NK_IPTOKEN => nothing */
1094
    0,  /*      FORCE => nothing */
X
Xiaoyu Wang 已提交
1095 1096 1097 1098 1099 1100 1101
    0,  /*      LOCAL => nothing */
    0,  /*      QNODE => nothing */
    0,  /*      BNODE => nothing */
    0,  /*      SNODE => nothing */
    0,  /*      MNODE => nothing */
    0,  /*   DATABASE => nothing */
    0,  /*        USE => nothing */
X
Xiaoyu Wang 已提交
1102
    0,  /*      FLUSH => nothing */
X
Xiaoyu Wang 已提交
1103
    0,  /*       TRIM => nothing */
X
Xiaoyu Wang 已提交
1104 1105 1106
    0,  /*         IF => nothing */
    0,  /*        NOT => nothing */
    0,  /*     EXISTS => nothing */
X
Xiaoyu Wang 已提交
1107
    0,  /*     BUFFER => nothing */
1108 1109
    0,  /* CACHEMODEL => nothing */
    0,  /*  CACHESIZE => nothing */
X
Xiaoyu Wang 已提交
1110
    0,  /*       COMP => nothing */
X
Xiaoyu Wang 已提交
1111
    0,  /*   DURATION => nothing */
X
Xiaoyu Wang 已提交
1112 1113 1114 1115
    0,  /* NK_VARIABLE => nothing */
    0,  /*    MAXROWS => nothing */
    0,  /*    MINROWS => nothing */
    0,  /*       KEEP => nothing */
X
Xiaoyu Wang 已提交
1116 1117
    0,  /*      PAGES => nothing */
    0,  /*   PAGESIZE => nothing */
1118
    0,  /* TSDB_PAGESIZE => nothing */
X
Xiaoyu Wang 已提交
1119 1120 1121 1122 1123
    0,  /*  PRECISION => nothing */
    0,  /*    REPLICA => nothing */
    0,  /*    VGROUPS => nothing */
    0,  /* SINGLE_STABLE => nothing */
    0,  /* RETENTIONS => nothing */
X
Xiaoyu Wang 已提交
1124
    0,  /* SCHEMALESS => nothing */
X
Xiaoyu Wang 已提交
1125 1126
    0,  /*  WAL_LEVEL => nothing */
    0,  /* WAL_FSYNC_PERIOD => nothing */
X
Xiaoyu Wang 已提交
1127 1128 1129 1130
    0,  /* WAL_RETENTION_PERIOD => nothing */
    0,  /* WAL_RETENTION_SIZE => nothing */
    0,  /* WAL_ROLL_PERIOD => nothing */
    0,  /* WAL_SEGMENT_SIZE => nothing */
1131
    0,  /* STT_TRIGGER => nothing */
1132 1133
    0,  /* TABLE_PREFIX => nothing */
    0,  /* TABLE_SUFFIX => nothing */
X
Xiaoyu Wang 已提交
1134
    0,  /*   NK_COLON => nothing */
1135
    0,  /*  MAX_SPEED => nothing */
X
Xiaoyu Wang 已提交
1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167
    0,  /*      TABLE => nothing */
    0,  /*      NK_LP => nothing */
    0,  /*      NK_RP => nothing */
    0,  /*     STABLE => nothing */
    0,  /*        ADD => nothing */
    0,  /*     COLUMN => nothing */
    0,  /*     MODIFY => nothing */
    0,  /*     RENAME => nothing */
    0,  /*        TAG => nothing */
    0,  /*        SET => nothing */
    0,  /*      NK_EQ => nothing */
    0,  /*      USING => nothing */
    0,  /*       TAGS => nothing */
    0,  /*    COMMENT => nothing */
    0,  /*       BOOL => nothing */
    0,  /*    TINYINT => nothing */
    0,  /*   SMALLINT => nothing */
    0,  /*        INT => nothing */
    0,  /*    INTEGER => nothing */
    0,  /*     BIGINT => nothing */
    0,  /*      FLOAT => nothing */
    0,  /*     DOUBLE => nothing */
    0,  /*     BINARY => nothing */
    0,  /*  TIMESTAMP => nothing */
    0,  /*      NCHAR => nothing */
    0,  /*   UNSIGNED => nothing */
    0,  /*       JSON => nothing */
    0,  /*    VARCHAR => nothing */
    0,  /* MEDIUMBLOB => nothing */
    0,  /*       BLOB => nothing */
    0,  /*  VARBINARY => nothing */
    0,  /*    DECIMAL => nothing */
X
Xiaoyu Wang 已提交
1168 1169
    0,  /*  MAX_DELAY => nothing */
    0,  /*  WATERMARK => nothing */
X
Xiaoyu Wang 已提交
1170 1171 1172
    0,  /*     ROLLUP => nothing */
    0,  /*        TTL => nothing */
    0,  /*        SMA => nothing */
1173
    0,  /* DELETE_MARK => nothing */
X
Xiaoyu Wang 已提交
1174 1175
    0,  /*      FIRST => nothing */
    0,  /*       LAST => nothing */
X
Xiaoyu Wang 已提交
1176
    0,  /*       SHOW => nothing */
1177
    0,  /* PRIVILEGES => nothing */
X
Xiaoyu Wang 已提交
1178 1179 1180 1181 1182 1183 1184 1185 1186 1187
    0,  /*  DATABASES => nothing */
    0,  /*     TABLES => nothing */
    0,  /*    STABLES => nothing */
    0,  /*     MNODES => nothing */
    0,  /*     QNODES => nothing */
    0,  /*  FUNCTIONS => nothing */
    0,  /*    INDEXES => nothing */
    0,  /*   ACCOUNTS => nothing */
    0,  /*       APPS => nothing */
    0,  /* CONNECTIONS => nothing */
X
Xiaoyu Wang 已提交
1188
    0,  /*   LICENCES => nothing */
X
Xiaoyu Wang 已提交
1189 1190 1191 1192 1193
    0,  /*     GRANTS => nothing */
    0,  /*    QUERIES => nothing */
    0,  /*     SCORES => nothing */
    0,  /*     TOPICS => nothing */
    0,  /*  VARIABLES => nothing */
1194
    0,  /*    CLUSTER => nothing */
X
Xiaoyu Wang 已提交
1195 1196
    0,  /*     BNODES => nothing */
    0,  /*     SNODES => nothing */
1197
    0,  /* TRANSACTIONS => nothing */
1198
    0,  /* DISTRIBUTED => nothing */
1199 1200
    0,  /*  CONSUMERS => nothing */
    0,  /* SUBSCRIPTIONS => nothing */
1201
    0,  /*     VNODES => nothing */
X
Xiaoyu Wang 已提交
1202
    0,  /*       LIKE => nothing */
1203 1204 1205
    0,  /*     TBNAME => nothing */
    0,  /*      QTAGS => nothing */
    0,  /*         AS => nothing */
X
Xiaoyu Wang 已提交
1206 1207 1208
    0,  /*      INDEX => nothing */
    0,  /*   FUNCTION => nothing */
    0,  /*   INTERVAL => nothing */
1209 1210
    0,  /*      COUNT => nothing */
    0,  /*   LAST_ROW => nothing */
X
Xiaoyu Wang 已提交
1211
    0,  /*      TOPIC => nothing */
X
Xiaoyu Wang 已提交
1212 1213
    0,  /*       WITH => nothing */
    0,  /*       META => nothing */
1214 1215
    0,  /*   CONSUMER => nothing */
    0,  /*      GROUP => nothing */
X
Xiaoyu Wang 已提交
1216 1217 1218 1219
    0,  /*       DESC => nothing */
    0,  /*   DESCRIBE => nothing */
    0,  /*      RESET => nothing */
    0,  /*      QUERY => nothing */
X
Xiaoyu Wang 已提交
1220
    0,  /*      CACHE => nothing */
X
Xiaoyu Wang 已提交
1221 1222 1223 1224 1225
    0,  /*    EXPLAIN => nothing */
    0,  /*    ANALYZE => nothing */
    0,  /*    VERBOSE => nothing */
    0,  /*    NK_BOOL => nothing */
    0,  /*      RATIO => nothing */
X
Xiaoyu Wang 已提交
1226
    0,  /*   NK_FLOAT => nothing */
X
Xiaoyu Wang 已提交
1227 1228 1229 1230 1231 1232 1233 1234
    0,  /* OUTPUTTYPE => nothing */
    0,  /*  AGGREGATE => nothing */
    0,  /*    BUFSIZE => nothing */
    0,  /*     STREAM => nothing */
    0,  /*       INTO => nothing */
    0,  /*    TRIGGER => nothing */
    0,  /*    AT_ONCE => nothing */
    0,  /* WINDOW_CLOSE => nothing */
1235 1236
    0,  /*     IGNORE => nothing */
    0,  /*    EXPIRED => nothing */
1237
    0,  /* FILL_HISTORY => nothing */
1238
    0,  /*   SUBTABLE => nothing */
X
Xiaoyu Wang 已提交
1239 1240
    0,  /*       KILL => nothing */
    0,  /* CONNECTION => nothing */
1241
    0,  /* TRANSACTION => nothing */
X
Xiaoyu Wang 已提交
1242
    0,  /*    BALANCE => nothing */
X
Xiaoyu Wang 已提交
1243
    0,  /*     VGROUP => nothing */
X
Xiaoyu Wang 已提交
1244
    0,  /*      MERGE => nothing */
X
Xiaoyu Wang 已提交
1245
    0,  /* REDISTRIBUTE => nothing */
1246
    0,  /*      SPLIT => nothing */
X
Xiaoyu Wang 已提交
1247
    0,  /*     DELETE => nothing */
1248
    0,  /*     INSERT => nothing */
X
Xiaoyu Wang 已提交
1249 1250 1251 1252
    0,  /*       NULL => nothing */
    0,  /* NK_QUESTION => nothing */
    0,  /*   NK_ARROW => nothing */
    0,  /*      ROWTS => nothing */
1253 1254 1255 1256 1257
    0,  /*     QSTART => nothing */
    0,  /*       QEND => nothing */
    0,  /*  QDURATION => nothing */
    0,  /*     WSTART => nothing */
    0,  /*       WEND => nothing */
X
Xiaoyu Wang 已提交
1258
    0,  /*  WDURATION => nothing */
1259
    0,  /*     IROWTS => nothing */
X
Xiaoyu Wang 已提交
1260 1261 1262 1263
    0,  /*       CAST => nothing */
    0,  /*        NOW => nothing */
    0,  /*      TODAY => nothing */
    0,  /*   TIMEZONE => nothing */
1264 1265 1266 1267
    0,  /* CLIENT_VERSION => nothing */
    0,  /* SERVER_VERSION => nothing */
    0,  /* SERVER_STATUS => nothing */
    0,  /* CURRENT_USER => nothing */
X
Xiaoyu Wang 已提交
1268
    0,  /*       CASE => nothing */
X
Xiaoyu Wang 已提交
1269
  270,  /*        END => ABORT */
X
Xiaoyu Wang 已提交
1270 1271 1272
    0,  /*       WHEN => nothing */
    0,  /*       THEN => nothing */
    0,  /*       ELSE => nothing */
X
Xiaoyu Wang 已提交
1273 1274 1275 1276 1277 1278 1279 1280 1281 1282
    0,  /*    BETWEEN => nothing */
    0,  /*         IS => nothing */
    0,  /*      NK_LT => nothing */
    0,  /*      NK_GT => nothing */
    0,  /*      NK_LE => nothing */
    0,  /*      NK_GE => nothing */
    0,  /*      NK_NE => nothing */
    0,  /*      MATCH => nothing */
    0,  /*     NMATCH => nothing */
    0,  /*   CONTAINS => nothing */
X
Xiaoyu Wang 已提交
1283
    0,  /*         IN => nothing */
X
Xiaoyu Wang 已提交
1284 1285 1286 1287 1288 1289 1290 1291 1292
    0,  /*       JOIN => nothing */
    0,  /*      INNER => nothing */
    0,  /*     SELECT => nothing */
    0,  /*   DISTINCT => nothing */
    0,  /*      WHERE => nothing */
    0,  /*  PARTITION => nothing */
    0,  /*         BY => nothing */
    0,  /*    SESSION => nothing */
    0,  /* STATE_WINDOW => nothing */
X
Xiaoyu Wang 已提交
1293 1294
    0,  /* EVENT_WINDOW => nothing */
    0,  /*      START => nothing */
X
Xiaoyu Wang 已提交
1295 1296 1297 1298 1299 1300 1301 1302
    0,  /*    SLIDING => nothing */
    0,  /*       FILL => nothing */
    0,  /*      VALUE => nothing */
    0,  /*       NONE => nothing */
    0,  /*       PREV => nothing */
    0,  /*     LINEAR => nothing */
    0,  /*       NEXT => nothing */
    0,  /*     HAVING => nothing */
X
Xiaoyu Wang 已提交
1303 1304
    0,  /*      RANGE => nothing */
    0,  /*      EVERY => nothing */
X
Xiaoyu Wang 已提交
1305 1306 1307 1308 1309 1310 1311
    0,  /*      ORDER => nothing */
    0,  /*     SLIMIT => nothing */
    0,  /*    SOFFSET => nothing */
    0,  /*      LIMIT => nothing */
    0,  /*     OFFSET => nothing */
    0,  /*        ASC => nothing */
    0,  /*      NULLS => nothing */
X
Xiaoyu Wang 已提交
1312
    0,  /*      ABORT => nothing */
X
Xiaoyu Wang 已提交
1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365
  270,  /*      AFTER => ABORT */
  270,  /*     ATTACH => ABORT */
  270,  /*     BEFORE => ABORT */
  270,  /*      BEGIN => ABORT */
  270,  /*     BITAND => ABORT */
  270,  /*     BITNOT => ABORT */
  270,  /*      BITOR => ABORT */
  270,  /*     BLOCKS => ABORT */
  270,  /*     CHANGE => ABORT */
  270,  /*      COMMA => ABORT */
  270,  /*    COMPACT => ABORT */
  270,  /*     CONCAT => ABORT */
  270,  /*   CONFLICT => ABORT */
  270,  /*       COPY => ABORT */
  270,  /*   DEFERRED => ABORT */
  270,  /* DELIMITERS => ABORT */
  270,  /*     DETACH => ABORT */
  270,  /*     DIVIDE => ABORT */
  270,  /*        DOT => ABORT */
  270,  /*       EACH => ABORT */
  270,  /*       FAIL => ABORT */
  270,  /*       FILE => ABORT */
  270,  /*        FOR => ABORT */
  270,  /*       GLOB => ABORT */
  270,  /*         ID => ABORT */
  270,  /*  IMMEDIATE => ABORT */
  270,  /*     IMPORT => ABORT */
  270,  /*  INITIALLY => ABORT */
  270,  /*    INSTEAD => ABORT */
  270,  /*     ISNULL => ABORT */
  270,  /*        KEY => ABORT */
  270,  /*    MODULES => ABORT */
  270,  /*  NK_BITNOT => ABORT */
  270,  /*    NK_SEMI => ABORT */
  270,  /*    NOTNULL => ABORT */
  270,  /*         OF => ABORT */
  270,  /*       PLUS => ABORT */
  270,  /*  PRIVILEGE => ABORT */
  270,  /*      RAISE => ABORT */
  270,  /*    REPLACE => ABORT */
  270,  /*   RESTRICT => ABORT */
  270,  /*        ROW => ABORT */
  270,  /*       SEMI => ABORT */
  270,  /*       STAR => ABORT */
  270,  /*  STATEMENT => ABORT */
  270,  /*     STRICT => ABORT */
  270,  /*     STRING => ABORT */
  270,  /*      TIMES => ABORT */
  270,  /*     UPDATE => ABORT */
  270,  /*     VALUES => ABORT */
  270,  /*   VARIABLE => ABORT */
  270,  /*       VIEW => ABORT */
  270,  /*        WAL => ABORT */
1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403
};
#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
X
Xiaoyu Wang 已提交
1404 1405
  ParseARG_SDECL                /* A place to hold %extra_argument */
  ParseCTX_SDECL                /* A place to hold %extra_context */
1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440
#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 <stdio.h>
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:
** <ul>
** <li> A FILE* to which trace output should be written.
**      If NULL, then tracing is turned off.
** <li> A prefix string written at the beginning of every
**      line of trace output.  If NULL, then tracing is
**      turned off.
** </ul>
**
** Outputs:
** None.
*/
X
Xiaoyu Wang 已提交
1441
void ParseTrace(FILE *TraceFILE, char *zTracePrompt){
1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453
  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 */ "$",
1454 1455
  /*    1 */ "OR",
  /*    2 */ "AND",
1456 1457 1458 1459 1460
  /*    3 */ "UNION",
  /*    4 */ "ALL",
  /*    5 */ "MINUS",
  /*    6 */ "EXCEPT",
  /*    7 */ "INTERSECT",
1461 1462 1463 1464 1465 1466 1467 1468 1469 1470
  /*    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",
1471
  /*   18 */ "CREATE",
1472 1473 1474
  /*   19 */ "ACCOUNT",
  /*   20 */ "NK_ID",
  /*   21 */ "PASS",
1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486
  /*   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",
X
Xiaoyu Wang 已提交
1487 1488 1489 1490 1491 1492 1493 1494 1495
  /*   34 */ "ENABLE",
  /*   35 */ "NK_INTEGER",
  /*   36 */ "SYSINFO",
  /*   37 */ "DROP",
  /*   38 */ "GRANT",
  /*   39 */ "ON",
  /*   40 */ "TO",
  /*   41 */ "REVOKE",
  /*   42 */ "FROM",
1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531
  /*   43 */ "SUBSCRIBE",
  /*   44 */ "NK_COMMA",
  /*   45 */ "READ",
  /*   46 */ "WRITE",
  /*   47 */ "NK_DOT",
  /*   48 */ "DNODE",
  /*   49 */ "PORT",
  /*   50 */ "DNODES",
  /*   51 */ "NK_IPTOKEN",
  /*   52 */ "FORCE",
  /*   53 */ "LOCAL",
  /*   54 */ "QNODE",
  /*   55 */ "BNODE",
  /*   56 */ "SNODE",
  /*   57 */ "MNODE",
  /*   58 */ "DATABASE",
  /*   59 */ "USE",
  /*   60 */ "FLUSH",
  /*   61 */ "TRIM",
  /*   62 */ "IF",
  /*   63 */ "NOT",
  /*   64 */ "EXISTS",
  /*   65 */ "BUFFER",
  /*   66 */ "CACHEMODEL",
  /*   67 */ "CACHESIZE",
  /*   68 */ "COMP",
  /*   69 */ "DURATION",
  /*   70 */ "NK_VARIABLE",
  /*   71 */ "MAXROWS",
  /*   72 */ "MINROWS",
  /*   73 */ "KEEP",
  /*   74 */ "PAGES",
  /*   75 */ "PAGESIZE",
  /*   76 */ "TSDB_PAGESIZE",
  /*   77 */ "PRECISION",
  /*   78 */ "REPLICA",
1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619
  /*   79 */ "VGROUPS",
  /*   80 */ "SINGLE_STABLE",
  /*   81 */ "RETENTIONS",
  /*   82 */ "SCHEMALESS",
  /*   83 */ "WAL_LEVEL",
  /*   84 */ "WAL_FSYNC_PERIOD",
  /*   85 */ "WAL_RETENTION_PERIOD",
  /*   86 */ "WAL_RETENTION_SIZE",
  /*   87 */ "WAL_ROLL_PERIOD",
  /*   88 */ "WAL_SEGMENT_SIZE",
  /*   89 */ "STT_TRIGGER",
  /*   90 */ "TABLE_PREFIX",
  /*   91 */ "TABLE_SUFFIX",
  /*   92 */ "NK_COLON",
  /*   93 */ "MAX_SPEED",
  /*   94 */ "TABLE",
  /*   95 */ "NK_LP",
  /*   96 */ "NK_RP",
  /*   97 */ "STABLE",
  /*   98 */ "ADD",
  /*   99 */ "COLUMN",
  /*  100 */ "MODIFY",
  /*  101 */ "RENAME",
  /*  102 */ "TAG",
  /*  103 */ "SET",
  /*  104 */ "NK_EQ",
  /*  105 */ "USING",
  /*  106 */ "TAGS",
  /*  107 */ "COMMENT",
  /*  108 */ "BOOL",
  /*  109 */ "TINYINT",
  /*  110 */ "SMALLINT",
  /*  111 */ "INT",
  /*  112 */ "INTEGER",
  /*  113 */ "BIGINT",
  /*  114 */ "FLOAT",
  /*  115 */ "DOUBLE",
  /*  116 */ "BINARY",
  /*  117 */ "TIMESTAMP",
  /*  118 */ "NCHAR",
  /*  119 */ "UNSIGNED",
  /*  120 */ "JSON",
  /*  121 */ "VARCHAR",
  /*  122 */ "MEDIUMBLOB",
  /*  123 */ "BLOB",
  /*  124 */ "VARBINARY",
  /*  125 */ "DECIMAL",
  /*  126 */ "MAX_DELAY",
  /*  127 */ "WATERMARK",
  /*  128 */ "ROLLUP",
  /*  129 */ "TTL",
  /*  130 */ "SMA",
  /*  131 */ "DELETE_MARK",
  /*  132 */ "FIRST",
  /*  133 */ "LAST",
  /*  134 */ "SHOW",
  /*  135 */ "PRIVILEGES",
  /*  136 */ "DATABASES",
  /*  137 */ "TABLES",
  /*  138 */ "STABLES",
  /*  139 */ "MNODES",
  /*  140 */ "QNODES",
  /*  141 */ "FUNCTIONS",
  /*  142 */ "INDEXES",
  /*  143 */ "ACCOUNTS",
  /*  144 */ "APPS",
  /*  145 */ "CONNECTIONS",
  /*  146 */ "LICENCES",
  /*  147 */ "GRANTS",
  /*  148 */ "QUERIES",
  /*  149 */ "SCORES",
  /*  150 */ "TOPICS",
  /*  151 */ "VARIABLES",
  /*  152 */ "CLUSTER",
  /*  153 */ "BNODES",
  /*  154 */ "SNODES",
  /*  155 */ "TRANSACTIONS",
  /*  156 */ "DISTRIBUTED",
  /*  157 */ "CONSUMERS",
  /*  158 */ "SUBSCRIPTIONS",
  /*  159 */ "VNODES",
  /*  160 */ "LIKE",
  /*  161 */ "TBNAME",
  /*  162 */ "QTAGS",
  /*  163 */ "AS",
  /*  164 */ "INDEX",
  /*  165 */ "FUNCTION",
  /*  166 */ "INTERVAL",
1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678
  /*  167 */ "COUNT",
  /*  168 */ "LAST_ROW",
  /*  169 */ "TOPIC",
  /*  170 */ "WITH",
  /*  171 */ "META",
  /*  172 */ "CONSUMER",
  /*  173 */ "GROUP",
  /*  174 */ "DESC",
  /*  175 */ "DESCRIBE",
  /*  176 */ "RESET",
  /*  177 */ "QUERY",
  /*  178 */ "CACHE",
  /*  179 */ "EXPLAIN",
  /*  180 */ "ANALYZE",
  /*  181 */ "VERBOSE",
  /*  182 */ "NK_BOOL",
  /*  183 */ "RATIO",
  /*  184 */ "NK_FLOAT",
  /*  185 */ "OUTPUTTYPE",
  /*  186 */ "AGGREGATE",
  /*  187 */ "BUFSIZE",
  /*  188 */ "STREAM",
  /*  189 */ "INTO",
  /*  190 */ "TRIGGER",
  /*  191 */ "AT_ONCE",
  /*  192 */ "WINDOW_CLOSE",
  /*  193 */ "IGNORE",
  /*  194 */ "EXPIRED",
  /*  195 */ "FILL_HISTORY",
  /*  196 */ "SUBTABLE",
  /*  197 */ "KILL",
  /*  198 */ "CONNECTION",
  /*  199 */ "TRANSACTION",
  /*  200 */ "BALANCE",
  /*  201 */ "VGROUP",
  /*  202 */ "MERGE",
  /*  203 */ "REDISTRIBUTE",
  /*  204 */ "SPLIT",
  /*  205 */ "DELETE",
  /*  206 */ "INSERT",
  /*  207 */ "NULL",
  /*  208 */ "NK_QUESTION",
  /*  209 */ "NK_ARROW",
  /*  210 */ "ROWTS",
  /*  211 */ "QSTART",
  /*  212 */ "QEND",
  /*  213 */ "QDURATION",
  /*  214 */ "WSTART",
  /*  215 */ "WEND",
  /*  216 */ "WDURATION",
  /*  217 */ "IROWTS",
  /*  218 */ "CAST",
  /*  219 */ "NOW",
  /*  220 */ "TODAY",
  /*  221 */ "TIMEZONE",
  /*  222 */ "CLIENT_VERSION",
  /*  223 */ "SERVER_VERSION",
  /*  224 */ "SERVER_STATUS",
  /*  225 */ "CURRENT_USER",
1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703
  /*  226 */ "CASE",
  /*  227 */ "END",
  /*  228 */ "WHEN",
  /*  229 */ "THEN",
  /*  230 */ "ELSE",
  /*  231 */ "BETWEEN",
  /*  232 */ "IS",
  /*  233 */ "NK_LT",
  /*  234 */ "NK_GT",
  /*  235 */ "NK_LE",
  /*  236 */ "NK_GE",
  /*  237 */ "NK_NE",
  /*  238 */ "MATCH",
  /*  239 */ "NMATCH",
  /*  240 */ "CONTAINS",
  /*  241 */ "IN",
  /*  242 */ "JOIN",
  /*  243 */ "INNER",
  /*  244 */ "SELECT",
  /*  245 */ "DISTINCT",
  /*  246 */ "WHERE",
  /*  247 */ "PARTITION",
  /*  248 */ "BY",
  /*  249 */ "SESSION",
  /*  250 */ "STATE_WINDOW",
X
Xiaoyu Wang 已提交
1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769
  /*  251 */ "EVENT_WINDOW",
  /*  252 */ "START",
  /*  253 */ "SLIDING",
  /*  254 */ "FILL",
  /*  255 */ "VALUE",
  /*  256 */ "NONE",
  /*  257 */ "PREV",
  /*  258 */ "LINEAR",
  /*  259 */ "NEXT",
  /*  260 */ "HAVING",
  /*  261 */ "RANGE",
  /*  262 */ "EVERY",
  /*  263 */ "ORDER",
  /*  264 */ "SLIMIT",
  /*  265 */ "SOFFSET",
  /*  266 */ "LIMIT",
  /*  267 */ "OFFSET",
  /*  268 */ "ASC",
  /*  269 */ "NULLS",
  /*  270 */ "ABORT",
  /*  271 */ "AFTER",
  /*  272 */ "ATTACH",
  /*  273 */ "BEFORE",
  /*  274 */ "BEGIN",
  /*  275 */ "BITAND",
  /*  276 */ "BITNOT",
  /*  277 */ "BITOR",
  /*  278 */ "BLOCKS",
  /*  279 */ "CHANGE",
  /*  280 */ "COMMA",
  /*  281 */ "COMPACT",
  /*  282 */ "CONCAT",
  /*  283 */ "CONFLICT",
  /*  284 */ "COPY",
  /*  285 */ "DEFERRED",
  /*  286 */ "DELIMITERS",
  /*  287 */ "DETACH",
  /*  288 */ "DIVIDE",
  /*  289 */ "DOT",
  /*  290 */ "EACH",
  /*  291 */ "FAIL",
  /*  292 */ "FILE",
  /*  293 */ "FOR",
  /*  294 */ "GLOB",
  /*  295 */ "ID",
  /*  296 */ "IMMEDIATE",
  /*  297 */ "IMPORT",
  /*  298 */ "INITIALLY",
  /*  299 */ "INSTEAD",
  /*  300 */ "ISNULL",
  /*  301 */ "KEY",
  /*  302 */ "MODULES",
  /*  303 */ "NK_BITNOT",
  /*  304 */ "NK_SEMI",
  /*  305 */ "NOTNULL",
  /*  306 */ "OF",
  /*  307 */ "PLUS",
  /*  308 */ "PRIVILEGE",
  /*  309 */ "RAISE",
  /*  310 */ "REPLACE",
  /*  311 */ "RESTRICT",
  /*  312 */ "ROW",
  /*  313 */ "SEMI",
  /*  314 */ "STAR",
  /*  315 */ "STATEMENT",
  /*  316 */ "STRICT",
X
Xiaoyu Wang 已提交
1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839
  /*  317 */ "STRING",
  /*  318 */ "TIMES",
  /*  319 */ "UPDATE",
  /*  320 */ "VALUES",
  /*  321 */ "VARIABLE",
  /*  322 */ "VIEW",
  /*  323 */ "WAL",
  /*  324 */ "cmd",
  /*  325 */ "account_options",
  /*  326 */ "alter_account_options",
  /*  327 */ "literal",
  /*  328 */ "alter_account_option",
  /*  329 */ "user_name",
  /*  330 */ "sysinfo_opt",
  /*  331 */ "privileges",
  /*  332 */ "priv_level",
  /*  333 */ "priv_type_list",
  /*  334 */ "priv_type",
  /*  335 */ "db_name",
  /*  336 */ "topic_name",
  /*  337 */ "dnode_endpoint",
  /*  338 */ "force_opt",
  /*  339 */ "not_exists_opt",
  /*  340 */ "db_options",
  /*  341 */ "exists_opt",
  /*  342 */ "alter_db_options",
  /*  343 */ "speed_opt",
  /*  344 */ "integer_list",
  /*  345 */ "variable_list",
  /*  346 */ "retention_list",
  /*  347 */ "alter_db_option",
  /*  348 */ "retention",
  /*  349 */ "full_table_name",
  /*  350 */ "column_def_list",
  /*  351 */ "tags_def_opt",
  /*  352 */ "table_options",
  /*  353 */ "multi_create_clause",
  /*  354 */ "tags_def",
  /*  355 */ "multi_drop_clause",
  /*  356 */ "alter_table_clause",
  /*  357 */ "alter_table_options",
  /*  358 */ "column_name",
  /*  359 */ "type_name",
  /*  360 */ "signed_literal",
  /*  361 */ "create_subtable_clause",
  /*  362 */ "specific_cols_opt",
  /*  363 */ "expression_list",
  /*  364 */ "drop_table_clause",
  /*  365 */ "col_name_list",
  /*  366 */ "table_name",
  /*  367 */ "column_def",
  /*  368 */ "duration_list",
  /*  369 */ "rollup_func_list",
  /*  370 */ "alter_table_option",
  /*  371 */ "duration_literal",
  /*  372 */ "rollup_func_name",
  /*  373 */ "function_name",
  /*  374 */ "col_name",
  /*  375 */ "db_name_cond_opt",
  /*  376 */ "like_pattern_opt",
  /*  377 */ "table_name_cond",
  /*  378 */ "from_db_opt",
  /*  379 */ "tag_list_opt",
  /*  380 */ "tag_item",
  /*  381 */ "column_alias",
  /*  382 */ "index_options",
  /*  383 */ "func_list",
  /*  384 */ "sliding_opt",
  /*  385 */ "sma_stream_opt",
  /*  386 */ "func",
1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 1898 1899 1900 1901 1902 1903 1904 1905 1906 1907 1908 1909 1910 1911 1912
  /*  387 */ "sma_func_name",
  /*  388 */ "query_or_subquery",
  /*  389 */ "cgroup_name",
  /*  390 */ "analyze_opt",
  /*  391 */ "explain_options",
  /*  392 */ "agg_func_opt",
  /*  393 */ "bufsize_opt",
  /*  394 */ "stream_name",
  /*  395 */ "stream_options",
  /*  396 */ "subtable_opt",
  /*  397 */ "expression",
  /*  398 */ "dnode_list",
  /*  399 */ "where_clause_opt",
  /*  400 */ "signed",
  /*  401 */ "literal_func",
  /*  402 */ "literal_list",
  /*  403 */ "table_alias",
  /*  404 */ "expr_or_subquery",
  /*  405 */ "pseudo_column",
  /*  406 */ "column_reference",
  /*  407 */ "function_expression",
  /*  408 */ "case_when_expression",
  /*  409 */ "star_func",
  /*  410 */ "star_func_para_list",
  /*  411 */ "noarg_func",
  /*  412 */ "other_para_list",
  /*  413 */ "star_func_para",
  /*  414 */ "when_then_list",
  /*  415 */ "case_when_else_opt",
  /*  416 */ "common_expression",
  /*  417 */ "when_then_expr",
  /*  418 */ "predicate",
  /*  419 */ "compare_op",
  /*  420 */ "in_op",
  /*  421 */ "in_predicate_value",
  /*  422 */ "boolean_value_expression",
  /*  423 */ "boolean_primary",
  /*  424 */ "from_clause_opt",
  /*  425 */ "table_reference_list",
  /*  426 */ "table_reference",
  /*  427 */ "table_primary",
  /*  428 */ "joined_table",
  /*  429 */ "alias_opt",
  /*  430 */ "subquery",
  /*  431 */ "parenthesized_joined_table",
  /*  432 */ "join_type",
  /*  433 */ "search_condition",
  /*  434 */ "query_specification",
  /*  435 */ "set_quantifier_opt",
  /*  436 */ "select_list",
  /*  437 */ "partition_by_clause_opt",
  /*  438 */ "range_opt",
  /*  439 */ "every_opt",
  /*  440 */ "fill_opt",
  /*  441 */ "twindow_clause_opt",
  /*  442 */ "group_by_clause_opt",
  /*  443 */ "having_clause_opt",
  /*  444 */ "select_item",
  /*  445 */ "partition_list",
  /*  446 */ "partition_item",
  /*  447 */ "fill_mode",
  /*  448 */ "group_by_list",
  /*  449 */ "query_expression",
  /*  450 */ "query_simple",
  /*  451 */ "order_by_clause_opt",
  /*  452 */ "slimit_clause_opt",
  /*  453 */ "limit_clause_opt",
  /*  454 */ "union_query_expression",
  /*  455 */ "query_simple_or_subquery",
  /*  456 */ "sort_specification_list",
  /*  457 */ "sort_specification",
  /*  458 */ "ordering_specification_opt",
  /*  459 */ "null_ordering_opt",
1913 1914 1915 1916 1917 1918 1919
};
#endif /* defined(YYCOVERAGE) || !defined(NDEBUG) */

#ifndef NDEBUG
/* For tracing reduce actions, the names of all rules are required.
*/
static const char *const yyRuleName[] = {
1920 1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 1939 1940 1941 1942 1943
 /*   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",
X
Xiaoyu Wang 已提交
1944
 /*  24 */ "cmd ::= CREATE USER user_name PASS NK_STRING sysinfo_opt",
1945
 /*  25 */ "cmd ::= ALTER USER user_name PASS NK_STRING",
X
Xiaoyu Wang 已提交
1946 1947 1948 1949 1950 1951 1952 1953 1954
 /*  26 */ "cmd ::= ALTER USER user_name ENABLE NK_INTEGER",
 /*  27 */ "cmd ::= ALTER USER user_name SYSINFO NK_INTEGER",
 /*  28 */ "cmd ::= DROP USER user_name",
 /*  29 */ "sysinfo_opt ::=",
 /*  30 */ "sysinfo_opt ::= SYSINFO NK_INTEGER",
 /*  31 */ "cmd ::= GRANT privileges ON priv_level TO user_name",
 /*  32 */ "cmd ::= REVOKE privileges ON priv_level FROM user_name",
 /*  33 */ "privileges ::= ALL",
 /*  34 */ "privileges ::= priv_type_list",
1955 1956 1957 1958 1959 1960 1961 1962 1963 1964 1965 1966 1967 1968 1969 1970 1971 1972 1973 1974 1975 1976 1977 1978 1979 1980 1981 1982 1983 1984 1985 1986 1987 1988 1989 1990 1991 1992 1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011
 /*  35 */ "privileges ::= SUBSCRIBE",
 /*  36 */ "priv_type_list ::= priv_type",
 /*  37 */ "priv_type_list ::= priv_type_list NK_COMMA priv_type",
 /*  38 */ "priv_type ::= READ",
 /*  39 */ "priv_type ::= WRITE",
 /*  40 */ "priv_level ::= NK_STAR NK_DOT NK_STAR",
 /*  41 */ "priv_level ::= db_name NK_DOT NK_STAR",
 /*  42 */ "priv_level ::= topic_name",
 /*  43 */ "cmd ::= CREATE DNODE dnode_endpoint",
 /*  44 */ "cmd ::= CREATE DNODE dnode_endpoint PORT NK_INTEGER",
 /*  45 */ "cmd ::= DROP DNODE NK_INTEGER force_opt",
 /*  46 */ "cmd ::= DROP DNODE dnode_endpoint force_opt",
 /*  47 */ "cmd ::= ALTER DNODE NK_INTEGER NK_STRING",
 /*  48 */ "cmd ::= ALTER DNODE NK_INTEGER NK_STRING NK_STRING",
 /*  49 */ "cmd ::= ALTER ALL DNODES NK_STRING",
 /*  50 */ "cmd ::= ALTER ALL DNODES NK_STRING NK_STRING",
 /*  51 */ "dnode_endpoint ::= NK_STRING",
 /*  52 */ "dnode_endpoint ::= NK_ID",
 /*  53 */ "dnode_endpoint ::= NK_IPTOKEN",
 /*  54 */ "force_opt ::=",
 /*  55 */ "force_opt ::= FORCE",
 /*  56 */ "cmd ::= ALTER LOCAL NK_STRING",
 /*  57 */ "cmd ::= ALTER LOCAL NK_STRING NK_STRING",
 /*  58 */ "cmd ::= CREATE QNODE ON DNODE NK_INTEGER",
 /*  59 */ "cmd ::= DROP QNODE ON DNODE NK_INTEGER",
 /*  60 */ "cmd ::= CREATE BNODE ON DNODE NK_INTEGER",
 /*  61 */ "cmd ::= DROP BNODE ON DNODE NK_INTEGER",
 /*  62 */ "cmd ::= CREATE SNODE ON DNODE NK_INTEGER",
 /*  63 */ "cmd ::= DROP SNODE ON DNODE NK_INTEGER",
 /*  64 */ "cmd ::= CREATE MNODE ON DNODE NK_INTEGER",
 /*  65 */ "cmd ::= DROP MNODE ON DNODE NK_INTEGER",
 /*  66 */ "cmd ::= CREATE DATABASE not_exists_opt db_name db_options",
 /*  67 */ "cmd ::= DROP DATABASE exists_opt db_name",
 /*  68 */ "cmd ::= USE db_name",
 /*  69 */ "cmd ::= ALTER DATABASE db_name alter_db_options",
 /*  70 */ "cmd ::= FLUSH DATABASE db_name",
 /*  71 */ "cmd ::= TRIM DATABASE db_name speed_opt",
 /*  72 */ "not_exists_opt ::= IF NOT EXISTS",
 /*  73 */ "not_exists_opt ::=",
 /*  74 */ "exists_opt ::= IF EXISTS",
 /*  75 */ "exists_opt ::=",
 /*  76 */ "db_options ::=",
 /*  77 */ "db_options ::= db_options BUFFER NK_INTEGER",
 /*  78 */ "db_options ::= db_options CACHEMODEL NK_STRING",
 /*  79 */ "db_options ::= db_options CACHESIZE NK_INTEGER",
 /*  80 */ "db_options ::= db_options COMP NK_INTEGER",
 /*  81 */ "db_options ::= db_options DURATION NK_INTEGER",
 /*  82 */ "db_options ::= db_options DURATION NK_VARIABLE",
 /*  83 */ "db_options ::= db_options MAXROWS NK_INTEGER",
 /*  84 */ "db_options ::= db_options MINROWS NK_INTEGER",
 /*  85 */ "db_options ::= db_options KEEP integer_list",
 /*  86 */ "db_options ::= db_options KEEP variable_list",
 /*  87 */ "db_options ::= db_options PAGES NK_INTEGER",
 /*  88 */ "db_options ::= db_options PAGESIZE NK_INTEGER",
 /*  89 */ "db_options ::= db_options TSDB_PAGESIZE NK_INTEGER",
 /*  90 */ "db_options ::= db_options PRECISION NK_STRING",
 /*  91 */ "db_options ::= db_options REPLICA NK_INTEGER",
2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026 2027 2028 2029 2030 2031 2032 2033 2034 2035 2036 2037 2038 2039 2040 2041 2042 2043 2044 2045 2046 2047 2048 2049 2050 2051 2052 2053 2054 2055 2056 2057 2058 2059 2060 2061 2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 2072 2073 2074 2075 2076 2077 2078 2079 2080 2081 2082 2083 2084 2085 2086 2087 2088 2089 2090 2091 2092 2093 2094 2095 2096 2097 2098 2099 2100 2101 2102 2103 2104 2105 2106 2107 2108 2109 2110 2111 2112 2113 2114 2115 2116 2117 2118 2119 2120 2121 2122 2123 2124 2125 2126 2127 2128 2129 2130 2131 2132 2133 2134 2135 2136 2137 2138 2139 2140 2141 2142 2143 2144 2145 2146 2147 2148 2149 2150 2151 2152 2153 2154 2155 2156 2157 2158 2159 2160 2161 2162 2163 2164 2165 2166 2167 2168 2169 2170 2171 2172 2173 2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185
 /*  92 */ "db_options ::= db_options VGROUPS NK_INTEGER",
 /*  93 */ "db_options ::= db_options SINGLE_STABLE NK_INTEGER",
 /*  94 */ "db_options ::= db_options RETENTIONS retention_list",
 /*  95 */ "db_options ::= db_options SCHEMALESS NK_INTEGER",
 /*  96 */ "db_options ::= db_options WAL_LEVEL NK_INTEGER",
 /*  97 */ "db_options ::= db_options WAL_FSYNC_PERIOD NK_INTEGER",
 /*  98 */ "db_options ::= db_options WAL_RETENTION_PERIOD NK_INTEGER",
 /*  99 */ "db_options ::= db_options WAL_RETENTION_PERIOD NK_MINUS NK_INTEGER",
 /* 100 */ "db_options ::= db_options WAL_RETENTION_SIZE NK_INTEGER",
 /* 101 */ "db_options ::= db_options WAL_RETENTION_SIZE NK_MINUS NK_INTEGER",
 /* 102 */ "db_options ::= db_options WAL_ROLL_PERIOD NK_INTEGER",
 /* 103 */ "db_options ::= db_options WAL_SEGMENT_SIZE NK_INTEGER",
 /* 104 */ "db_options ::= db_options STT_TRIGGER NK_INTEGER",
 /* 105 */ "db_options ::= db_options TABLE_PREFIX NK_INTEGER",
 /* 106 */ "db_options ::= db_options TABLE_SUFFIX NK_INTEGER",
 /* 107 */ "alter_db_options ::= alter_db_option",
 /* 108 */ "alter_db_options ::= alter_db_options alter_db_option",
 /* 109 */ "alter_db_option ::= BUFFER NK_INTEGER",
 /* 110 */ "alter_db_option ::= CACHEMODEL NK_STRING",
 /* 111 */ "alter_db_option ::= CACHESIZE NK_INTEGER",
 /* 112 */ "alter_db_option ::= WAL_FSYNC_PERIOD NK_INTEGER",
 /* 113 */ "alter_db_option ::= KEEP integer_list",
 /* 114 */ "alter_db_option ::= KEEP variable_list",
 /* 115 */ "alter_db_option ::= PAGES NK_INTEGER",
 /* 116 */ "alter_db_option ::= REPLICA NK_INTEGER",
 /* 117 */ "alter_db_option ::= WAL_LEVEL NK_INTEGER",
 /* 118 */ "alter_db_option ::= STT_TRIGGER NK_INTEGER",
 /* 119 */ "integer_list ::= NK_INTEGER",
 /* 120 */ "integer_list ::= integer_list NK_COMMA NK_INTEGER",
 /* 121 */ "variable_list ::= NK_VARIABLE",
 /* 122 */ "variable_list ::= variable_list NK_COMMA NK_VARIABLE",
 /* 123 */ "retention_list ::= retention",
 /* 124 */ "retention_list ::= retention_list NK_COMMA retention",
 /* 125 */ "retention ::= NK_VARIABLE NK_COLON NK_VARIABLE",
 /* 126 */ "speed_opt ::=",
 /* 127 */ "speed_opt ::= MAX_SPEED NK_INTEGER",
 /* 128 */ "cmd ::= CREATE TABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def_opt table_options",
 /* 129 */ "cmd ::= CREATE TABLE multi_create_clause",
 /* 130 */ "cmd ::= CREATE STABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def table_options",
 /* 131 */ "cmd ::= DROP TABLE multi_drop_clause",
 /* 132 */ "cmd ::= DROP STABLE exists_opt full_table_name",
 /* 133 */ "cmd ::= ALTER TABLE alter_table_clause",
 /* 134 */ "cmd ::= ALTER STABLE alter_table_clause",
 /* 135 */ "alter_table_clause ::= full_table_name alter_table_options",
 /* 136 */ "alter_table_clause ::= full_table_name ADD COLUMN column_name type_name",
 /* 137 */ "alter_table_clause ::= full_table_name DROP COLUMN column_name",
 /* 138 */ "alter_table_clause ::= full_table_name MODIFY COLUMN column_name type_name",
 /* 139 */ "alter_table_clause ::= full_table_name RENAME COLUMN column_name column_name",
 /* 140 */ "alter_table_clause ::= full_table_name ADD TAG column_name type_name",
 /* 141 */ "alter_table_clause ::= full_table_name DROP TAG column_name",
 /* 142 */ "alter_table_clause ::= full_table_name MODIFY TAG column_name type_name",
 /* 143 */ "alter_table_clause ::= full_table_name RENAME TAG column_name column_name",
 /* 144 */ "alter_table_clause ::= full_table_name SET TAG column_name NK_EQ signed_literal",
 /* 145 */ "multi_create_clause ::= create_subtable_clause",
 /* 146 */ "multi_create_clause ::= multi_create_clause create_subtable_clause",
 /* 147 */ "create_subtable_clause ::= not_exists_opt full_table_name USING full_table_name specific_cols_opt TAGS NK_LP expression_list NK_RP table_options",
 /* 148 */ "multi_drop_clause ::= drop_table_clause",
 /* 149 */ "multi_drop_clause ::= multi_drop_clause drop_table_clause",
 /* 150 */ "drop_table_clause ::= exists_opt full_table_name",
 /* 151 */ "specific_cols_opt ::=",
 /* 152 */ "specific_cols_opt ::= NK_LP col_name_list NK_RP",
 /* 153 */ "full_table_name ::= table_name",
 /* 154 */ "full_table_name ::= db_name NK_DOT table_name",
 /* 155 */ "column_def_list ::= column_def",
 /* 156 */ "column_def_list ::= column_def_list NK_COMMA column_def",
 /* 157 */ "column_def ::= column_name type_name",
 /* 158 */ "column_def ::= column_name type_name COMMENT NK_STRING",
 /* 159 */ "type_name ::= BOOL",
 /* 160 */ "type_name ::= TINYINT",
 /* 161 */ "type_name ::= SMALLINT",
 /* 162 */ "type_name ::= INT",
 /* 163 */ "type_name ::= INTEGER",
 /* 164 */ "type_name ::= BIGINT",
 /* 165 */ "type_name ::= FLOAT",
 /* 166 */ "type_name ::= DOUBLE",
 /* 167 */ "type_name ::= BINARY NK_LP NK_INTEGER NK_RP",
 /* 168 */ "type_name ::= TIMESTAMP",
 /* 169 */ "type_name ::= NCHAR NK_LP NK_INTEGER NK_RP",
 /* 170 */ "type_name ::= TINYINT UNSIGNED",
 /* 171 */ "type_name ::= SMALLINT UNSIGNED",
 /* 172 */ "type_name ::= INT UNSIGNED",
 /* 173 */ "type_name ::= BIGINT UNSIGNED",
 /* 174 */ "type_name ::= JSON",
 /* 175 */ "type_name ::= VARCHAR NK_LP NK_INTEGER NK_RP",
 /* 176 */ "type_name ::= MEDIUMBLOB",
 /* 177 */ "type_name ::= BLOB",
 /* 178 */ "type_name ::= VARBINARY NK_LP NK_INTEGER NK_RP",
 /* 179 */ "type_name ::= DECIMAL",
 /* 180 */ "type_name ::= DECIMAL NK_LP NK_INTEGER NK_RP",
 /* 181 */ "type_name ::= DECIMAL NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP",
 /* 182 */ "tags_def_opt ::=",
 /* 183 */ "tags_def_opt ::= tags_def",
 /* 184 */ "tags_def ::= TAGS NK_LP column_def_list NK_RP",
 /* 185 */ "table_options ::=",
 /* 186 */ "table_options ::= table_options COMMENT NK_STRING",
 /* 187 */ "table_options ::= table_options MAX_DELAY duration_list",
 /* 188 */ "table_options ::= table_options WATERMARK duration_list",
 /* 189 */ "table_options ::= table_options ROLLUP NK_LP rollup_func_list NK_RP",
 /* 190 */ "table_options ::= table_options TTL NK_INTEGER",
 /* 191 */ "table_options ::= table_options SMA NK_LP col_name_list NK_RP",
 /* 192 */ "table_options ::= table_options DELETE_MARK duration_list",
 /* 193 */ "alter_table_options ::= alter_table_option",
 /* 194 */ "alter_table_options ::= alter_table_options alter_table_option",
 /* 195 */ "alter_table_option ::= COMMENT NK_STRING",
 /* 196 */ "alter_table_option ::= TTL NK_INTEGER",
 /* 197 */ "duration_list ::= duration_literal",
 /* 198 */ "duration_list ::= duration_list NK_COMMA duration_literal",
 /* 199 */ "rollup_func_list ::= rollup_func_name",
 /* 200 */ "rollup_func_list ::= rollup_func_list NK_COMMA rollup_func_name",
 /* 201 */ "rollup_func_name ::= function_name",
 /* 202 */ "rollup_func_name ::= FIRST",
 /* 203 */ "rollup_func_name ::= LAST",
 /* 204 */ "col_name_list ::= col_name",
 /* 205 */ "col_name_list ::= col_name_list NK_COMMA col_name",
 /* 206 */ "col_name ::= column_name",
 /* 207 */ "cmd ::= SHOW DNODES",
 /* 208 */ "cmd ::= SHOW USERS",
 /* 209 */ "cmd ::= SHOW USER PRIVILEGES",
 /* 210 */ "cmd ::= SHOW DATABASES",
 /* 211 */ "cmd ::= SHOW db_name_cond_opt TABLES like_pattern_opt",
 /* 212 */ "cmd ::= SHOW db_name_cond_opt STABLES like_pattern_opt",
 /* 213 */ "cmd ::= SHOW db_name_cond_opt VGROUPS",
 /* 214 */ "cmd ::= SHOW MNODES",
 /* 215 */ "cmd ::= SHOW QNODES",
 /* 216 */ "cmd ::= SHOW FUNCTIONS",
 /* 217 */ "cmd ::= SHOW INDEXES FROM table_name_cond from_db_opt",
 /* 218 */ "cmd ::= SHOW STREAMS",
 /* 219 */ "cmd ::= SHOW ACCOUNTS",
 /* 220 */ "cmd ::= SHOW APPS",
 /* 221 */ "cmd ::= SHOW CONNECTIONS",
 /* 222 */ "cmd ::= SHOW LICENCES",
 /* 223 */ "cmd ::= SHOW GRANTS",
 /* 224 */ "cmd ::= SHOW CREATE DATABASE db_name",
 /* 225 */ "cmd ::= SHOW CREATE TABLE full_table_name",
 /* 226 */ "cmd ::= SHOW CREATE STABLE full_table_name",
 /* 227 */ "cmd ::= SHOW QUERIES",
 /* 228 */ "cmd ::= SHOW SCORES",
 /* 229 */ "cmd ::= SHOW TOPICS",
 /* 230 */ "cmd ::= SHOW VARIABLES",
 /* 231 */ "cmd ::= SHOW CLUSTER VARIABLES",
 /* 232 */ "cmd ::= SHOW LOCAL VARIABLES",
 /* 233 */ "cmd ::= SHOW DNODE NK_INTEGER VARIABLES like_pattern_opt",
 /* 234 */ "cmd ::= SHOW BNODES",
 /* 235 */ "cmd ::= SHOW SNODES",
 /* 236 */ "cmd ::= SHOW CLUSTER",
 /* 237 */ "cmd ::= SHOW TRANSACTIONS",
 /* 238 */ "cmd ::= SHOW TABLE DISTRIBUTED full_table_name",
 /* 239 */ "cmd ::= SHOW CONSUMERS",
 /* 240 */ "cmd ::= SHOW SUBSCRIPTIONS",
 /* 241 */ "cmd ::= SHOW TAGS FROM table_name_cond from_db_opt",
 /* 242 */ "cmd ::= SHOW TABLE TAGS tag_list_opt FROM table_name_cond from_db_opt",
 /* 243 */ "cmd ::= SHOW VNODES NK_INTEGER",
 /* 244 */ "cmd ::= SHOW VNODES NK_STRING",
 /* 245 */ "db_name_cond_opt ::=",
 /* 246 */ "db_name_cond_opt ::= db_name NK_DOT",
 /* 247 */ "like_pattern_opt ::=",
 /* 248 */ "like_pattern_opt ::= LIKE NK_STRING",
 /* 249 */ "table_name_cond ::= table_name",
 /* 250 */ "from_db_opt ::=",
 /* 251 */ "from_db_opt ::= FROM db_name",
 /* 252 */ "tag_list_opt ::=",
 /* 253 */ "tag_list_opt ::= tag_item",
 /* 254 */ "tag_list_opt ::= tag_list_opt NK_COMMA tag_item",
 /* 255 */ "tag_item ::= TBNAME",
 /* 256 */ "tag_item ::= QTAGS",
 /* 257 */ "tag_item ::= column_name",
 /* 258 */ "tag_item ::= column_name column_alias",
 /* 259 */ "tag_item ::= column_name AS column_alias",
 /* 260 */ "cmd ::= CREATE SMA INDEX not_exists_opt full_table_name ON full_table_name index_options",
 /* 261 */ "cmd ::= DROP INDEX exists_opt full_table_name",
 /* 262 */ "index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_RP sliding_opt sma_stream_opt",
 /* 263 */ "index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt sma_stream_opt",
 /* 264 */ "func_list ::= func",
 /* 265 */ "func_list ::= func_list NK_COMMA func",
2186 2187 2188 2189 2190 2191 2192 2193 2194 2195 2196 2197 2198 2199 2200 2201 2202 2203 2204 2205 2206 2207 2208 2209 2210 2211 2212 2213 2214 2215 2216 2217 2218 2219 2220 2221 2222 2223 2224 2225 2226 2227 2228 2229 2230 2231 2232 2233 2234 2235 2236 2237 2238 2239 2240 2241 2242 2243 2244 2245 2246 2247 2248 2249 2250 2251 2252 2253 2254 2255 2256 2257 2258 2259 2260 2261 2262 2263 2264 2265 2266 2267 2268 2269 2270 2271 2272 2273 2274 2275 2276 2277 2278 2279 2280 2281 2282 2283 2284 2285 2286 2287 2288 2289 2290 2291 2292 2293 2294 2295 2296 2297 2298 2299 2300 2301 2302 2303 2304 2305 2306 2307 2308 2309 2310 2311 2312 2313 2314 2315 2316 2317 2318 2319 2320 2321 2322 2323 2324 2325 2326 2327 2328 2329 2330 2331 2332 2333 2334 2335 2336 2337 2338 2339 2340 2341 2342 2343 2344 2345 2346 2347 2348 2349 2350 2351 2352 2353 2354 2355 2356 2357 2358 2359 2360 2361 2362 2363 2364 2365 2366 2367 2368 2369 2370 2371 2372 2373 2374 2375 2376 2377 2378 2379 2380 2381 2382 2383 2384 2385 2386 2387 2388 2389 2390 2391 2392 2393 2394 2395 2396 2397 2398 2399 2400 2401 2402 2403 2404 2405 2406 2407 2408 2409 2410 2411 2412 2413 2414 2415 2416 2417 2418 2419 2420 2421 2422 2423 2424 2425 2426 2427 2428 2429 2430 2431 2432 2433 2434 2435 2436 2437 2438 2439 2440 2441 2442 2443 2444 2445 2446 2447 2448 2449 2450 2451 2452 2453 2454 2455 2456 2457 2458 2459 2460 2461 2462 2463
 /* 266 */ "func ::= sma_func_name NK_LP expression_list NK_RP",
 /* 267 */ "sma_func_name ::= function_name",
 /* 268 */ "sma_func_name ::= COUNT",
 /* 269 */ "sma_func_name ::= FIRST",
 /* 270 */ "sma_func_name ::= LAST",
 /* 271 */ "sma_func_name ::= LAST_ROW",
 /* 272 */ "sma_stream_opt ::=",
 /* 273 */ "sma_stream_opt ::= sma_stream_opt WATERMARK duration_literal",
 /* 274 */ "sma_stream_opt ::= sma_stream_opt MAX_DELAY duration_literal",
 /* 275 */ "sma_stream_opt ::= sma_stream_opt DELETE_MARK duration_literal",
 /* 276 */ "cmd ::= CREATE TOPIC not_exists_opt topic_name AS query_or_subquery",
 /* 277 */ "cmd ::= CREATE TOPIC not_exists_opt topic_name AS DATABASE db_name",
 /* 278 */ "cmd ::= CREATE TOPIC not_exists_opt topic_name WITH META AS DATABASE db_name",
 /* 279 */ "cmd ::= CREATE TOPIC not_exists_opt topic_name AS STABLE full_table_name",
 /* 280 */ "cmd ::= CREATE TOPIC not_exists_opt topic_name WITH META AS STABLE full_table_name",
 /* 281 */ "cmd ::= DROP TOPIC exists_opt topic_name",
 /* 282 */ "cmd ::= DROP CONSUMER GROUP exists_opt cgroup_name ON topic_name",
 /* 283 */ "cmd ::= DESC full_table_name",
 /* 284 */ "cmd ::= DESCRIBE full_table_name",
 /* 285 */ "cmd ::= RESET QUERY CACHE",
 /* 286 */ "cmd ::= EXPLAIN analyze_opt explain_options query_or_subquery",
 /* 287 */ "analyze_opt ::=",
 /* 288 */ "analyze_opt ::= ANALYZE",
 /* 289 */ "explain_options ::=",
 /* 290 */ "explain_options ::= explain_options VERBOSE NK_BOOL",
 /* 291 */ "explain_options ::= explain_options RATIO NK_FLOAT",
 /* 292 */ "cmd ::= CREATE agg_func_opt FUNCTION not_exists_opt function_name AS NK_STRING OUTPUTTYPE type_name bufsize_opt",
 /* 293 */ "cmd ::= DROP FUNCTION exists_opt function_name",
 /* 294 */ "agg_func_opt ::=",
 /* 295 */ "agg_func_opt ::= AGGREGATE",
 /* 296 */ "bufsize_opt ::=",
 /* 297 */ "bufsize_opt ::= BUFSIZE NK_INTEGER",
 /* 298 */ "cmd ::= CREATE STREAM not_exists_opt stream_name stream_options INTO full_table_name tags_def_opt subtable_opt AS query_or_subquery",
 /* 299 */ "cmd ::= DROP STREAM exists_opt stream_name",
 /* 300 */ "stream_options ::=",
 /* 301 */ "stream_options ::= stream_options TRIGGER AT_ONCE",
 /* 302 */ "stream_options ::= stream_options TRIGGER WINDOW_CLOSE",
 /* 303 */ "stream_options ::= stream_options TRIGGER MAX_DELAY duration_literal",
 /* 304 */ "stream_options ::= stream_options WATERMARK duration_literal",
 /* 305 */ "stream_options ::= stream_options IGNORE EXPIRED NK_INTEGER",
 /* 306 */ "stream_options ::= stream_options FILL_HISTORY NK_INTEGER",
 /* 307 */ "subtable_opt ::=",
 /* 308 */ "subtable_opt ::= SUBTABLE NK_LP expression NK_RP",
 /* 309 */ "cmd ::= KILL CONNECTION NK_INTEGER",
 /* 310 */ "cmd ::= KILL QUERY NK_STRING",
 /* 311 */ "cmd ::= KILL TRANSACTION NK_INTEGER",
 /* 312 */ "cmd ::= BALANCE VGROUP",
 /* 313 */ "cmd ::= MERGE VGROUP NK_INTEGER NK_INTEGER",
 /* 314 */ "cmd ::= REDISTRIBUTE VGROUP NK_INTEGER dnode_list",
 /* 315 */ "cmd ::= SPLIT VGROUP NK_INTEGER",
 /* 316 */ "dnode_list ::= DNODE NK_INTEGER",
 /* 317 */ "dnode_list ::= dnode_list DNODE NK_INTEGER",
 /* 318 */ "cmd ::= DELETE FROM full_table_name where_clause_opt",
 /* 319 */ "cmd ::= query_or_subquery",
 /* 320 */ "cmd ::= INSERT INTO full_table_name NK_LP col_name_list NK_RP query_or_subquery",
 /* 321 */ "cmd ::= INSERT INTO full_table_name query_or_subquery",
 /* 322 */ "literal ::= NK_INTEGER",
 /* 323 */ "literal ::= NK_FLOAT",
 /* 324 */ "literal ::= NK_STRING",
 /* 325 */ "literal ::= NK_BOOL",
 /* 326 */ "literal ::= TIMESTAMP NK_STRING",
 /* 327 */ "literal ::= duration_literal",
 /* 328 */ "literal ::= NULL",
 /* 329 */ "literal ::= NK_QUESTION",
 /* 330 */ "duration_literal ::= NK_VARIABLE",
 /* 331 */ "signed ::= NK_INTEGER",
 /* 332 */ "signed ::= NK_PLUS NK_INTEGER",
 /* 333 */ "signed ::= NK_MINUS NK_INTEGER",
 /* 334 */ "signed ::= NK_FLOAT",
 /* 335 */ "signed ::= NK_PLUS NK_FLOAT",
 /* 336 */ "signed ::= NK_MINUS NK_FLOAT",
 /* 337 */ "signed_literal ::= signed",
 /* 338 */ "signed_literal ::= NK_STRING",
 /* 339 */ "signed_literal ::= NK_BOOL",
 /* 340 */ "signed_literal ::= TIMESTAMP NK_STRING",
 /* 341 */ "signed_literal ::= duration_literal",
 /* 342 */ "signed_literal ::= NULL",
 /* 343 */ "signed_literal ::= literal_func",
 /* 344 */ "signed_literal ::= NK_QUESTION",
 /* 345 */ "literal_list ::= signed_literal",
 /* 346 */ "literal_list ::= literal_list NK_COMMA signed_literal",
 /* 347 */ "db_name ::= NK_ID",
 /* 348 */ "table_name ::= NK_ID",
 /* 349 */ "column_name ::= NK_ID",
 /* 350 */ "function_name ::= NK_ID",
 /* 351 */ "table_alias ::= NK_ID",
 /* 352 */ "column_alias ::= NK_ID",
 /* 353 */ "user_name ::= NK_ID",
 /* 354 */ "topic_name ::= NK_ID",
 /* 355 */ "stream_name ::= NK_ID",
 /* 356 */ "cgroup_name ::= NK_ID",
 /* 357 */ "expr_or_subquery ::= expression",
 /* 358 */ "expression ::= literal",
 /* 359 */ "expression ::= pseudo_column",
 /* 360 */ "expression ::= column_reference",
 /* 361 */ "expression ::= function_expression",
 /* 362 */ "expression ::= case_when_expression",
 /* 363 */ "expression ::= NK_LP expression NK_RP",
 /* 364 */ "expression ::= NK_PLUS expr_or_subquery",
 /* 365 */ "expression ::= NK_MINUS expr_or_subquery",
 /* 366 */ "expression ::= expr_or_subquery NK_PLUS expr_or_subquery",
 /* 367 */ "expression ::= expr_or_subquery NK_MINUS expr_or_subquery",
 /* 368 */ "expression ::= expr_or_subquery NK_STAR expr_or_subquery",
 /* 369 */ "expression ::= expr_or_subquery NK_SLASH expr_or_subquery",
 /* 370 */ "expression ::= expr_or_subquery NK_REM expr_or_subquery",
 /* 371 */ "expression ::= column_reference NK_ARROW NK_STRING",
 /* 372 */ "expression ::= expr_or_subquery NK_BITAND expr_or_subquery",
 /* 373 */ "expression ::= expr_or_subquery NK_BITOR expr_or_subquery",
 /* 374 */ "expression_list ::= expr_or_subquery",
 /* 375 */ "expression_list ::= expression_list NK_COMMA expr_or_subquery",
 /* 376 */ "column_reference ::= column_name",
 /* 377 */ "column_reference ::= table_name NK_DOT column_name",
 /* 378 */ "pseudo_column ::= ROWTS",
 /* 379 */ "pseudo_column ::= TBNAME",
 /* 380 */ "pseudo_column ::= table_name NK_DOT TBNAME",
 /* 381 */ "pseudo_column ::= QSTART",
 /* 382 */ "pseudo_column ::= QEND",
 /* 383 */ "pseudo_column ::= QDURATION",
 /* 384 */ "pseudo_column ::= WSTART",
 /* 385 */ "pseudo_column ::= WEND",
 /* 386 */ "pseudo_column ::= WDURATION",
 /* 387 */ "pseudo_column ::= IROWTS",
 /* 388 */ "pseudo_column ::= QTAGS",
 /* 389 */ "function_expression ::= function_name NK_LP expression_list NK_RP",
 /* 390 */ "function_expression ::= star_func NK_LP star_func_para_list NK_RP",
 /* 391 */ "function_expression ::= CAST NK_LP expr_or_subquery AS type_name NK_RP",
 /* 392 */ "function_expression ::= literal_func",
 /* 393 */ "literal_func ::= noarg_func NK_LP NK_RP",
 /* 394 */ "literal_func ::= NOW",
 /* 395 */ "noarg_func ::= NOW",
 /* 396 */ "noarg_func ::= TODAY",
 /* 397 */ "noarg_func ::= TIMEZONE",
 /* 398 */ "noarg_func ::= DATABASE",
 /* 399 */ "noarg_func ::= CLIENT_VERSION",
 /* 400 */ "noarg_func ::= SERVER_VERSION",
 /* 401 */ "noarg_func ::= SERVER_STATUS",
 /* 402 */ "noarg_func ::= CURRENT_USER",
 /* 403 */ "noarg_func ::= USER",
 /* 404 */ "star_func ::= COUNT",
 /* 405 */ "star_func ::= FIRST",
 /* 406 */ "star_func ::= LAST",
 /* 407 */ "star_func ::= LAST_ROW",
 /* 408 */ "star_func_para_list ::= NK_STAR",
 /* 409 */ "star_func_para_list ::= other_para_list",
 /* 410 */ "other_para_list ::= star_func_para",
 /* 411 */ "other_para_list ::= other_para_list NK_COMMA star_func_para",
 /* 412 */ "star_func_para ::= expr_or_subquery",
 /* 413 */ "star_func_para ::= table_name NK_DOT NK_STAR",
 /* 414 */ "case_when_expression ::= CASE when_then_list case_when_else_opt END",
 /* 415 */ "case_when_expression ::= CASE common_expression when_then_list case_when_else_opt END",
 /* 416 */ "when_then_list ::= when_then_expr",
 /* 417 */ "when_then_list ::= when_then_list when_then_expr",
 /* 418 */ "when_then_expr ::= WHEN common_expression THEN common_expression",
 /* 419 */ "case_when_else_opt ::=",
 /* 420 */ "case_when_else_opt ::= ELSE common_expression",
 /* 421 */ "predicate ::= expr_or_subquery compare_op expr_or_subquery",
 /* 422 */ "predicate ::= expr_or_subquery BETWEEN expr_or_subquery AND expr_or_subquery",
 /* 423 */ "predicate ::= expr_or_subquery NOT BETWEEN expr_or_subquery AND expr_or_subquery",
 /* 424 */ "predicate ::= expr_or_subquery IS NULL",
 /* 425 */ "predicate ::= expr_or_subquery IS NOT NULL",
 /* 426 */ "predicate ::= expr_or_subquery in_op in_predicate_value",
 /* 427 */ "compare_op ::= NK_LT",
 /* 428 */ "compare_op ::= NK_GT",
 /* 429 */ "compare_op ::= NK_LE",
 /* 430 */ "compare_op ::= NK_GE",
 /* 431 */ "compare_op ::= NK_NE",
 /* 432 */ "compare_op ::= NK_EQ",
 /* 433 */ "compare_op ::= LIKE",
 /* 434 */ "compare_op ::= NOT LIKE",
 /* 435 */ "compare_op ::= MATCH",
 /* 436 */ "compare_op ::= NMATCH",
 /* 437 */ "compare_op ::= CONTAINS",
 /* 438 */ "in_op ::= IN",
 /* 439 */ "in_op ::= NOT IN",
 /* 440 */ "in_predicate_value ::= NK_LP literal_list NK_RP",
 /* 441 */ "boolean_value_expression ::= boolean_primary",
 /* 442 */ "boolean_value_expression ::= NOT boolean_primary",
 /* 443 */ "boolean_value_expression ::= boolean_value_expression OR boolean_value_expression",
 /* 444 */ "boolean_value_expression ::= boolean_value_expression AND boolean_value_expression",
 /* 445 */ "boolean_primary ::= predicate",
 /* 446 */ "boolean_primary ::= NK_LP boolean_value_expression NK_RP",
 /* 447 */ "common_expression ::= expr_or_subquery",
 /* 448 */ "common_expression ::= boolean_value_expression",
 /* 449 */ "from_clause_opt ::=",
 /* 450 */ "from_clause_opt ::= FROM table_reference_list",
 /* 451 */ "table_reference_list ::= table_reference",
 /* 452 */ "table_reference_list ::= table_reference_list NK_COMMA table_reference",
 /* 453 */ "table_reference ::= table_primary",
 /* 454 */ "table_reference ::= joined_table",
 /* 455 */ "table_primary ::= table_name alias_opt",
 /* 456 */ "table_primary ::= db_name NK_DOT table_name alias_opt",
 /* 457 */ "table_primary ::= subquery alias_opt",
 /* 458 */ "table_primary ::= parenthesized_joined_table",
 /* 459 */ "alias_opt ::=",
 /* 460 */ "alias_opt ::= table_alias",
 /* 461 */ "alias_opt ::= AS table_alias",
 /* 462 */ "parenthesized_joined_table ::= NK_LP joined_table NK_RP",
 /* 463 */ "parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP",
 /* 464 */ "joined_table ::= table_reference join_type JOIN table_reference ON search_condition",
 /* 465 */ "join_type ::=",
 /* 466 */ "join_type ::= INNER",
 /* 467 */ "query_specification ::= SELECT set_quantifier_opt select_list from_clause_opt where_clause_opt partition_by_clause_opt range_opt every_opt fill_opt twindow_clause_opt group_by_clause_opt having_clause_opt",
 /* 468 */ "set_quantifier_opt ::=",
 /* 469 */ "set_quantifier_opt ::= DISTINCT",
 /* 470 */ "set_quantifier_opt ::= ALL",
 /* 471 */ "select_list ::= select_item",
 /* 472 */ "select_list ::= select_list NK_COMMA select_item",
 /* 473 */ "select_item ::= NK_STAR",
 /* 474 */ "select_item ::= common_expression",
 /* 475 */ "select_item ::= common_expression column_alias",
 /* 476 */ "select_item ::= common_expression AS column_alias",
 /* 477 */ "select_item ::= table_name NK_DOT NK_STAR",
 /* 478 */ "where_clause_opt ::=",
 /* 479 */ "where_clause_opt ::= WHERE search_condition",
 /* 480 */ "partition_by_clause_opt ::=",
 /* 481 */ "partition_by_clause_opt ::= PARTITION BY partition_list",
 /* 482 */ "partition_list ::= partition_item",
 /* 483 */ "partition_list ::= partition_list NK_COMMA partition_item",
 /* 484 */ "partition_item ::= expr_or_subquery",
 /* 485 */ "partition_item ::= expr_or_subquery column_alias",
 /* 486 */ "partition_item ::= expr_or_subquery AS column_alias",
 /* 487 */ "twindow_clause_opt ::=",
 /* 488 */ "twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA duration_literal NK_RP",
 /* 489 */ "twindow_clause_opt ::= STATE_WINDOW NK_LP expr_or_subquery NK_RP",
 /* 490 */ "twindow_clause_opt ::= INTERVAL NK_LP duration_literal NK_RP sliding_opt fill_opt",
 /* 491 */ "twindow_clause_opt ::= INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt fill_opt",
 /* 492 */ "twindow_clause_opt ::= EVENT_WINDOW START WITH search_condition END WITH search_condition",
 /* 493 */ "sliding_opt ::=",
 /* 494 */ "sliding_opt ::= SLIDING NK_LP duration_literal NK_RP",
 /* 495 */ "fill_opt ::=",
 /* 496 */ "fill_opt ::= FILL NK_LP fill_mode NK_RP",
 /* 497 */ "fill_opt ::= FILL NK_LP VALUE NK_COMMA literal_list NK_RP",
 /* 498 */ "fill_mode ::= NONE",
 /* 499 */ "fill_mode ::= PREV",
 /* 500 */ "fill_mode ::= NULL",
 /* 501 */ "fill_mode ::= LINEAR",
 /* 502 */ "fill_mode ::= NEXT",
 /* 503 */ "group_by_clause_opt ::=",
 /* 504 */ "group_by_clause_opt ::= GROUP BY group_by_list",
 /* 505 */ "group_by_list ::= expr_or_subquery",
 /* 506 */ "group_by_list ::= group_by_list NK_COMMA expr_or_subquery",
 /* 507 */ "having_clause_opt ::=",
 /* 508 */ "having_clause_opt ::= HAVING search_condition",
 /* 509 */ "range_opt ::=",
 /* 510 */ "range_opt ::= RANGE NK_LP expr_or_subquery NK_COMMA expr_or_subquery NK_RP",
 /* 511 */ "every_opt ::=",
 /* 512 */ "every_opt ::= EVERY NK_LP duration_literal NK_RP",
 /* 513 */ "query_expression ::= query_simple order_by_clause_opt slimit_clause_opt limit_clause_opt",
 /* 514 */ "query_simple ::= query_specification",
 /* 515 */ "query_simple ::= union_query_expression",
 /* 516 */ "union_query_expression ::= query_simple_or_subquery UNION ALL query_simple_or_subquery",
 /* 517 */ "union_query_expression ::= query_simple_or_subquery UNION query_simple_or_subquery",
 /* 518 */ "query_simple_or_subquery ::= query_simple",
 /* 519 */ "query_simple_or_subquery ::= subquery",
 /* 520 */ "query_or_subquery ::= query_expression",
 /* 521 */ "query_or_subquery ::= subquery",
 /* 522 */ "order_by_clause_opt ::=",
 /* 523 */ "order_by_clause_opt ::= ORDER BY sort_specification_list",
 /* 524 */ "slimit_clause_opt ::=",
 /* 525 */ "slimit_clause_opt ::= SLIMIT NK_INTEGER",
 /* 526 */ "slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER",
 /* 527 */ "slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER",
 /* 528 */ "limit_clause_opt ::=",
 /* 529 */ "limit_clause_opt ::= LIMIT NK_INTEGER",
 /* 530 */ "limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER",
 /* 531 */ "limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER",
 /* 532 */ "subquery ::= NK_LP query_expression NK_RP",
 /* 533 */ "subquery ::= NK_LP subquery NK_RP",
 /* 534 */ "search_condition ::= common_expression",
 /* 535 */ "sort_specification_list ::= sort_specification",
 /* 536 */ "sort_specification_list ::= sort_specification_list NK_COMMA sort_specification",
 /* 537 */ "sort_specification ::= expr_or_subquery ordering_specification_opt null_ordering_opt",
 /* 538 */ "ordering_specification_opt ::=",
 /* 539 */ "ordering_specification_opt ::= ASC",
 /* 540 */ "ordering_specification_opt ::= DESC",
 /* 541 */ "null_ordering_opt ::=",
 /* 542 */ "null_ordering_opt ::= NULLS FIRST",
 /* 543 */ "null_ordering_opt ::= NULLS LAST",
2464 2465 2466 2467 2468 2469 2470 2471 2472 2473 2474 2475 2476 2477 2478 2479 2480
};
#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 ){
X
Xiaoyu Wang 已提交
2481
    pNew = malloc(newSize*sizeof(pNew[0]));
2482 2483
    if( pNew ) pNew[0] = p->yystk0;
  }else{
X
Xiaoyu Wang 已提交
2484
    pNew = realloc(p->yystack, newSize*sizeof(pNew[0]));
2485 2486 2487 2488 2489 2490 2491 2492 2493 2494 2495 2496 2497 2498 2499 2500 2501
  }
  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
X
Xiaoyu Wang 已提交
2502
** second argument to ParseAlloc() below.  This can be changed by
2503 2504 2505 2506 2507 2508 2509 2510 2511
** 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.
*/
X
Xiaoyu Wang 已提交
2512
void ParseInit(void *yypRawParser ParseCTX_PDECL){
2513
  yyParser *yypParser = (yyParser*)yypRawParser;
X
Xiaoyu Wang 已提交
2514
  ParseCTX_STORE
2515 2516 2517 2518 2519 2520 2521 2522 2523 2524 2525 2526 2527 2528 2529 2530 2531 2532 2533 2534 2535 2536 2537
#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
}

X
Xiaoyu Wang 已提交
2538
#ifndef Parse_ENGINEALWAYSONSTACK
2539 2540 2541 2542 2543 2544 2545 2546 2547 2548
/* 
** 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
X
Xiaoyu Wang 已提交
2549
** to Parse and ParseFree.
2550
*/
X
Xiaoyu Wang 已提交
2551
void *ParseAlloc(void *(*mallocProc)(YYMALLOCARGTYPE) ParseCTX_PDECL){
2552 2553 2554
  yyParser *yypParser;
  yypParser = (yyParser*)(*mallocProc)( (YYMALLOCARGTYPE)sizeof(yyParser) );
  if( yypParser ){
X
Xiaoyu Wang 已提交
2555 2556
    ParseCTX_STORE
    ParseInit(yypParser ParseCTX_PARAM);
2557 2558 2559
  }
  return (void*)yypParser;
}
X
Xiaoyu Wang 已提交
2560
#endif /* Parse_ENGINEALWAYSONSTACK */
2561 2562 2563 2564 2565 2566 2567 2568 2569 2570 2571 2572 2573 2574


/* 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 */
){
X
Xiaoyu Wang 已提交
2575 2576
  ParseARG_FETCH
  ParseCTX_FETCH
2577 2578 2579 2580 2581 2582 2583 2584 2585 2586 2587 2588 2589
  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 */
X
Xiaoyu Wang 已提交
2590 2591 2592 2593 2594 2595 2596 2597 2598 2599 2600 2601 2602 2603 2604 2605 2606 2607 2608 2609 2610 2611 2612 2613 2614
    case 324: /* cmd */
    case 327: /* literal */
    case 340: /* db_options */
    case 342: /* alter_db_options */
    case 348: /* retention */
    case 349: /* full_table_name */
    case 352: /* table_options */
    case 356: /* alter_table_clause */
    case 357: /* alter_table_options */
    case 360: /* signed_literal */
    case 361: /* create_subtable_clause */
    case 364: /* drop_table_clause */
    case 367: /* column_def */
    case 371: /* duration_literal */
    case 372: /* rollup_func_name */
    case 374: /* col_name */
    case 375: /* db_name_cond_opt */
    case 376: /* like_pattern_opt */
    case 377: /* table_name_cond */
    case 378: /* from_db_opt */
    case 380: /* tag_item */
    case 382: /* index_options */
    case 384: /* sliding_opt */
    case 385: /* sma_stream_opt */
    case 386: /* func */
2615 2616 2617 2618 2619 2620 2621 2622 2623 2624 2625 2626 2627 2628 2629 2630 2631 2632 2633 2634 2635 2636 2637 2638 2639 2640 2641 2642 2643 2644 2645 2646 2647 2648 2649 2650 2651 2652 2653 2654 2655 2656 2657 2658
    case 388: /* query_or_subquery */
    case 391: /* explain_options */
    case 395: /* stream_options */
    case 396: /* subtable_opt */
    case 397: /* expression */
    case 399: /* where_clause_opt */
    case 400: /* signed */
    case 401: /* literal_func */
    case 404: /* expr_or_subquery */
    case 405: /* pseudo_column */
    case 406: /* column_reference */
    case 407: /* function_expression */
    case 408: /* case_when_expression */
    case 413: /* star_func_para */
    case 415: /* case_when_else_opt */
    case 416: /* common_expression */
    case 417: /* when_then_expr */
    case 418: /* predicate */
    case 421: /* in_predicate_value */
    case 422: /* boolean_value_expression */
    case 423: /* boolean_primary */
    case 424: /* from_clause_opt */
    case 425: /* table_reference_list */
    case 426: /* table_reference */
    case 427: /* table_primary */
    case 428: /* joined_table */
    case 430: /* subquery */
    case 431: /* parenthesized_joined_table */
    case 433: /* search_condition */
    case 434: /* query_specification */
    case 438: /* range_opt */
    case 439: /* every_opt */
    case 440: /* fill_opt */
    case 441: /* twindow_clause_opt */
    case 443: /* having_clause_opt */
    case 444: /* select_item */
    case 446: /* partition_item */
    case 449: /* query_expression */
    case 450: /* query_simple */
    case 452: /* slimit_clause_opt */
    case 453: /* limit_clause_opt */
    case 454: /* union_query_expression */
    case 455: /* query_simple_or_subquery */
    case 457: /* sort_specification */
X
Xiaoyu Wang 已提交
2659
{
2660
 nodesDestroyNode((yypminor->yy752)); 
X
Xiaoyu Wang 已提交
2661 2662
}
      break;
X
Xiaoyu Wang 已提交
2663 2664 2665 2666
    case 325: /* account_options */
    case 326: /* alter_account_options */
    case 328: /* alter_account_option */
    case 343: /* speed_opt */
2667
    case 393: /* bufsize_opt */
2668
{
X
Xiaoyu Wang 已提交
2669
 
2670 2671
}
      break;
X
Xiaoyu Wang 已提交
2672 2673 2674 2675 2676 2677 2678 2679 2680
    case 329: /* user_name */
    case 332: /* priv_level */
    case 335: /* db_name */
    case 336: /* topic_name */
    case 337: /* dnode_endpoint */
    case 358: /* column_name */
    case 366: /* table_name */
    case 373: /* function_name */
    case 381: /* column_alias */
2681 2682 2683 2684 2685 2686 2687
    case 387: /* sma_func_name */
    case 389: /* cgroup_name */
    case 394: /* stream_name */
    case 403: /* table_alias */
    case 409: /* star_func */
    case 411: /* noarg_func */
    case 429: /* alias_opt */
2688
{
2689
 
2690 2691
}
      break;
X
Xiaoyu Wang 已提交
2692
    case 330: /* sysinfo_opt */
2693
{
2694
 
2695 2696
}
      break;
X
Xiaoyu Wang 已提交
2697 2698 2699
    case 331: /* privileges */
    case 333: /* priv_type_list */
    case 334: /* priv_type */
2700
{
2701
 
2702 2703
}
      break;
X
Xiaoyu Wang 已提交
2704 2705 2706
    case 338: /* force_opt */
    case 339: /* not_exists_opt */
    case 341: /* exists_opt */
2707 2708 2709
    case 390: /* analyze_opt */
    case 392: /* agg_func_opt */
    case 435: /* set_quantifier_opt */
2710
{
2711 2712 2713
 
}
      break;
X
Xiaoyu Wang 已提交
2714 2715 2716 2717 2718 2719 2720 2721 2722 2723 2724 2725 2726 2727 2728
    case 344: /* integer_list */
    case 345: /* variable_list */
    case 346: /* retention_list */
    case 350: /* column_def_list */
    case 351: /* tags_def_opt */
    case 353: /* multi_create_clause */
    case 354: /* tags_def */
    case 355: /* multi_drop_clause */
    case 362: /* specific_cols_opt */
    case 363: /* expression_list */
    case 365: /* col_name_list */
    case 368: /* duration_list */
    case 369: /* rollup_func_list */
    case 379: /* tag_list_opt */
    case 383: /* func_list */
2729 2730 2731 2732 2733 2734 2735 2736 2737 2738 2739 2740
    case 398: /* dnode_list */
    case 402: /* literal_list */
    case 410: /* star_func_para_list */
    case 412: /* other_para_list */
    case 414: /* when_then_list */
    case 436: /* select_list */
    case 437: /* partition_by_clause_opt */
    case 442: /* group_by_clause_opt */
    case 445: /* partition_list */
    case 448: /* group_by_list */
    case 451: /* order_by_clause_opt */
    case 456: /* sort_specification_list */
2741
{
2742
 nodesDestroyList((yypminor->yy424)); 
2743 2744
}
      break;
X
Xiaoyu Wang 已提交
2745 2746
    case 347: /* alter_db_option */
    case 370: /* alter_table_option */
2747
{
X
Xiaoyu Wang 已提交
2748
 
2749 2750
}
      break;
X
Xiaoyu Wang 已提交
2751
    case 359: /* type_name */
2752
{
2753
 
2754 2755
}
      break;
2756 2757
    case 419: /* compare_op */
    case 420: /* in_op */
2758
{
2759
 
2760 2761
}
      break;
2762
    case 432: /* join_type */
2763
{
2764
 
2765 2766
}
      break;
2767
    case 447: /* fill_mode */
2768
{
2769
 
2770 2771
}
      break;
2772
    case 458: /* ordering_specification_opt */
2773
{
2774
 
2775 2776
}
      break;
2777
    case 459: /* null_ordering_opt */
2778
{
2779
 
2780 2781 2782 2783 2784 2785 2786 2787 2788 2789 2790 2791 2792 2793 2794 2795 2796 2797 2798 2799 2800 2801 2802 2803 2804 2805 2806 2807 2808 2809 2810
}
      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
*/
X
Xiaoyu Wang 已提交
2811
void ParseFinalize(void *p){
2812 2813 2814
  yyParser *pParser = (yyParser*)p;
  while( pParser->yytos>pParser->yystack ) yy_pop_parser_stack(pParser);
#if YYSTACKDEPTH<=0
X
Xiaoyu Wang 已提交
2815
  if( pParser->yystack!=&pParser->yystk0 ) free(pParser->yystack);
2816 2817 2818
#endif
}

X
Xiaoyu Wang 已提交
2819
#ifndef Parse_ENGINEALWAYSONSTACK
2820 2821 2822 2823 2824 2825 2826 2827
/* 
** 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.
*/
X
Xiaoyu Wang 已提交
2828
void ParseFree(
2829 2830 2831 2832 2833 2834
  void *p,                    /* The parser to be deleted */
  void (*freeProc)(void*)     /* Function used to reclaim memory */
){
#ifndef YYPARSEFREENEVERNULL
  if( p==0 ) return;
#endif
X
Xiaoyu Wang 已提交
2835
  ParseFinalize(p);
2836 2837
  (*freeProc)(p);
}
X
Xiaoyu Wang 已提交
2838
#endif /* Parse_ENGINEALWAYSONSTACK */
2839 2840 2841 2842 2843

/*
** Return the peak depth of the stack for a parser.
*/
#ifdef YYTRACKMAXSTACKDEPTH
X
Xiaoyu Wang 已提交
2844
int ParseStackPeak(void *p){
2845 2846 2847 2848 2849 2850 2851 2852 2853 2854 2855 2856 2857 2858 2859 2860 2861 2862 2863 2864 2865 2866 2867
  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)
X
Xiaoyu Wang 已提交
2868
int ParseCoverage(FILE *out){
2869 2870 2871 2872 2873 2874 2875 2876 2877 2878 2879 2880 2881 2882 2883 2884 2885 2886 2887 2888 2889 2890 2891 2892 2893 2894 2895 2896 2897 2898 2899 2900 2901 2902 2903 2904
  int stateno, iLookAhead, i;
  int nMissed = 0;
  for(stateno=0; stateno<YYNSTATE; stateno++){
    i = yy_shift_ofst[stateno];
    for(iLookAhead=0; iLookAhead<YYNTOKEN; iLookAhead++){
      if( yy_lookahead[i+iLookAhead]!=iLookAhead ) continue;
      if( yycoverage[stateno][iLookAhead]==0 ) nMissed++;
      if( out ){
        fprintf(out,"State %d lookahead %s %s\n", stateno,
                yyTokenName[iLookAhead],
                yycoverage[stateno][iLookAhead] ? "ok" : "missed");
      }
    }
  }
  return nMissed;
}
#endif

/*
** Find the appropriate action for a parser given the terminal
** look-ahead token iLookAhead.
*/
static YYACTIONTYPE yy_find_shift_action(
  YYCODETYPE iLookAhead,    /* The look-ahead token */
  YYACTIONTYPE stateno      /* Current state number */
){
  int i;

  if( stateno>YY_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 );
X
Xiaoyu Wang 已提交
2905
    /* assert( i+YYNTOKEN<=(int)YY_NLOOKAHEAD ); */
2906 2907 2908
    assert( iLookAhead!=YYNOCODE );
    assert( iLookAhead < YYNTOKEN );
    i += iLookAhead;
X
Xiaoyu Wang 已提交
2909
    if( i>=YY_NLOOKAHEAD || yy_lookahead[i]!=iLookAhead ){
2910 2911
#ifdef YYFALLBACK
      YYCODETYPE iFallback;            /* Fallback token */
X
Xiaoyu Wang 已提交
2912 2913
      if( iLookAhead<sizeof(yyFallback)/sizeof(yyFallback[0])
             && (iFallback = yyFallback[iLookAhead])!=0 ){
2914 2915 2916 2917 2918 2919 2920 2921 2922 2923 2924 2925 2926 2927
#ifndef NDEBUG
        if( yyTraceFILE ){
          fprintf(yyTraceFILE, "%sFALLBACK %s => %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;
X
Xiaoyu Wang 已提交
2928 2929 2930 2931 2932 2933 2934 2935 2936 2937
        if( 
#if YY_SHIFT_MIN+YYWILDCARD<0
          j>=0 &&
#endif
#if YY_SHIFT_MAX+YYWILDCARD>=YY_ACTTAB_COUNT
          j<YY_ACTTAB_COUNT &&
#endif
          j<(int)(sizeof(yy_lookahead)/sizeof(yy_lookahead[0])) &&
          yy_lookahead[j]==YYWILDCARD && iLookAhead>0
        ){
2938 2939 2940 2941 2942 2943 2944 2945 2946 2947 2948 2949 2950 2951 2952 2953 2954 2955 2956 2957 2958 2959 2960 2961 2962 2963 2964 2965 2966 2967 2968 2969 2970 2971 2972 2973 2974 2975 2976 2977 2978 2979 2980 2981 2982 2983 2984 2985 2986 2987 2988 2989
#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{
      return yy_action[i];
    }
  }while(1);
}

/*
** Find the appropriate action for a parser given the non-terminal
** look-ahead token iLookAhead.
*/
static YYACTIONTYPE yy_find_reduce_action(
  YYACTIONTYPE stateno,     /* Current state number */
  YYCODETYPE iLookAhead     /* The look-ahead token */
){
  int i;
#ifdef YYERRORSYMBOL
  if( stateno>YY_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 && i<YY_ACTTAB_COUNT );
  assert( yy_lookahead[i]==iLookAhead );
#endif
  return yy_action[i];
}

/*
** The following routine is called if the stack overflows.
*/
static void yyStackOverflow(yyParser *yypParser){
X
Xiaoyu Wang 已提交
2990 2991
   ParseARG_FETCH
   ParseCTX_FETCH
2992 2993 2994 2995 2996 2997 2998 2999 3000 3001
#ifndef NDEBUG
   if( yyTraceFILE ){
     fprintf(yyTraceFILE,"%sStack Overflow!\n",yyTracePrompt);
   }
#endif
   while( yypParser->yytos>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 ********************************************/
X
Xiaoyu Wang 已提交
3002 3003
   ParseARG_STORE /* Suppress warning about unused %extra_argument var */
   ParseCTX_STORE
3004 3005 3006 3007 3008 3009 3010 3011 3012 3013 3014 3015 3016 3017 3018 3019 3020 3021 3022 3023 3024 3025 3026 3027 3028 3029 3030 3031 3032 3033
}

/*
** Print tracing information for a SHIFT action
*/
#ifndef NDEBUG
static void yyTraceShift(yyParser *yypParser, int yyNewState, const char *zTag){
  if( yyTraceFILE ){
    if( yyNewState<YYNSTATE ){
      fprintf(yyTraceFILE,"%s%s '%s', go to state %d\n",
         yyTracePrompt, zTag, yyTokenName[yypParser->yytos->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 */
X
Xiaoyu Wang 已提交
3034
  ParseTOKENTYPE yyMinor        /* The minor token to shift in */
3035 3036 3037 3038 3039 3040 3041 3042 3043 3044 3045 3046 3047 3048 3049 3050 3051 3052 3053 3054 3055 3056 3057 3058 3059 3060 3061 3062 3063 3064 3065 3066 3067 3068
){
  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");
}

X
Xiaoyu Wang 已提交
3069 3070 3071 3072 3073 3074 3075
/* The following table contains information about every rule that
** is used during the reduce.
*/
static const struct {
  YYCODETYPE lhs;       /* Symbol on the left-hand side of the rule */
  signed char nrhs;     /* Negative of the number of RHS symbols in the rule */
} yyRuleInfo[] = {
X
Xiaoyu Wang 已提交
3076 3077 3078 3079 3080 3081 3082 3083 3084 3085 3086 3087 3088 3089 3090 3091 3092 3093 3094 3095 3096 3097 3098 3099 3100 3101 3102 3103 3104 3105 3106 3107 3108 3109 3110 3111 3112 3113 3114 3115 3116 3117 3118 3119 3120 3121 3122 3123 3124 3125 3126 3127 3128 3129 3130 3131 3132 3133 3134 3135 3136 3137 3138 3139 3140 3141 3142 3143 3144 3145 3146 3147 3148 3149 3150 3151 3152 3153 3154 3155 3156 3157 3158 3159 3160 3161 3162 3163 3164 3165 3166 3167
  {  324,   -6 }, /* (0) cmd ::= CREATE ACCOUNT NK_ID PASS NK_STRING account_options */
  {  324,   -4 }, /* (1) cmd ::= ALTER ACCOUNT NK_ID alter_account_options */
  {  325,    0 }, /* (2) account_options ::= */
  {  325,   -3 }, /* (3) account_options ::= account_options PPS literal */
  {  325,   -3 }, /* (4) account_options ::= account_options TSERIES literal */
  {  325,   -3 }, /* (5) account_options ::= account_options STORAGE literal */
  {  325,   -3 }, /* (6) account_options ::= account_options STREAMS literal */
  {  325,   -3 }, /* (7) account_options ::= account_options QTIME literal */
  {  325,   -3 }, /* (8) account_options ::= account_options DBS literal */
  {  325,   -3 }, /* (9) account_options ::= account_options USERS literal */
  {  325,   -3 }, /* (10) account_options ::= account_options CONNS literal */
  {  325,   -3 }, /* (11) account_options ::= account_options STATE literal */
  {  326,   -1 }, /* (12) alter_account_options ::= alter_account_option */
  {  326,   -2 }, /* (13) alter_account_options ::= alter_account_options alter_account_option */
  {  328,   -2 }, /* (14) alter_account_option ::= PASS literal */
  {  328,   -2 }, /* (15) alter_account_option ::= PPS literal */
  {  328,   -2 }, /* (16) alter_account_option ::= TSERIES literal */
  {  328,   -2 }, /* (17) alter_account_option ::= STORAGE literal */
  {  328,   -2 }, /* (18) alter_account_option ::= STREAMS literal */
  {  328,   -2 }, /* (19) alter_account_option ::= QTIME literal */
  {  328,   -2 }, /* (20) alter_account_option ::= DBS literal */
  {  328,   -2 }, /* (21) alter_account_option ::= USERS literal */
  {  328,   -2 }, /* (22) alter_account_option ::= CONNS literal */
  {  328,   -2 }, /* (23) alter_account_option ::= STATE literal */
  {  324,   -6 }, /* (24) cmd ::= CREATE USER user_name PASS NK_STRING sysinfo_opt */
  {  324,   -5 }, /* (25) cmd ::= ALTER USER user_name PASS NK_STRING */
  {  324,   -5 }, /* (26) cmd ::= ALTER USER user_name ENABLE NK_INTEGER */
  {  324,   -5 }, /* (27) cmd ::= ALTER USER user_name SYSINFO NK_INTEGER */
  {  324,   -3 }, /* (28) cmd ::= DROP USER user_name */
  {  330,    0 }, /* (29) sysinfo_opt ::= */
  {  330,   -2 }, /* (30) sysinfo_opt ::= SYSINFO NK_INTEGER */
  {  324,   -6 }, /* (31) cmd ::= GRANT privileges ON priv_level TO user_name */
  {  324,   -6 }, /* (32) cmd ::= REVOKE privileges ON priv_level FROM user_name */
  {  331,   -1 }, /* (33) privileges ::= ALL */
  {  331,   -1 }, /* (34) privileges ::= priv_type_list */
  {  331,   -1 }, /* (35) privileges ::= SUBSCRIBE */
  {  333,   -1 }, /* (36) priv_type_list ::= priv_type */
  {  333,   -3 }, /* (37) priv_type_list ::= priv_type_list NK_COMMA priv_type */
  {  334,   -1 }, /* (38) priv_type ::= READ */
  {  334,   -1 }, /* (39) priv_type ::= WRITE */
  {  332,   -3 }, /* (40) priv_level ::= NK_STAR NK_DOT NK_STAR */
  {  332,   -3 }, /* (41) priv_level ::= db_name NK_DOT NK_STAR */
  {  332,   -1 }, /* (42) priv_level ::= topic_name */
  {  324,   -3 }, /* (43) cmd ::= CREATE DNODE dnode_endpoint */
  {  324,   -5 }, /* (44) cmd ::= CREATE DNODE dnode_endpoint PORT NK_INTEGER */
  {  324,   -4 }, /* (45) cmd ::= DROP DNODE NK_INTEGER force_opt */
  {  324,   -4 }, /* (46) cmd ::= DROP DNODE dnode_endpoint force_opt */
  {  324,   -4 }, /* (47) cmd ::= ALTER DNODE NK_INTEGER NK_STRING */
  {  324,   -5 }, /* (48) cmd ::= ALTER DNODE NK_INTEGER NK_STRING NK_STRING */
  {  324,   -4 }, /* (49) cmd ::= ALTER ALL DNODES NK_STRING */
  {  324,   -5 }, /* (50) cmd ::= ALTER ALL DNODES NK_STRING NK_STRING */
  {  337,   -1 }, /* (51) dnode_endpoint ::= NK_STRING */
  {  337,   -1 }, /* (52) dnode_endpoint ::= NK_ID */
  {  337,   -1 }, /* (53) dnode_endpoint ::= NK_IPTOKEN */
  {  338,    0 }, /* (54) force_opt ::= */
  {  338,   -1 }, /* (55) force_opt ::= FORCE */
  {  324,   -3 }, /* (56) cmd ::= ALTER LOCAL NK_STRING */
  {  324,   -4 }, /* (57) cmd ::= ALTER LOCAL NK_STRING NK_STRING */
  {  324,   -5 }, /* (58) cmd ::= CREATE QNODE ON DNODE NK_INTEGER */
  {  324,   -5 }, /* (59) cmd ::= DROP QNODE ON DNODE NK_INTEGER */
  {  324,   -5 }, /* (60) cmd ::= CREATE BNODE ON DNODE NK_INTEGER */
  {  324,   -5 }, /* (61) cmd ::= DROP BNODE ON DNODE NK_INTEGER */
  {  324,   -5 }, /* (62) cmd ::= CREATE SNODE ON DNODE NK_INTEGER */
  {  324,   -5 }, /* (63) cmd ::= DROP SNODE ON DNODE NK_INTEGER */
  {  324,   -5 }, /* (64) cmd ::= CREATE MNODE ON DNODE NK_INTEGER */
  {  324,   -5 }, /* (65) cmd ::= DROP MNODE ON DNODE NK_INTEGER */
  {  324,   -5 }, /* (66) cmd ::= CREATE DATABASE not_exists_opt db_name db_options */
  {  324,   -4 }, /* (67) cmd ::= DROP DATABASE exists_opt db_name */
  {  324,   -2 }, /* (68) cmd ::= USE db_name */
  {  324,   -4 }, /* (69) cmd ::= ALTER DATABASE db_name alter_db_options */
  {  324,   -3 }, /* (70) cmd ::= FLUSH DATABASE db_name */
  {  324,   -4 }, /* (71) cmd ::= TRIM DATABASE db_name speed_opt */
  {  339,   -3 }, /* (72) not_exists_opt ::= IF NOT EXISTS */
  {  339,    0 }, /* (73) not_exists_opt ::= */
  {  341,   -2 }, /* (74) exists_opt ::= IF EXISTS */
  {  341,    0 }, /* (75) exists_opt ::= */
  {  340,    0 }, /* (76) db_options ::= */
  {  340,   -3 }, /* (77) db_options ::= db_options BUFFER NK_INTEGER */
  {  340,   -3 }, /* (78) db_options ::= db_options CACHEMODEL NK_STRING */
  {  340,   -3 }, /* (79) db_options ::= db_options CACHESIZE NK_INTEGER */
  {  340,   -3 }, /* (80) db_options ::= db_options COMP NK_INTEGER */
  {  340,   -3 }, /* (81) db_options ::= db_options DURATION NK_INTEGER */
  {  340,   -3 }, /* (82) db_options ::= db_options DURATION NK_VARIABLE */
  {  340,   -3 }, /* (83) db_options ::= db_options MAXROWS NK_INTEGER */
  {  340,   -3 }, /* (84) db_options ::= db_options MINROWS NK_INTEGER */
  {  340,   -3 }, /* (85) db_options ::= db_options KEEP integer_list */
  {  340,   -3 }, /* (86) db_options ::= db_options KEEP variable_list */
  {  340,   -3 }, /* (87) db_options ::= db_options PAGES NK_INTEGER */
  {  340,   -3 }, /* (88) db_options ::= db_options PAGESIZE NK_INTEGER */
  {  340,   -3 }, /* (89) db_options ::= db_options TSDB_PAGESIZE NK_INTEGER */
  {  340,   -3 }, /* (90) db_options ::= db_options PRECISION NK_STRING */
  {  340,   -3 }, /* (91) db_options ::= db_options REPLICA NK_INTEGER */
X
Xiaoyu Wang 已提交
3168 3169 3170 3171 3172 3173 3174 3175 3176 3177 3178 3179 3180 3181 3182 3183 3184 3185 3186 3187 3188 3189 3190 3191 3192 3193 3194 3195 3196 3197 3198 3199 3200 3201 3202 3203 3204 3205 3206 3207 3208 3209 3210 3211 3212 3213 3214 3215 3216 3217 3218 3219 3220 3221 3222 3223 3224 3225 3226 3227 3228 3229 3230 3231 3232 3233 3234 3235 3236 3237 3238 3239 3240 3241 3242 3243 3244 3245 3246 3247 3248 3249 3250 3251 3252 3253 3254 3255 3256 3257 3258 3259 3260 3261 3262 3263 3264 3265 3266 3267 3268 3269 3270 3271 3272 3273 3274 3275 3276 3277 3278 3279 3280 3281 3282 3283 3284 3285 3286 3287 3288 3289 3290 3291 3292 3293 3294 3295 3296 3297 3298 3299 3300 3301 3302 3303 3304 3305 3306 3307 3308 3309 3310 3311 3312 3313 3314 3315 3316 3317 3318 3319 3320 3321 3322 3323 3324 3325 3326 3327 3328 3329 3330 3331 3332 3333 3334 3335 3336 3337 3338 3339 3340 3341
  {  340,   -3 }, /* (92) db_options ::= db_options VGROUPS NK_INTEGER */
  {  340,   -3 }, /* (93) db_options ::= db_options SINGLE_STABLE NK_INTEGER */
  {  340,   -3 }, /* (94) db_options ::= db_options RETENTIONS retention_list */
  {  340,   -3 }, /* (95) db_options ::= db_options SCHEMALESS NK_INTEGER */
  {  340,   -3 }, /* (96) db_options ::= db_options WAL_LEVEL NK_INTEGER */
  {  340,   -3 }, /* (97) db_options ::= db_options WAL_FSYNC_PERIOD NK_INTEGER */
  {  340,   -3 }, /* (98) db_options ::= db_options WAL_RETENTION_PERIOD NK_INTEGER */
  {  340,   -4 }, /* (99) db_options ::= db_options WAL_RETENTION_PERIOD NK_MINUS NK_INTEGER */
  {  340,   -3 }, /* (100) db_options ::= db_options WAL_RETENTION_SIZE NK_INTEGER */
  {  340,   -4 }, /* (101) db_options ::= db_options WAL_RETENTION_SIZE NK_MINUS NK_INTEGER */
  {  340,   -3 }, /* (102) db_options ::= db_options WAL_ROLL_PERIOD NK_INTEGER */
  {  340,   -3 }, /* (103) db_options ::= db_options WAL_SEGMENT_SIZE NK_INTEGER */
  {  340,   -3 }, /* (104) db_options ::= db_options STT_TRIGGER NK_INTEGER */
  {  340,   -3 }, /* (105) db_options ::= db_options TABLE_PREFIX NK_INTEGER */
  {  340,   -3 }, /* (106) db_options ::= db_options TABLE_SUFFIX NK_INTEGER */
  {  342,   -1 }, /* (107) alter_db_options ::= alter_db_option */
  {  342,   -2 }, /* (108) alter_db_options ::= alter_db_options alter_db_option */
  {  347,   -2 }, /* (109) alter_db_option ::= BUFFER NK_INTEGER */
  {  347,   -2 }, /* (110) alter_db_option ::= CACHEMODEL NK_STRING */
  {  347,   -2 }, /* (111) alter_db_option ::= CACHESIZE NK_INTEGER */
  {  347,   -2 }, /* (112) alter_db_option ::= WAL_FSYNC_PERIOD NK_INTEGER */
  {  347,   -2 }, /* (113) alter_db_option ::= KEEP integer_list */
  {  347,   -2 }, /* (114) alter_db_option ::= KEEP variable_list */
  {  347,   -2 }, /* (115) alter_db_option ::= PAGES NK_INTEGER */
  {  347,   -2 }, /* (116) alter_db_option ::= REPLICA NK_INTEGER */
  {  347,   -2 }, /* (117) alter_db_option ::= WAL_LEVEL NK_INTEGER */
  {  347,   -2 }, /* (118) alter_db_option ::= STT_TRIGGER NK_INTEGER */
  {  344,   -1 }, /* (119) integer_list ::= NK_INTEGER */
  {  344,   -3 }, /* (120) integer_list ::= integer_list NK_COMMA NK_INTEGER */
  {  345,   -1 }, /* (121) variable_list ::= NK_VARIABLE */
  {  345,   -3 }, /* (122) variable_list ::= variable_list NK_COMMA NK_VARIABLE */
  {  346,   -1 }, /* (123) retention_list ::= retention */
  {  346,   -3 }, /* (124) retention_list ::= retention_list NK_COMMA retention */
  {  348,   -3 }, /* (125) retention ::= NK_VARIABLE NK_COLON NK_VARIABLE */
  {  343,    0 }, /* (126) speed_opt ::= */
  {  343,   -2 }, /* (127) speed_opt ::= MAX_SPEED NK_INTEGER */
  {  324,   -9 }, /* (128) cmd ::= CREATE TABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def_opt table_options */
  {  324,   -3 }, /* (129) cmd ::= CREATE TABLE multi_create_clause */
  {  324,   -9 }, /* (130) cmd ::= CREATE STABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def table_options */
  {  324,   -3 }, /* (131) cmd ::= DROP TABLE multi_drop_clause */
  {  324,   -4 }, /* (132) cmd ::= DROP STABLE exists_opt full_table_name */
  {  324,   -3 }, /* (133) cmd ::= ALTER TABLE alter_table_clause */
  {  324,   -3 }, /* (134) cmd ::= ALTER STABLE alter_table_clause */
  {  356,   -2 }, /* (135) alter_table_clause ::= full_table_name alter_table_options */
  {  356,   -5 }, /* (136) alter_table_clause ::= full_table_name ADD COLUMN column_name type_name */
  {  356,   -4 }, /* (137) alter_table_clause ::= full_table_name DROP COLUMN column_name */
  {  356,   -5 }, /* (138) alter_table_clause ::= full_table_name MODIFY COLUMN column_name type_name */
  {  356,   -5 }, /* (139) alter_table_clause ::= full_table_name RENAME COLUMN column_name column_name */
  {  356,   -5 }, /* (140) alter_table_clause ::= full_table_name ADD TAG column_name type_name */
  {  356,   -4 }, /* (141) alter_table_clause ::= full_table_name DROP TAG column_name */
  {  356,   -5 }, /* (142) alter_table_clause ::= full_table_name MODIFY TAG column_name type_name */
  {  356,   -5 }, /* (143) alter_table_clause ::= full_table_name RENAME TAG column_name column_name */
  {  356,   -6 }, /* (144) alter_table_clause ::= full_table_name SET TAG column_name NK_EQ signed_literal */
  {  353,   -1 }, /* (145) multi_create_clause ::= create_subtable_clause */
  {  353,   -2 }, /* (146) multi_create_clause ::= multi_create_clause create_subtable_clause */
  {  361,  -10 }, /* (147) create_subtable_clause ::= not_exists_opt full_table_name USING full_table_name specific_cols_opt TAGS NK_LP expression_list NK_RP table_options */
  {  355,   -1 }, /* (148) multi_drop_clause ::= drop_table_clause */
  {  355,   -2 }, /* (149) multi_drop_clause ::= multi_drop_clause drop_table_clause */
  {  364,   -2 }, /* (150) drop_table_clause ::= exists_opt full_table_name */
  {  362,    0 }, /* (151) specific_cols_opt ::= */
  {  362,   -3 }, /* (152) specific_cols_opt ::= NK_LP col_name_list NK_RP */
  {  349,   -1 }, /* (153) full_table_name ::= table_name */
  {  349,   -3 }, /* (154) full_table_name ::= db_name NK_DOT table_name */
  {  350,   -1 }, /* (155) column_def_list ::= column_def */
  {  350,   -3 }, /* (156) column_def_list ::= column_def_list NK_COMMA column_def */
  {  367,   -2 }, /* (157) column_def ::= column_name type_name */
  {  367,   -4 }, /* (158) column_def ::= column_name type_name COMMENT NK_STRING */
  {  359,   -1 }, /* (159) type_name ::= BOOL */
  {  359,   -1 }, /* (160) type_name ::= TINYINT */
  {  359,   -1 }, /* (161) type_name ::= SMALLINT */
  {  359,   -1 }, /* (162) type_name ::= INT */
  {  359,   -1 }, /* (163) type_name ::= INTEGER */
  {  359,   -1 }, /* (164) type_name ::= BIGINT */
  {  359,   -1 }, /* (165) type_name ::= FLOAT */
  {  359,   -1 }, /* (166) type_name ::= DOUBLE */
  {  359,   -4 }, /* (167) type_name ::= BINARY NK_LP NK_INTEGER NK_RP */
  {  359,   -1 }, /* (168) type_name ::= TIMESTAMP */
  {  359,   -4 }, /* (169) type_name ::= NCHAR NK_LP NK_INTEGER NK_RP */
  {  359,   -2 }, /* (170) type_name ::= TINYINT UNSIGNED */
  {  359,   -2 }, /* (171) type_name ::= SMALLINT UNSIGNED */
  {  359,   -2 }, /* (172) type_name ::= INT UNSIGNED */
  {  359,   -2 }, /* (173) type_name ::= BIGINT UNSIGNED */
  {  359,   -1 }, /* (174) type_name ::= JSON */
  {  359,   -4 }, /* (175) type_name ::= VARCHAR NK_LP NK_INTEGER NK_RP */
  {  359,   -1 }, /* (176) type_name ::= MEDIUMBLOB */
  {  359,   -1 }, /* (177) type_name ::= BLOB */
  {  359,   -4 }, /* (178) type_name ::= VARBINARY NK_LP NK_INTEGER NK_RP */
  {  359,   -1 }, /* (179) type_name ::= DECIMAL */
  {  359,   -4 }, /* (180) type_name ::= DECIMAL NK_LP NK_INTEGER NK_RP */
  {  359,   -6 }, /* (181) type_name ::= DECIMAL NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP */
  {  351,    0 }, /* (182) tags_def_opt ::= */
  {  351,   -1 }, /* (183) tags_def_opt ::= tags_def */
  {  354,   -4 }, /* (184) tags_def ::= TAGS NK_LP column_def_list NK_RP */
  {  352,    0 }, /* (185) table_options ::= */
  {  352,   -3 }, /* (186) table_options ::= table_options COMMENT NK_STRING */
  {  352,   -3 }, /* (187) table_options ::= table_options MAX_DELAY duration_list */
  {  352,   -3 }, /* (188) table_options ::= table_options WATERMARK duration_list */
  {  352,   -5 }, /* (189) table_options ::= table_options ROLLUP NK_LP rollup_func_list NK_RP */
  {  352,   -3 }, /* (190) table_options ::= table_options TTL NK_INTEGER */
  {  352,   -5 }, /* (191) table_options ::= table_options SMA NK_LP col_name_list NK_RP */
  {  352,   -3 }, /* (192) table_options ::= table_options DELETE_MARK duration_list */
  {  357,   -1 }, /* (193) alter_table_options ::= alter_table_option */
  {  357,   -2 }, /* (194) alter_table_options ::= alter_table_options alter_table_option */
  {  370,   -2 }, /* (195) alter_table_option ::= COMMENT NK_STRING */
  {  370,   -2 }, /* (196) alter_table_option ::= TTL NK_INTEGER */
  {  368,   -1 }, /* (197) duration_list ::= duration_literal */
  {  368,   -3 }, /* (198) duration_list ::= duration_list NK_COMMA duration_literal */
  {  369,   -1 }, /* (199) rollup_func_list ::= rollup_func_name */
  {  369,   -3 }, /* (200) rollup_func_list ::= rollup_func_list NK_COMMA rollup_func_name */
  {  372,   -1 }, /* (201) rollup_func_name ::= function_name */
  {  372,   -1 }, /* (202) rollup_func_name ::= FIRST */
  {  372,   -1 }, /* (203) rollup_func_name ::= LAST */
  {  365,   -1 }, /* (204) col_name_list ::= col_name */
  {  365,   -3 }, /* (205) col_name_list ::= col_name_list NK_COMMA col_name */
  {  374,   -1 }, /* (206) col_name ::= column_name */
  {  324,   -2 }, /* (207) cmd ::= SHOW DNODES */
  {  324,   -2 }, /* (208) cmd ::= SHOW USERS */
  {  324,   -3 }, /* (209) cmd ::= SHOW USER PRIVILEGES */
  {  324,   -2 }, /* (210) cmd ::= SHOW DATABASES */
  {  324,   -4 }, /* (211) cmd ::= SHOW db_name_cond_opt TABLES like_pattern_opt */
  {  324,   -4 }, /* (212) cmd ::= SHOW db_name_cond_opt STABLES like_pattern_opt */
  {  324,   -3 }, /* (213) cmd ::= SHOW db_name_cond_opt VGROUPS */
  {  324,   -2 }, /* (214) cmd ::= SHOW MNODES */
  {  324,   -2 }, /* (215) cmd ::= SHOW QNODES */
  {  324,   -2 }, /* (216) cmd ::= SHOW FUNCTIONS */
  {  324,   -5 }, /* (217) cmd ::= SHOW INDEXES FROM table_name_cond from_db_opt */
  {  324,   -2 }, /* (218) cmd ::= SHOW STREAMS */
  {  324,   -2 }, /* (219) cmd ::= SHOW ACCOUNTS */
  {  324,   -2 }, /* (220) cmd ::= SHOW APPS */
  {  324,   -2 }, /* (221) cmd ::= SHOW CONNECTIONS */
  {  324,   -2 }, /* (222) cmd ::= SHOW LICENCES */
  {  324,   -2 }, /* (223) cmd ::= SHOW GRANTS */
  {  324,   -4 }, /* (224) cmd ::= SHOW CREATE DATABASE db_name */
  {  324,   -4 }, /* (225) cmd ::= SHOW CREATE TABLE full_table_name */
  {  324,   -4 }, /* (226) cmd ::= SHOW CREATE STABLE full_table_name */
  {  324,   -2 }, /* (227) cmd ::= SHOW QUERIES */
  {  324,   -2 }, /* (228) cmd ::= SHOW SCORES */
  {  324,   -2 }, /* (229) cmd ::= SHOW TOPICS */
  {  324,   -2 }, /* (230) cmd ::= SHOW VARIABLES */
  {  324,   -3 }, /* (231) cmd ::= SHOW CLUSTER VARIABLES */
  {  324,   -3 }, /* (232) cmd ::= SHOW LOCAL VARIABLES */
  {  324,   -5 }, /* (233) cmd ::= SHOW DNODE NK_INTEGER VARIABLES like_pattern_opt */
  {  324,   -2 }, /* (234) cmd ::= SHOW BNODES */
  {  324,   -2 }, /* (235) cmd ::= SHOW SNODES */
  {  324,   -2 }, /* (236) cmd ::= SHOW CLUSTER */
  {  324,   -2 }, /* (237) cmd ::= SHOW TRANSACTIONS */
  {  324,   -4 }, /* (238) cmd ::= SHOW TABLE DISTRIBUTED full_table_name */
  {  324,   -2 }, /* (239) cmd ::= SHOW CONSUMERS */
  {  324,   -2 }, /* (240) cmd ::= SHOW SUBSCRIPTIONS */
  {  324,   -5 }, /* (241) cmd ::= SHOW TAGS FROM table_name_cond from_db_opt */
  {  324,   -7 }, /* (242) cmd ::= SHOW TABLE TAGS tag_list_opt FROM table_name_cond from_db_opt */
  {  324,   -3 }, /* (243) cmd ::= SHOW VNODES NK_INTEGER */
  {  324,   -3 }, /* (244) cmd ::= SHOW VNODES NK_STRING */
  {  375,    0 }, /* (245) db_name_cond_opt ::= */
  {  375,   -2 }, /* (246) db_name_cond_opt ::= db_name NK_DOT */
  {  376,    0 }, /* (247) like_pattern_opt ::= */
  {  376,   -2 }, /* (248) like_pattern_opt ::= LIKE NK_STRING */
  {  377,   -1 }, /* (249) table_name_cond ::= table_name */
  {  378,    0 }, /* (250) from_db_opt ::= */
  {  378,   -2 }, /* (251) from_db_opt ::= FROM db_name */
  {  379,    0 }, /* (252) tag_list_opt ::= */
  {  379,   -1 }, /* (253) tag_list_opt ::= tag_item */
  {  379,   -3 }, /* (254) tag_list_opt ::= tag_list_opt NK_COMMA tag_item */
  {  380,   -1 }, /* (255) tag_item ::= TBNAME */
  {  380,   -1 }, /* (256) tag_item ::= QTAGS */
  {  380,   -1 }, /* (257) tag_item ::= column_name */
  {  380,   -2 }, /* (258) tag_item ::= column_name column_alias */
  {  380,   -3 }, /* (259) tag_item ::= column_name AS column_alias */
  {  324,   -8 }, /* (260) cmd ::= CREATE SMA INDEX not_exists_opt full_table_name ON full_table_name index_options */
  {  324,   -4 }, /* (261) cmd ::= DROP INDEX exists_opt full_table_name */
  {  382,  -10 }, /* (262) index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_RP sliding_opt sma_stream_opt */
  {  382,  -12 }, /* (263) index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt sma_stream_opt */
  {  383,   -1 }, /* (264) func_list ::= func */
  {  383,   -3 }, /* (265) func_list ::= func_list NK_COMMA func */
3342 3343 3344 3345 3346 3347 3348 3349 3350 3351 3352 3353 3354 3355 3356 3357 3358 3359 3360 3361 3362 3363 3364 3365 3366 3367 3368 3369 3370 3371 3372 3373 3374 3375 3376 3377 3378 3379 3380 3381 3382 3383 3384 3385 3386 3387 3388 3389 3390 3391 3392 3393 3394 3395 3396 3397 3398 3399 3400 3401 3402 3403 3404 3405 3406 3407 3408 3409 3410 3411 3412 3413 3414 3415 3416 3417 3418 3419 3420 3421 3422 3423 3424 3425 3426 3427 3428 3429 3430 3431 3432 3433 3434 3435 3436 3437 3438 3439 3440 3441 3442 3443 3444 3445 3446 3447 3448 3449 3450 3451 3452 3453 3454 3455 3456 3457 3458 3459 3460 3461 3462 3463 3464 3465 3466 3467 3468 3469 3470 3471 3472 3473 3474 3475 3476 3477 3478 3479 3480 3481 3482 3483 3484 3485 3486 3487 3488 3489 3490 3491 3492 3493 3494 3495 3496 3497 3498 3499 3500 3501 3502 3503 3504 3505 3506 3507 3508 3509 3510 3511 3512 3513 3514 3515 3516 3517 3518 3519 3520 3521 3522 3523 3524 3525 3526 3527 3528 3529 3530 3531 3532 3533 3534 3535 3536 3537 3538 3539 3540 3541 3542 3543 3544 3545 3546 3547 3548 3549 3550 3551 3552 3553 3554 3555 3556 3557 3558 3559 3560 3561 3562 3563 3564 3565 3566 3567 3568 3569 3570 3571 3572 3573 3574 3575 3576 3577 3578 3579 3580 3581 3582 3583 3584 3585 3586 3587 3588 3589 3590 3591 3592 3593 3594 3595 3596 3597 3598 3599 3600 3601 3602 3603 3604 3605 3606 3607 3608 3609 3610 3611 3612 3613 3614 3615 3616 3617 3618 3619
  {  386,   -4 }, /* (266) func ::= sma_func_name NK_LP expression_list NK_RP */
  {  387,   -1 }, /* (267) sma_func_name ::= function_name */
  {  387,   -1 }, /* (268) sma_func_name ::= COUNT */
  {  387,   -1 }, /* (269) sma_func_name ::= FIRST */
  {  387,   -1 }, /* (270) sma_func_name ::= LAST */
  {  387,   -1 }, /* (271) sma_func_name ::= LAST_ROW */
  {  385,    0 }, /* (272) sma_stream_opt ::= */
  {  385,   -3 }, /* (273) sma_stream_opt ::= sma_stream_opt WATERMARK duration_literal */
  {  385,   -3 }, /* (274) sma_stream_opt ::= sma_stream_opt MAX_DELAY duration_literal */
  {  385,   -3 }, /* (275) sma_stream_opt ::= sma_stream_opt DELETE_MARK duration_literal */
  {  324,   -6 }, /* (276) cmd ::= CREATE TOPIC not_exists_opt topic_name AS query_or_subquery */
  {  324,   -7 }, /* (277) cmd ::= CREATE TOPIC not_exists_opt topic_name AS DATABASE db_name */
  {  324,   -9 }, /* (278) cmd ::= CREATE TOPIC not_exists_opt topic_name WITH META AS DATABASE db_name */
  {  324,   -7 }, /* (279) cmd ::= CREATE TOPIC not_exists_opt topic_name AS STABLE full_table_name */
  {  324,   -9 }, /* (280) cmd ::= CREATE TOPIC not_exists_opt topic_name WITH META AS STABLE full_table_name */
  {  324,   -4 }, /* (281) cmd ::= DROP TOPIC exists_opt topic_name */
  {  324,   -7 }, /* (282) cmd ::= DROP CONSUMER GROUP exists_opt cgroup_name ON topic_name */
  {  324,   -2 }, /* (283) cmd ::= DESC full_table_name */
  {  324,   -2 }, /* (284) cmd ::= DESCRIBE full_table_name */
  {  324,   -3 }, /* (285) cmd ::= RESET QUERY CACHE */
  {  324,   -4 }, /* (286) cmd ::= EXPLAIN analyze_opt explain_options query_or_subquery */
  {  390,    0 }, /* (287) analyze_opt ::= */
  {  390,   -1 }, /* (288) analyze_opt ::= ANALYZE */
  {  391,    0 }, /* (289) explain_options ::= */
  {  391,   -3 }, /* (290) explain_options ::= explain_options VERBOSE NK_BOOL */
  {  391,   -3 }, /* (291) explain_options ::= explain_options RATIO NK_FLOAT */
  {  324,  -10 }, /* (292) cmd ::= CREATE agg_func_opt FUNCTION not_exists_opt function_name AS NK_STRING OUTPUTTYPE type_name bufsize_opt */
  {  324,   -4 }, /* (293) cmd ::= DROP FUNCTION exists_opt function_name */
  {  392,    0 }, /* (294) agg_func_opt ::= */
  {  392,   -1 }, /* (295) agg_func_opt ::= AGGREGATE */
  {  393,    0 }, /* (296) bufsize_opt ::= */
  {  393,   -2 }, /* (297) bufsize_opt ::= BUFSIZE NK_INTEGER */
  {  324,  -11 }, /* (298) cmd ::= CREATE STREAM not_exists_opt stream_name stream_options INTO full_table_name tags_def_opt subtable_opt AS query_or_subquery */
  {  324,   -4 }, /* (299) cmd ::= DROP STREAM exists_opt stream_name */
  {  395,    0 }, /* (300) stream_options ::= */
  {  395,   -3 }, /* (301) stream_options ::= stream_options TRIGGER AT_ONCE */
  {  395,   -3 }, /* (302) stream_options ::= stream_options TRIGGER WINDOW_CLOSE */
  {  395,   -4 }, /* (303) stream_options ::= stream_options TRIGGER MAX_DELAY duration_literal */
  {  395,   -3 }, /* (304) stream_options ::= stream_options WATERMARK duration_literal */
  {  395,   -4 }, /* (305) stream_options ::= stream_options IGNORE EXPIRED NK_INTEGER */
  {  395,   -3 }, /* (306) stream_options ::= stream_options FILL_HISTORY NK_INTEGER */
  {  396,    0 }, /* (307) subtable_opt ::= */
  {  396,   -4 }, /* (308) subtable_opt ::= SUBTABLE NK_LP expression NK_RP */
  {  324,   -3 }, /* (309) cmd ::= KILL CONNECTION NK_INTEGER */
  {  324,   -3 }, /* (310) cmd ::= KILL QUERY NK_STRING */
  {  324,   -3 }, /* (311) cmd ::= KILL TRANSACTION NK_INTEGER */
  {  324,   -2 }, /* (312) cmd ::= BALANCE VGROUP */
  {  324,   -4 }, /* (313) cmd ::= MERGE VGROUP NK_INTEGER NK_INTEGER */
  {  324,   -4 }, /* (314) cmd ::= REDISTRIBUTE VGROUP NK_INTEGER dnode_list */
  {  324,   -3 }, /* (315) cmd ::= SPLIT VGROUP NK_INTEGER */
  {  398,   -2 }, /* (316) dnode_list ::= DNODE NK_INTEGER */
  {  398,   -3 }, /* (317) dnode_list ::= dnode_list DNODE NK_INTEGER */
  {  324,   -4 }, /* (318) cmd ::= DELETE FROM full_table_name where_clause_opt */
  {  324,   -1 }, /* (319) cmd ::= query_or_subquery */
  {  324,   -7 }, /* (320) cmd ::= INSERT INTO full_table_name NK_LP col_name_list NK_RP query_or_subquery */
  {  324,   -4 }, /* (321) cmd ::= INSERT INTO full_table_name query_or_subquery */
  {  327,   -1 }, /* (322) literal ::= NK_INTEGER */
  {  327,   -1 }, /* (323) literal ::= NK_FLOAT */
  {  327,   -1 }, /* (324) literal ::= NK_STRING */
  {  327,   -1 }, /* (325) literal ::= NK_BOOL */
  {  327,   -2 }, /* (326) literal ::= TIMESTAMP NK_STRING */
  {  327,   -1 }, /* (327) literal ::= duration_literal */
  {  327,   -1 }, /* (328) literal ::= NULL */
  {  327,   -1 }, /* (329) literal ::= NK_QUESTION */
  {  371,   -1 }, /* (330) duration_literal ::= NK_VARIABLE */
  {  400,   -1 }, /* (331) signed ::= NK_INTEGER */
  {  400,   -2 }, /* (332) signed ::= NK_PLUS NK_INTEGER */
  {  400,   -2 }, /* (333) signed ::= NK_MINUS NK_INTEGER */
  {  400,   -1 }, /* (334) signed ::= NK_FLOAT */
  {  400,   -2 }, /* (335) signed ::= NK_PLUS NK_FLOAT */
  {  400,   -2 }, /* (336) signed ::= NK_MINUS NK_FLOAT */
  {  360,   -1 }, /* (337) signed_literal ::= signed */
  {  360,   -1 }, /* (338) signed_literal ::= NK_STRING */
  {  360,   -1 }, /* (339) signed_literal ::= NK_BOOL */
  {  360,   -2 }, /* (340) signed_literal ::= TIMESTAMP NK_STRING */
  {  360,   -1 }, /* (341) signed_literal ::= duration_literal */
  {  360,   -1 }, /* (342) signed_literal ::= NULL */
  {  360,   -1 }, /* (343) signed_literal ::= literal_func */
  {  360,   -1 }, /* (344) signed_literal ::= NK_QUESTION */
  {  402,   -1 }, /* (345) literal_list ::= signed_literal */
  {  402,   -3 }, /* (346) literal_list ::= literal_list NK_COMMA signed_literal */
  {  335,   -1 }, /* (347) db_name ::= NK_ID */
  {  366,   -1 }, /* (348) table_name ::= NK_ID */
  {  358,   -1 }, /* (349) column_name ::= NK_ID */
  {  373,   -1 }, /* (350) function_name ::= NK_ID */
  {  403,   -1 }, /* (351) table_alias ::= NK_ID */
  {  381,   -1 }, /* (352) column_alias ::= NK_ID */
  {  329,   -1 }, /* (353) user_name ::= NK_ID */
  {  336,   -1 }, /* (354) topic_name ::= NK_ID */
  {  394,   -1 }, /* (355) stream_name ::= NK_ID */
  {  389,   -1 }, /* (356) cgroup_name ::= NK_ID */
  {  404,   -1 }, /* (357) expr_or_subquery ::= expression */
  {  397,   -1 }, /* (358) expression ::= literal */
  {  397,   -1 }, /* (359) expression ::= pseudo_column */
  {  397,   -1 }, /* (360) expression ::= column_reference */
  {  397,   -1 }, /* (361) expression ::= function_expression */
  {  397,   -1 }, /* (362) expression ::= case_when_expression */
  {  397,   -3 }, /* (363) expression ::= NK_LP expression NK_RP */
  {  397,   -2 }, /* (364) expression ::= NK_PLUS expr_or_subquery */
  {  397,   -2 }, /* (365) expression ::= NK_MINUS expr_or_subquery */
  {  397,   -3 }, /* (366) expression ::= expr_or_subquery NK_PLUS expr_or_subquery */
  {  397,   -3 }, /* (367) expression ::= expr_or_subquery NK_MINUS expr_or_subquery */
  {  397,   -3 }, /* (368) expression ::= expr_or_subquery NK_STAR expr_or_subquery */
  {  397,   -3 }, /* (369) expression ::= expr_or_subquery NK_SLASH expr_or_subquery */
  {  397,   -3 }, /* (370) expression ::= expr_or_subquery NK_REM expr_or_subquery */
  {  397,   -3 }, /* (371) expression ::= column_reference NK_ARROW NK_STRING */
  {  397,   -3 }, /* (372) expression ::= expr_or_subquery NK_BITAND expr_or_subquery */
  {  397,   -3 }, /* (373) expression ::= expr_or_subquery NK_BITOR expr_or_subquery */
  {  363,   -1 }, /* (374) expression_list ::= expr_or_subquery */
  {  363,   -3 }, /* (375) expression_list ::= expression_list NK_COMMA expr_or_subquery */
  {  406,   -1 }, /* (376) column_reference ::= column_name */
  {  406,   -3 }, /* (377) column_reference ::= table_name NK_DOT column_name */
  {  405,   -1 }, /* (378) pseudo_column ::= ROWTS */
  {  405,   -1 }, /* (379) pseudo_column ::= TBNAME */
  {  405,   -3 }, /* (380) pseudo_column ::= table_name NK_DOT TBNAME */
  {  405,   -1 }, /* (381) pseudo_column ::= QSTART */
  {  405,   -1 }, /* (382) pseudo_column ::= QEND */
  {  405,   -1 }, /* (383) pseudo_column ::= QDURATION */
  {  405,   -1 }, /* (384) pseudo_column ::= WSTART */
  {  405,   -1 }, /* (385) pseudo_column ::= WEND */
  {  405,   -1 }, /* (386) pseudo_column ::= WDURATION */
  {  405,   -1 }, /* (387) pseudo_column ::= IROWTS */
  {  405,   -1 }, /* (388) pseudo_column ::= QTAGS */
  {  407,   -4 }, /* (389) function_expression ::= function_name NK_LP expression_list NK_RP */
  {  407,   -4 }, /* (390) function_expression ::= star_func NK_LP star_func_para_list NK_RP */
  {  407,   -6 }, /* (391) function_expression ::= CAST NK_LP expr_or_subquery AS type_name NK_RP */
  {  407,   -1 }, /* (392) function_expression ::= literal_func */
  {  401,   -3 }, /* (393) literal_func ::= noarg_func NK_LP NK_RP */
  {  401,   -1 }, /* (394) literal_func ::= NOW */
  {  411,   -1 }, /* (395) noarg_func ::= NOW */
  {  411,   -1 }, /* (396) noarg_func ::= TODAY */
  {  411,   -1 }, /* (397) noarg_func ::= TIMEZONE */
  {  411,   -1 }, /* (398) noarg_func ::= DATABASE */
  {  411,   -1 }, /* (399) noarg_func ::= CLIENT_VERSION */
  {  411,   -1 }, /* (400) noarg_func ::= SERVER_VERSION */
  {  411,   -1 }, /* (401) noarg_func ::= SERVER_STATUS */
  {  411,   -1 }, /* (402) noarg_func ::= CURRENT_USER */
  {  411,   -1 }, /* (403) noarg_func ::= USER */
  {  409,   -1 }, /* (404) star_func ::= COUNT */
  {  409,   -1 }, /* (405) star_func ::= FIRST */
  {  409,   -1 }, /* (406) star_func ::= LAST */
  {  409,   -1 }, /* (407) star_func ::= LAST_ROW */
  {  410,   -1 }, /* (408) star_func_para_list ::= NK_STAR */
  {  410,   -1 }, /* (409) star_func_para_list ::= other_para_list */
  {  412,   -1 }, /* (410) other_para_list ::= star_func_para */
  {  412,   -3 }, /* (411) other_para_list ::= other_para_list NK_COMMA star_func_para */
  {  413,   -1 }, /* (412) star_func_para ::= expr_or_subquery */
  {  413,   -3 }, /* (413) star_func_para ::= table_name NK_DOT NK_STAR */
  {  408,   -4 }, /* (414) case_when_expression ::= CASE when_then_list case_when_else_opt END */
  {  408,   -5 }, /* (415) case_when_expression ::= CASE common_expression when_then_list case_when_else_opt END */
  {  414,   -1 }, /* (416) when_then_list ::= when_then_expr */
  {  414,   -2 }, /* (417) when_then_list ::= when_then_list when_then_expr */
  {  417,   -4 }, /* (418) when_then_expr ::= WHEN common_expression THEN common_expression */
  {  415,    0 }, /* (419) case_when_else_opt ::= */
  {  415,   -2 }, /* (420) case_when_else_opt ::= ELSE common_expression */
  {  418,   -3 }, /* (421) predicate ::= expr_or_subquery compare_op expr_or_subquery */
  {  418,   -5 }, /* (422) predicate ::= expr_or_subquery BETWEEN expr_or_subquery AND expr_or_subquery */
  {  418,   -6 }, /* (423) predicate ::= expr_or_subquery NOT BETWEEN expr_or_subquery AND expr_or_subquery */
  {  418,   -3 }, /* (424) predicate ::= expr_or_subquery IS NULL */
  {  418,   -4 }, /* (425) predicate ::= expr_or_subquery IS NOT NULL */
  {  418,   -3 }, /* (426) predicate ::= expr_or_subquery in_op in_predicate_value */
  {  419,   -1 }, /* (427) compare_op ::= NK_LT */
  {  419,   -1 }, /* (428) compare_op ::= NK_GT */
  {  419,   -1 }, /* (429) compare_op ::= NK_LE */
  {  419,   -1 }, /* (430) compare_op ::= NK_GE */
  {  419,   -1 }, /* (431) compare_op ::= NK_NE */
  {  419,   -1 }, /* (432) compare_op ::= NK_EQ */
  {  419,   -1 }, /* (433) compare_op ::= LIKE */
  {  419,   -2 }, /* (434) compare_op ::= NOT LIKE */
  {  419,   -1 }, /* (435) compare_op ::= MATCH */
  {  419,   -1 }, /* (436) compare_op ::= NMATCH */
  {  419,   -1 }, /* (437) compare_op ::= CONTAINS */
  {  420,   -1 }, /* (438) in_op ::= IN */
  {  420,   -2 }, /* (439) in_op ::= NOT IN */
  {  421,   -3 }, /* (440) in_predicate_value ::= NK_LP literal_list NK_RP */
  {  422,   -1 }, /* (441) boolean_value_expression ::= boolean_primary */
  {  422,   -2 }, /* (442) boolean_value_expression ::= NOT boolean_primary */
  {  422,   -3 }, /* (443) boolean_value_expression ::= boolean_value_expression OR boolean_value_expression */
  {  422,   -3 }, /* (444) boolean_value_expression ::= boolean_value_expression AND boolean_value_expression */
  {  423,   -1 }, /* (445) boolean_primary ::= predicate */
  {  423,   -3 }, /* (446) boolean_primary ::= NK_LP boolean_value_expression NK_RP */
  {  416,   -1 }, /* (447) common_expression ::= expr_or_subquery */
  {  416,   -1 }, /* (448) common_expression ::= boolean_value_expression */
  {  424,    0 }, /* (449) from_clause_opt ::= */
  {  424,   -2 }, /* (450) from_clause_opt ::= FROM table_reference_list */
  {  425,   -1 }, /* (451) table_reference_list ::= table_reference */
  {  425,   -3 }, /* (452) table_reference_list ::= table_reference_list NK_COMMA table_reference */
  {  426,   -1 }, /* (453) table_reference ::= table_primary */
  {  426,   -1 }, /* (454) table_reference ::= joined_table */
  {  427,   -2 }, /* (455) table_primary ::= table_name alias_opt */
  {  427,   -4 }, /* (456) table_primary ::= db_name NK_DOT table_name alias_opt */
  {  427,   -2 }, /* (457) table_primary ::= subquery alias_opt */
  {  427,   -1 }, /* (458) table_primary ::= parenthesized_joined_table */
  {  429,    0 }, /* (459) alias_opt ::= */
  {  429,   -1 }, /* (460) alias_opt ::= table_alias */
  {  429,   -2 }, /* (461) alias_opt ::= AS table_alias */
  {  431,   -3 }, /* (462) parenthesized_joined_table ::= NK_LP joined_table NK_RP */
  {  431,   -3 }, /* (463) parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP */
  {  428,   -6 }, /* (464) joined_table ::= table_reference join_type JOIN table_reference ON search_condition */
  {  432,    0 }, /* (465) join_type ::= */
  {  432,   -1 }, /* (466) join_type ::= INNER */
  {  434,  -12 }, /* (467) query_specification ::= SELECT set_quantifier_opt select_list from_clause_opt where_clause_opt partition_by_clause_opt range_opt every_opt fill_opt twindow_clause_opt group_by_clause_opt having_clause_opt */
  {  435,    0 }, /* (468) set_quantifier_opt ::= */
  {  435,   -1 }, /* (469) set_quantifier_opt ::= DISTINCT */
  {  435,   -1 }, /* (470) set_quantifier_opt ::= ALL */
  {  436,   -1 }, /* (471) select_list ::= select_item */
  {  436,   -3 }, /* (472) select_list ::= select_list NK_COMMA select_item */
  {  444,   -1 }, /* (473) select_item ::= NK_STAR */
  {  444,   -1 }, /* (474) select_item ::= common_expression */
  {  444,   -2 }, /* (475) select_item ::= common_expression column_alias */
  {  444,   -3 }, /* (476) select_item ::= common_expression AS column_alias */
  {  444,   -3 }, /* (477) select_item ::= table_name NK_DOT NK_STAR */
  {  399,    0 }, /* (478) where_clause_opt ::= */
  {  399,   -2 }, /* (479) where_clause_opt ::= WHERE search_condition */
  {  437,    0 }, /* (480) partition_by_clause_opt ::= */
  {  437,   -3 }, /* (481) partition_by_clause_opt ::= PARTITION BY partition_list */
  {  445,   -1 }, /* (482) partition_list ::= partition_item */
  {  445,   -3 }, /* (483) partition_list ::= partition_list NK_COMMA partition_item */
  {  446,   -1 }, /* (484) partition_item ::= expr_or_subquery */
  {  446,   -2 }, /* (485) partition_item ::= expr_or_subquery column_alias */
  {  446,   -3 }, /* (486) partition_item ::= expr_or_subquery AS column_alias */
  {  441,    0 }, /* (487) twindow_clause_opt ::= */
  {  441,   -6 }, /* (488) twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA duration_literal NK_RP */
  {  441,   -4 }, /* (489) twindow_clause_opt ::= STATE_WINDOW NK_LP expr_or_subquery NK_RP */
  {  441,   -6 }, /* (490) twindow_clause_opt ::= INTERVAL NK_LP duration_literal NK_RP sliding_opt fill_opt */
  {  441,   -8 }, /* (491) twindow_clause_opt ::= INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt fill_opt */
  {  441,   -7 }, /* (492) twindow_clause_opt ::= EVENT_WINDOW START WITH search_condition END WITH search_condition */
  {  384,    0 }, /* (493) sliding_opt ::= */
  {  384,   -4 }, /* (494) sliding_opt ::= SLIDING NK_LP duration_literal NK_RP */
  {  440,    0 }, /* (495) fill_opt ::= */
  {  440,   -4 }, /* (496) fill_opt ::= FILL NK_LP fill_mode NK_RP */
  {  440,   -6 }, /* (497) fill_opt ::= FILL NK_LP VALUE NK_COMMA literal_list NK_RP */
  {  447,   -1 }, /* (498) fill_mode ::= NONE */
  {  447,   -1 }, /* (499) fill_mode ::= PREV */
  {  447,   -1 }, /* (500) fill_mode ::= NULL */
  {  447,   -1 }, /* (501) fill_mode ::= LINEAR */
  {  447,   -1 }, /* (502) fill_mode ::= NEXT */
  {  442,    0 }, /* (503) group_by_clause_opt ::= */
  {  442,   -3 }, /* (504) group_by_clause_opt ::= GROUP BY group_by_list */
  {  448,   -1 }, /* (505) group_by_list ::= expr_or_subquery */
  {  448,   -3 }, /* (506) group_by_list ::= group_by_list NK_COMMA expr_or_subquery */
  {  443,    0 }, /* (507) having_clause_opt ::= */
  {  443,   -2 }, /* (508) having_clause_opt ::= HAVING search_condition */
  {  438,    0 }, /* (509) range_opt ::= */
  {  438,   -6 }, /* (510) range_opt ::= RANGE NK_LP expr_or_subquery NK_COMMA expr_or_subquery NK_RP */
  {  439,    0 }, /* (511) every_opt ::= */
  {  439,   -4 }, /* (512) every_opt ::= EVERY NK_LP duration_literal NK_RP */
  {  449,   -4 }, /* (513) query_expression ::= query_simple order_by_clause_opt slimit_clause_opt limit_clause_opt */
  {  450,   -1 }, /* (514) query_simple ::= query_specification */
  {  450,   -1 }, /* (515) query_simple ::= union_query_expression */
  {  454,   -4 }, /* (516) union_query_expression ::= query_simple_or_subquery UNION ALL query_simple_or_subquery */
  {  454,   -3 }, /* (517) union_query_expression ::= query_simple_or_subquery UNION query_simple_or_subquery */
  {  455,   -1 }, /* (518) query_simple_or_subquery ::= query_simple */
  {  455,   -1 }, /* (519) query_simple_or_subquery ::= subquery */
  {  388,   -1 }, /* (520) query_or_subquery ::= query_expression */
  {  388,   -1 }, /* (521) query_or_subquery ::= subquery */
  {  451,    0 }, /* (522) order_by_clause_opt ::= */
  {  451,   -3 }, /* (523) order_by_clause_opt ::= ORDER BY sort_specification_list */
  {  452,    0 }, /* (524) slimit_clause_opt ::= */
  {  452,   -2 }, /* (525) slimit_clause_opt ::= SLIMIT NK_INTEGER */
  {  452,   -4 }, /* (526) slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER */
  {  452,   -4 }, /* (527) slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER */
  {  453,    0 }, /* (528) limit_clause_opt ::= */
  {  453,   -2 }, /* (529) limit_clause_opt ::= LIMIT NK_INTEGER */
  {  453,   -4 }, /* (530) limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER */
  {  453,   -4 }, /* (531) limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER */
  {  430,   -3 }, /* (532) subquery ::= NK_LP query_expression NK_RP */
  {  430,   -3 }, /* (533) subquery ::= NK_LP subquery NK_RP */
  {  433,   -1 }, /* (534) search_condition ::= common_expression */
  {  456,   -1 }, /* (535) sort_specification_list ::= sort_specification */
  {  456,   -3 }, /* (536) sort_specification_list ::= sort_specification_list NK_COMMA sort_specification */
  {  457,   -3 }, /* (537) sort_specification ::= expr_or_subquery ordering_specification_opt null_ordering_opt */
  {  458,    0 }, /* (538) ordering_specification_opt ::= */
  {  458,   -1 }, /* (539) ordering_specification_opt ::= ASC */
  {  458,   -1 }, /* (540) ordering_specification_opt ::= DESC */
  {  459,    0 }, /* (541) null_ordering_opt ::= */
  {  459,   -2 }, /* (542) null_ordering_opt ::= NULLS FIRST */
  {  459,   -2 }, /* (543) null_ordering_opt ::= NULLS LAST */
3620 3621 3622 3623 3624 3625 3626 3627 3628 3629 3630 3631 3632 3633 3634 3635 3636 3637
};

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 */
X
Xiaoyu Wang 已提交
3638 3639
  ParseTOKENTYPE yyLookaheadToken  /* Value of the lookahead token */
  ParseCTX_PDECL                   /* %extra_context */
3640 3641 3642 3643 3644
){
  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 */
X
Xiaoyu Wang 已提交
3645
  ParseARG_FETCH
3646 3647 3648
  (void)yyLookahead;
  (void)yyLookaheadToken;
  yymsp = yypParser->yytos;
X
Xiaoyu Wang 已提交
3649 3650
#ifndef NDEBUG
  if( yyTraceFILE && yyruleno<(int)(sizeof(yyRuleName)/sizeof(yyRuleName[0])) ){
X
Xiaoyu Wang 已提交
3651
    yysize = yyRuleInfo[yyruleno].nrhs;
X
Xiaoyu Wang 已提交
3652
    if( yysize ){
X
Xiaoyu Wang 已提交
3653
      fprintf(yyTraceFILE, "%sReduce %d [%s], go to state %d.\n",
X
Xiaoyu Wang 已提交
3654
        yyTracePrompt,
X
Xiaoyu Wang 已提交
3655
        yyruleno, yyRuleName[yyruleno], yymsp[yysize].stateno);
X
Xiaoyu Wang 已提交
3656
    }else{
X
Xiaoyu Wang 已提交
3657 3658
      fprintf(yyTraceFILE, "%sReduce %d [%s].\n",
        yyTracePrompt, yyruleno, yyRuleName[yyruleno]);
X
Xiaoyu Wang 已提交
3659 3660 3661 3662 3663 3664 3665
    }
  }
#endif /* NDEBUG */

  /* Check that the stack is large enough to grow by a single entry
  ** if the RHS of the rule is empty.  This ensures that there is room
  ** enough on the stack to push the LHS value */
X
Xiaoyu Wang 已提交
3666
  if( yyRuleInfo[yyruleno].nrhs==0 ){
X
Xiaoyu Wang 已提交
3667 3668 3669 3670 3671 3672 3673 3674 3675 3676 3677 3678 3679 3680 3681 3682 3683 3684 3685 3686 3687 3688 3689 3690 3691 3692 3693
#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 ){
      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
  }
3694 3695 3696 3697 3698 3699 3700 3701 3702 3703 3704 3705

  switch( yyruleno ){
  /* Beginning here are the reduction cases.  A typical example
  ** follows:
  **   case 0:
  **  #line <lineno> <grammarfile>
  **     { ... }           // User supplied code
  **  #line <lineno> <thisfile>
  **     break;
  */
/********** Begin reduce actions **********************************************/
        YYMINORTYPE yylhsminor;
3706
      case 0: /* cmd ::= CREATE ACCOUNT NK_ID PASS NK_STRING account_options */
3707
{ pCxt->errCode = generateSyntaxErrMsg(&pCxt->msgBuf, TSDB_CODE_PAR_EXPRIE_STATEMENT); }
X
Xiaoyu Wang 已提交
3708
  yy_destructor(yypParser,325,&yymsp[0].minor);
3709
        break;
3710
      case 1: /* cmd ::= ALTER ACCOUNT NK_ID alter_account_options */
3711
{ pCxt->errCode = generateSyntaxErrMsg(&pCxt->msgBuf, TSDB_CODE_PAR_EXPRIE_STATEMENT); }
X
Xiaoyu Wang 已提交
3712
  yy_destructor(yypParser,326,&yymsp[0].minor);
3713 3714 3715 3716 3717 3718 3719 3720 3721 3722 3723 3724 3725
        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);
X
Xiaoyu Wang 已提交
3726
{  yy_destructor(yypParser,325,&yymsp[-2].minor);
3727
{ }
X
Xiaoyu Wang 已提交
3728
  yy_destructor(yypParser,327,&yymsp[0].minor);
3729
}
3730
        break;
3731
      case 12: /* alter_account_options ::= alter_account_option */
X
Xiaoyu Wang 已提交
3732
{  yy_destructor(yypParser,328,&yymsp[0].minor);
3733 3734 3735
{ }
}
        break;
3736
      case 13: /* alter_account_options ::= alter_account_options alter_account_option */
X
Xiaoyu Wang 已提交
3737
{  yy_destructor(yypParser,326,&yymsp[-1].minor);
3738
{ }
X
Xiaoyu Wang 已提交
3739
  yy_destructor(yypParser,328,&yymsp[0].minor);
3740 3741 3742 3743 3744 3745 3746 3747 3748 3749 3750 3751
}
        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);
3752
{ }
X
Xiaoyu Wang 已提交
3753
  yy_destructor(yypParser,327,&yymsp[0].minor);
3754
        break;
X
Xiaoyu Wang 已提交
3755
      case 24: /* cmd ::= CREATE USER user_name PASS NK_STRING sysinfo_opt */
3756
{ pCxt->pRootNode = createCreateUserStmt(pCxt, &yymsp[-3].minor.yy849, &yymsp[-1].minor.yy0, yymsp[0].minor.yy383); }
3757
        break;
3758
      case 25: /* cmd ::= ALTER USER user_name PASS NK_STRING */
3759
{ pCxt->pRootNode = createAlterUserStmt(pCxt, &yymsp[-2].minor.yy849, TSDB_ALTER_USER_PASSWD, &yymsp[0].minor.yy0); }
3760
        break;
X
Xiaoyu Wang 已提交
3761
      case 26: /* cmd ::= ALTER USER user_name ENABLE NK_INTEGER */
3762
{ pCxt->pRootNode = createAlterUserStmt(pCxt, &yymsp[-2].minor.yy849, TSDB_ALTER_USER_ENABLE, &yymsp[0].minor.yy0); }
3763
        break;
X
Xiaoyu Wang 已提交
3764
      case 27: /* cmd ::= ALTER USER user_name SYSINFO NK_INTEGER */
3765
{ pCxt->pRootNode = createAlterUserStmt(pCxt, &yymsp[-2].minor.yy849, TSDB_ALTER_USER_SYSINFO, &yymsp[0].minor.yy0); }
3766
        break;
X
Xiaoyu Wang 已提交
3767
      case 28: /* cmd ::= DROP USER user_name */
3768
{ pCxt->pRootNode = createDropUserStmt(pCxt, &yymsp[0].minor.yy849); }
3769
        break;
X
Xiaoyu Wang 已提交
3770
      case 29: /* sysinfo_opt ::= */
3771
{ yymsp[1].minor.yy383 = 1; }
3772
        break;
X
Xiaoyu Wang 已提交
3773
      case 30: /* sysinfo_opt ::= SYSINFO NK_INTEGER */
3774
{ yymsp[-1].minor.yy383 = taosStr2Int8(yymsp[0].minor.yy0.z, NULL, 10); }
3775
        break;
X
Xiaoyu Wang 已提交
3776
      case 31: /* cmd ::= GRANT privileges ON priv_level TO user_name */
3777
{ pCxt->pRootNode = createGrantStmt(pCxt, yymsp[-4].minor.yy869, &yymsp[-2].minor.yy849, &yymsp[0].minor.yy849); }
3778
        break;
X
Xiaoyu Wang 已提交
3779
      case 32: /* cmd ::= REVOKE privileges ON priv_level FROM user_name */
3780
{ pCxt->pRootNode = createRevokeStmt(pCxt, yymsp[-4].minor.yy869, &yymsp[-2].minor.yy849, &yymsp[0].minor.yy849); }
3781
        break;
X
Xiaoyu Wang 已提交
3782
      case 33: /* privileges ::= ALL */
3783
{ yymsp[0].minor.yy869 = PRIVILEGE_TYPE_ALL; }
3784
        break;
X
Xiaoyu Wang 已提交
3785
      case 34: /* privileges ::= priv_type_list */
3786
      case 36: /* priv_type_list ::= priv_type */ yytestcase(yyruleno==36);
3787 3788
{ yylhsminor.yy869 = yymsp[0].minor.yy869; }
  yymsp[0].minor.yy869 = yylhsminor.yy869;
3789
        break;
3790
      case 35: /* privileges ::= SUBSCRIBE */
3791
{ yymsp[0].minor.yy869 = PRIVILEGE_TYPE_SUBSCRIBE; }
3792
        break;
3793
      case 37: /* priv_type_list ::= priv_type_list NK_COMMA priv_type */
3794 3795
{ yylhsminor.yy869 = yymsp[-2].minor.yy869 | yymsp[0].minor.yy869; }
  yymsp[-2].minor.yy869 = yylhsminor.yy869;
3796
        break;
3797
      case 38: /* priv_type ::= READ */
3798
{ yymsp[0].minor.yy869 = PRIVILEGE_TYPE_READ; }
3799
        break;
3800
      case 39: /* priv_type ::= WRITE */
3801
{ yymsp[0].minor.yy869 = PRIVILEGE_TYPE_WRITE; }
3802
        break;
3803
      case 40: /* priv_level ::= NK_STAR NK_DOT NK_STAR */
3804 3805
{ yylhsminor.yy849 = yymsp[-2].minor.yy0; }
  yymsp[-2].minor.yy849 = yylhsminor.yy849;
X
Xiaoyu Wang 已提交
3806
        break;
3807
      case 41: /* priv_level ::= db_name NK_DOT NK_STAR */
3808 3809
{ yylhsminor.yy849 = yymsp[-2].minor.yy849; }
  yymsp[-2].minor.yy849 = yylhsminor.yy849;
X
Xiaoyu Wang 已提交
3810
        break;
3811
      case 42: /* priv_level ::= topic_name */
3812 3813 3814 3815
      case 267: /* sma_func_name ::= function_name */ yytestcase(yyruleno==267);
      case 460: /* alias_opt ::= table_alias */ yytestcase(yyruleno==460);
{ yylhsminor.yy849 = yymsp[0].minor.yy849; }
  yymsp[0].minor.yy849 = yylhsminor.yy849;
X
Xiaoyu Wang 已提交
3816
        break;
3817
      case 43: /* cmd ::= CREATE DNODE dnode_endpoint */
3818
{ pCxt->pRootNode = createCreateDnodeStmt(pCxt, &yymsp[0].minor.yy849, NULL); }
3819
        break;
3820
      case 44: /* cmd ::= CREATE DNODE dnode_endpoint PORT NK_INTEGER */
3821
{ pCxt->pRootNode = createCreateDnodeStmt(pCxt, &yymsp[-2].minor.yy849, &yymsp[0].minor.yy0); }
3822
        break;
3823
      case 45: /* cmd ::= DROP DNODE NK_INTEGER force_opt */
3824
{ pCxt->pRootNode = createDropDnodeStmt(pCxt, &yymsp[-1].minor.yy0, yymsp[0].minor.yy57); }
3825 3826
        break;
      case 46: /* cmd ::= DROP DNODE dnode_endpoint force_opt */
3827
{ pCxt->pRootNode = createDropDnodeStmt(pCxt, &yymsp[-1].minor.yy849, yymsp[0].minor.yy57); }
3828 3829
        break;
      case 47: /* cmd ::= ALTER DNODE NK_INTEGER NK_STRING */
3830 3831
{ pCxt->pRootNode = createAlterDnodeStmt(pCxt, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0, NULL); }
        break;
3832
      case 48: /* cmd ::= ALTER DNODE NK_INTEGER NK_STRING NK_STRING */
3833 3834
{ pCxt->pRootNode = createAlterDnodeStmt(pCxt, &yymsp[-2].minor.yy0, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0); }
        break;
3835
      case 49: /* cmd ::= ALTER ALL DNODES NK_STRING */
3836 3837
{ pCxt->pRootNode = createAlterDnodeStmt(pCxt, NULL, &yymsp[0].minor.yy0, NULL); }
        break;
3838
      case 50: /* cmd ::= ALTER ALL DNODES NK_STRING NK_STRING */
3839 3840
{ pCxt->pRootNode = createAlterDnodeStmt(pCxt, NULL, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0); }
        break;
3841 3842 3843
      case 51: /* dnode_endpoint ::= NK_STRING */
      case 52: /* dnode_endpoint ::= NK_ID */ yytestcase(yyruleno==52);
      case 53: /* dnode_endpoint ::= NK_IPTOKEN */ yytestcase(yyruleno==53);
3844 3845 3846 3847 3848 3849 3850 3851 3852 3853 3854 3855 3856 3857 3858 3859 3860 3861 3862 3863 3864 3865 3866 3867 3868 3869 3870 3871 3872
      case 268: /* sma_func_name ::= COUNT */ yytestcase(yyruleno==268);
      case 269: /* sma_func_name ::= FIRST */ yytestcase(yyruleno==269);
      case 270: /* sma_func_name ::= LAST */ yytestcase(yyruleno==270);
      case 271: /* sma_func_name ::= LAST_ROW */ yytestcase(yyruleno==271);
      case 347: /* db_name ::= NK_ID */ yytestcase(yyruleno==347);
      case 348: /* table_name ::= NK_ID */ yytestcase(yyruleno==348);
      case 349: /* column_name ::= NK_ID */ yytestcase(yyruleno==349);
      case 350: /* function_name ::= NK_ID */ yytestcase(yyruleno==350);
      case 351: /* table_alias ::= NK_ID */ yytestcase(yyruleno==351);
      case 352: /* column_alias ::= NK_ID */ yytestcase(yyruleno==352);
      case 353: /* user_name ::= NK_ID */ yytestcase(yyruleno==353);
      case 354: /* topic_name ::= NK_ID */ yytestcase(yyruleno==354);
      case 355: /* stream_name ::= NK_ID */ yytestcase(yyruleno==355);
      case 356: /* cgroup_name ::= NK_ID */ yytestcase(yyruleno==356);
      case 395: /* noarg_func ::= NOW */ yytestcase(yyruleno==395);
      case 396: /* noarg_func ::= TODAY */ yytestcase(yyruleno==396);
      case 397: /* noarg_func ::= TIMEZONE */ yytestcase(yyruleno==397);
      case 398: /* noarg_func ::= DATABASE */ yytestcase(yyruleno==398);
      case 399: /* noarg_func ::= CLIENT_VERSION */ yytestcase(yyruleno==399);
      case 400: /* noarg_func ::= SERVER_VERSION */ yytestcase(yyruleno==400);
      case 401: /* noarg_func ::= SERVER_STATUS */ yytestcase(yyruleno==401);
      case 402: /* noarg_func ::= CURRENT_USER */ yytestcase(yyruleno==402);
      case 403: /* noarg_func ::= USER */ yytestcase(yyruleno==403);
      case 404: /* star_func ::= COUNT */ yytestcase(yyruleno==404);
      case 405: /* star_func ::= FIRST */ yytestcase(yyruleno==405);
      case 406: /* star_func ::= LAST */ yytestcase(yyruleno==406);
      case 407: /* star_func ::= LAST_ROW */ yytestcase(yyruleno==407);
{ yylhsminor.yy849 = yymsp[0].minor.yy0; }
  yymsp[0].minor.yy849 = yylhsminor.yy849;
3873 3874 3875 3876
        break;
      case 54: /* force_opt ::= */
      case 73: /* not_exists_opt ::= */ yytestcase(yyruleno==73);
      case 75: /* exists_opt ::= */ yytestcase(yyruleno==75);
3877 3878 3879 3880
      case 287: /* analyze_opt ::= */ yytestcase(yyruleno==287);
      case 294: /* agg_func_opt ::= */ yytestcase(yyruleno==294);
      case 468: /* set_quantifier_opt ::= */ yytestcase(yyruleno==468);
{ yymsp[1].minor.yy57 = false; }
3881 3882
        break;
      case 55: /* force_opt ::= FORCE */
3883 3884 3885 3886
      case 288: /* analyze_opt ::= ANALYZE */ yytestcase(yyruleno==288);
      case 295: /* agg_func_opt ::= AGGREGATE */ yytestcase(yyruleno==295);
      case 469: /* set_quantifier_opt ::= DISTINCT */ yytestcase(yyruleno==469);
{ yymsp[0].minor.yy57 = true; }
3887 3888
        break;
      case 56: /* cmd ::= ALTER LOCAL NK_STRING */
3889 3890
{ pCxt->pRootNode = createAlterLocalStmt(pCxt, &yymsp[0].minor.yy0, NULL); }
        break;
3891
      case 57: /* cmd ::= ALTER LOCAL NK_STRING NK_STRING */
3892 3893
{ pCxt->pRootNode = createAlterLocalStmt(pCxt, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0); }
        break;
3894
      case 58: /* cmd ::= CREATE QNODE ON DNODE NK_INTEGER */
3895
{ pCxt->pRootNode = createCreateComponentNodeStmt(pCxt, QUERY_NODE_CREATE_QNODE_STMT, &yymsp[0].minor.yy0); }
X
Xiaoyu Wang 已提交
3896
        break;
3897
      case 59: /* cmd ::= DROP QNODE ON DNODE NK_INTEGER */
3898
{ pCxt->pRootNode = createDropComponentNodeStmt(pCxt, QUERY_NODE_DROP_QNODE_STMT, &yymsp[0].minor.yy0); }
3899
        break;
3900
      case 60: /* cmd ::= CREATE BNODE ON DNODE NK_INTEGER */
3901
{ pCxt->pRootNode = createCreateComponentNodeStmt(pCxt, QUERY_NODE_CREATE_BNODE_STMT, &yymsp[0].minor.yy0); }
X
Xiaoyu Wang 已提交
3902
        break;
3903
      case 61: /* cmd ::= DROP BNODE ON DNODE NK_INTEGER */
3904
{ pCxt->pRootNode = createDropComponentNodeStmt(pCxt, QUERY_NODE_DROP_BNODE_STMT, &yymsp[0].minor.yy0); }
X
Xiaoyu Wang 已提交
3905
        break;
3906
      case 62: /* cmd ::= CREATE SNODE ON DNODE NK_INTEGER */
3907
{ pCxt->pRootNode = createCreateComponentNodeStmt(pCxt, QUERY_NODE_CREATE_SNODE_STMT, &yymsp[0].minor.yy0); }
3908
        break;
3909
      case 63: /* cmd ::= DROP SNODE ON DNODE NK_INTEGER */
3910
{ pCxt->pRootNode = createDropComponentNodeStmt(pCxt, QUERY_NODE_DROP_SNODE_STMT, &yymsp[0].minor.yy0); }
3911
        break;
3912
      case 64: /* cmd ::= CREATE MNODE ON DNODE NK_INTEGER */
3913
{ pCxt->pRootNode = createCreateComponentNodeStmt(pCxt, QUERY_NODE_CREATE_MNODE_STMT, &yymsp[0].minor.yy0); }
3914
        break;
3915
      case 65: /* cmd ::= DROP MNODE ON DNODE NK_INTEGER */
3916
{ pCxt->pRootNode = createDropComponentNodeStmt(pCxt, QUERY_NODE_DROP_MNODE_STMT, &yymsp[0].minor.yy0); }
3917
        break;
3918
      case 66: /* cmd ::= CREATE DATABASE not_exists_opt db_name db_options */
3919
{ pCxt->pRootNode = createCreateDatabaseStmt(pCxt, yymsp[-2].minor.yy57, &yymsp[-1].minor.yy849, yymsp[0].minor.yy752); }
3920
        break;
3921
      case 67: /* cmd ::= DROP DATABASE exists_opt db_name */
3922
{ pCxt->pRootNode = createDropDatabaseStmt(pCxt, yymsp[-1].minor.yy57, &yymsp[0].minor.yy849); }
3923
        break;
3924
      case 68: /* cmd ::= USE db_name */
3925
{ pCxt->pRootNode = createUseDatabaseStmt(pCxt, &yymsp[0].minor.yy849); }
3926
        break;
3927
      case 69: /* cmd ::= ALTER DATABASE db_name alter_db_options */
3928
{ pCxt->pRootNode = createAlterDatabaseStmt(pCxt, &yymsp[-1].minor.yy849, yymsp[0].minor.yy752); }
X
Xiaoyu Wang 已提交
3929
        break;
3930
      case 70: /* cmd ::= FLUSH DATABASE db_name */
3931
{ pCxt->pRootNode = createFlushDatabaseStmt(pCxt, &yymsp[0].minor.yy849); }
X
Xiaoyu Wang 已提交
3932
        break;
3933
      case 71: /* cmd ::= TRIM DATABASE db_name speed_opt */
3934
{ pCxt->pRootNode = createTrimDatabaseStmt(pCxt, &yymsp[-1].minor.yy849, yymsp[0].minor.yy340); }
X
Xiaoyu Wang 已提交
3935
        break;
3936
      case 72: /* not_exists_opt ::= IF NOT EXISTS */
3937
{ yymsp[-2].minor.yy57 = true; }
X
Xiaoyu Wang 已提交
3938
        break;
3939
      case 74: /* exists_opt ::= IF EXISTS */
3940
{ yymsp[-1].minor.yy57 = true; }
X
Xiaoyu Wang 已提交
3941
        break;
3942
      case 76: /* db_options ::= */
3943
{ yymsp[1].minor.yy752 = createDefaultDatabaseOptions(pCxt); }
X
Xiaoyu Wang 已提交
3944
        break;
3945
      case 77: /* db_options ::= db_options BUFFER NK_INTEGER */
3946 3947
{ yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-2].minor.yy752, DB_OPTION_BUFFER, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
3948
        break;
3949
      case 78: /* db_options ::= db_options CACHEMODEL NK_STRING */
3950 3951
{ yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-2].minor.yy752, DB_OPTION_CACHEMODEL, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
3952
        break;
3953
      case 79: /* db_options ::= db_options CACHESIZE NK_INTEGER */
3954 3955
{ yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-2].minor.yy752, DB_OPTION_CACHESIZE, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
3956
        break;
3957
      case 80: /* db_options ::= db_options COMP NK_INTEGER */
3958 3959
{ yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-2].minor.yy752, DB_OPTION_COMP, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
X
Xiaoyu Wang 已提交
3960
        break;
3961 3962
      case 81: /* db_options ::= db_options DURATION NK_INTEGER */
      case 82: /* db_options ::= db_options DURATION NK_VARIABLE */ yytestcase(yyruleno==82);
3963 3964
{ yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-2].minor.yy752, DB_OPTION_DAYS, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
3965
        break;
3966
      case 83: /* db_options ::= db_options MAXROWS NK_INTEGER */
3967 3968
{ yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-2].minor.yy752, DB_OPTION_MAXROWS, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
3969
        break;
3970
      case 84: /* db_options ::= db_options MINROWS NK_INTEGER */
3971 3972
{ yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-2].minor.yy752, DB_OPTION_MINROWS, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
3973
        break;
3974 3975
      case 85: /* db_options ::= db_options KEEP integer_list */
      case 86: /* db_options ::= db_options KEEP variable_list */ yytestcase(yyruleno==86);
3976 3977
{ yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-2].minor.yy752, DB_OPTION_KEEP, yymsp[0].minor.yy424); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
3978
        break;
3979
      case 87: /* db_options ::= db_options PAGES NK_INTEGER */
3980 3981
{ yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-2].minor.yy752, DB_OPTION_PAGES, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
X
Xiaoyu Wang 已提交
3982
        break;
3983
      case 88: /* db_options ::= db_options PAGESIZE NK_INTEGER */
3984 3985
{ yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-2].minor.yy752, DB_OPTION_PAGESIZE, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
X
Xiaoyu Wang 已提交
3986
        break;
3987
      case 89: /* db_options ::= db_options TSDB_PAGESIZE NK_INTEGER */
3988 3989
{ yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-2].minor.yy752, DB_OPTION_TSDB_PAGESIZE, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
3990
        break;
3991
      case 90: /* db_options ::= db_options PRECISION NK_STRING */
3992 3993
{ yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-2].minor.yy752, DB_OPTION_PRECISION, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
X
Xiaoyu Wang 已提交
3994
        break;
3995
      case 91: /* db_options ::= db_options REPLICA NK_INTEGER */
3996 3997
{ yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-2].minor.yy752, DB_OPTION_REPLICA, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
X
Xiaoyu Wang 已提交
3998
        break;
3999
      case 92: /* db_options ::= db_options VGROUPS NK_INTEGER */
4000 4001
{ yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-2].minor.yy752, DB_OPTION_VGROUPS, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
X
Xiaoyu Wang 已提交
4002
        break;
4003
      case 93: /* db_options ::= db_options SINGLE_STABLE NK_INTEGER */
4004 4005
{ yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-2].minor.yy752, DB_OPTION_SINGLE_STABLE, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
X
Xiaoyu Wang 已提交
4006
        break;
4007
      case 94: /* db_options ::= db_options RETENTIONS retention_list */
4008 4009
{ yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-2].minor.yy752, DB_OPTION_RETENTIONS, yymsp[0].minor.yy424); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
X
Xiaoyu Wang 已提交
4010
        break;
4011
      case 95: /* db_options ::= db_options SCHEMALESS NK_INTEGER */
4012 4013
{ yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-2].minor.yy752, DB_OPTION_SCHEMALESS, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
X
Xiaoyu Wang 已提交
4014
        break;
4015
      case 96: /* db_options ::= db_options WAL_LEVEL NK_INTEGER */
4016 4017
{ yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-2].minor.yy752, DB_OPTION_WAL, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
X
Xiaoyu Wang 已提交
4018
        break;
4019
      case 97: /* db_options ::= db_options WAL_FSYNC_PERIOD NK_INTEGER */
4020 4021
{ yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-2].minor.yy752, DB_OPTION_FSYNC, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
X
Xiaoyu Wang 已提交
4022
        break;
4023
      case 98: /* db_options ::= db_options WAL_RETENTION_PERIOD NK_INTEGER */
4024 4025
{ yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-2].minor.yy752, DB_OPTION_WAL_RETENTION_PERIOD, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
4026
        break;
4027
      case 99: /* db_options ::= db_options WAL_RETENTION_PERIOD NK_MINUS NK_INTEGER */
X
Xiaoyu Wang 已提交
4028 4029 4030
{ 
                                                                                    SToken t = yymsp[-1].minor.yy0;
                                                                                    t.n = (yymsp[0].minor.yy0.z + yymsp[0].minor.yy0.n) - yymsp[-1].minor.yy0.z;
4031
                                                                                    yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-3].minor.yy752, DB_OPTION_WAL_RETENTION_PERIOD, &t);
X
Xiaoyu Wang 已提交
4032
                                                                                  }
4033
  yymsp[-3].minor.yy752 = yylhsminor.yy752;
X
Xiaoyu Wang 已提交
4034
        break;
4035
      case 100: /* db_options ::= db_options WAL_RETENTION_SIZE NK_INTEGER */
4036 4037
{ yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-2].minor.yy752, DB_OPTION_WAL_RETENTION_SIZE, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
X
Xiaoyu Wang 已提交
4038
        break;
4039
      case 101: /* db_options ::= db_options WAL_RETENTION_SIZE NK_MINUS NK_INTEGER */
X
Xiaoyu Wang 已提交
4040 4041 4042
{ 
                                                                                    SToken t = yymsp[-1].minor.yy0;
                                                                                    t.n = (yymsp[0].minor.yy0.z + yymsp[0].minor.yy0.n) - yymsp[-1].minor.yy0.z;
4043
                                                                                    yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-3].minor.yy752, DB_OPTION_WAL_RETENTION_SIZE, &t);
X
Xiaoyu Wang 已提交
4044
                                                                                  }
4045
  yymsp[-3].minor.yy752 = yylhsminor.yy752;
4046
        break;
4047
      case 102: /* db_options ::= db_options WAL_ROLL_PERIOD NK_INTEGER */
4048 4049
{ yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-2].minor.yy752, DB_OPTION_WAL_ROLL_PERIOD, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
4050
        break;
4051
      case 103: /* db_options ::= db_options WAL_SEGMENT_SIZE NK_INTEGER */
4052 4053
{ yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-2].minor.yy752, DB_OPTION_WAL_SEGMENT_SIZE, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
4054
        break;
4055
      case 104: /* db_options ::= db_options STT_TRIGGER NK_INTEGER */
4056 4057
{ yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-2].minor.yy752, DB_OPTION_STT_TRIGGER, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
4058
        break;
4059
      case 105: /* db_options ::= db_options TABLE_PREFIX NK_INTEGER */
4060 4061
{ yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-2].minor.yy752, DB_OPTION_TABLE_PREFIX, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
4062
        break;
4063
      case 106: /* db_options ::= db_options TABLE_SUFFIX NK_INTEGER */
4064 4065
{ yylhsminor.yy752 = setDatabaseOption(pCxt, yymsp[-2].minor.yy752, DB_OPTION_TABLE_SUFFIX, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
4066
        break;
4067
      case 107: /* alter_db_options ::= alter_db_option */
4068 4069
{ yylhsminor.yy752 = createAlterDatabaseOptions(pCxt); yylhsminor.yy752 = setAlterDatabaseOption(pCxt, yylhsminor.yy752, &yymsp[0].minor.yy5); }
  yymsp[0].minor.yy752 = yylhsminor.yy752;
4070
        break;
4071
      case 108: /* alter_db_options ::= alter_db_options alter_db_option */
4072 4073
{ yylhsminor.yy752 = setAlterDatabaseOption(pCxt, yymsp[-1].minor.yy752, &yymsp[0].minor.yy5); }
  yymsp[-1].minor.yy752 = yylhsminor.yy752;
4074
        break;
4075
      case 109: /* alter_db_option ::= BUFFER NK_INTEGER */
4076
{ yymsp[-1].minor.yy5.type = DB_OPTION_BUFFER; yymsp[-1].minor.yy5.val = yymsp[0].minor.yy0; }
4077
        break;
4078
      case 110: /* alter_db_option ::= CACHEMODEL NK_STRING */
4079
{ yymsp[-1].minor.yy5.type = DB_OPTION_CACHEMODEL; yymsp[-1].minor.yy5.val = yymsp[0].minor.yy0; }
4080
        break;
4081
      case 111: /* alter_db_option ::= CACHESIZE NK_INTEGER */
4082
{ yymsp[-1].minor.yy5.type = DB_OPTION_CACHESIZE; yymsp[-1].minor.yy5.val = yymsp[0].minor.yy0; }
4083
        break;
4084
      case 112: /* alter_db_option ::= WAL_FSYNC_PERIOD NK_INTEGER */
4085
{ yymsp[-1].minor.yy5.type = DB_OPTION_FSYNC; yymsp[-1].minor.yy5.val = yymsp[0].minor.yy0; }
4086
        break;
4087 4088
      case 113: /* alter_db_option ::= KEEP integer_list */
      case 114: /* alter_db_option ::= KEEP variable_list */ yytestcase(yyruleno==114);
4089
{ yymsp[-1].minor.yy5.type = DB_OPTION_KEEP; yymsp[-1].minor.yy5.pList = yymsp[0].minor.yy424; }
4090
        break;
4091
      case 115: /* alter_db_option ::= PAGES NK_INTEGER */
4092
{ yymsp[-1].minor.yy5.type = DB_OPTION_PAGES; yymsp[-1].minor.yy5.val = yymsp[0].minor.yy0; }
4093
        break;
4094
      case 116: /* alter_db_option ::= REPLICA NK_INTEGER */
4095
{ yymsp[-1].minor.yy5.type = DB_OPTION_REPLICA; yymsp[-1].minor.yy5.val = yymsp[0].minor.yy0; }
4096
        break;
4097
      case 117: /* alter_db_option ::= WAL_LEVEL NK_INTEGER */
4098
{ yymsp[-1].minor.yy5.type = DB_OPTION_WAL; yymsp[-1].minor.yy5.val = yymsp[0].minor.yy0; }
4099
        break;
4100
      case 118: /* alter_db_option ::= STT_TRIGGER NK_INTEGER */
4101
{ yymsp[-1].minor.yy5.type = DB_OPTION_STT_TRIGGER; yymsp[-1].minor.yy5.val = yymsp[0].minor.yy0; }
4102
        break;
4103
      case 119: /* integer_list ::= NK_INTEGER */
4104 4105
{ yylhsminor.yy424 = createNodeList(pCxt, createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0)); }
  yymsp[0].minor.yy424 = yylhsminor.yy424;
4106
        break;
4107
      case 120: /* integer_list ::= integer_list NK_COMMA NK_INTEGER */
4108 4109 4110
      case 317: /* dnode_list ::= dnode_list DNODE NK_INTEGER */ yytestcase(yyruleno==317);
{ yylhsminor.yy424 = addNodeToList(pCxt, yymsp[-2].minor.yy424, createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0)); }
  yymsp[-2].minor.yy424 = yylhsminor.yy424;
4111
        break;
4112
      case 121: /* variable_list ::= NK_VARIABLE */
4113 4114
{ yylhsminor.yy424 = createNodeList(pCxt, createDurationValueNode(pCxt, &yymsp[0].minor.yy0)); }
  yymsp[0].minor.yy424 = yylhsminor.yy424;
4115
        break;
4116
      case 122: /* variable_list ::= variable_list NK_COMMA NK_VARIABLE */
4117 4118
{ yylhsminor.yy424 = addNodeToList(pCxt, yymsp[-2].minor.yy424, createDurationValueNode(pCxt, &yymsp[0].minor.yy0)); }
  yymsp[-2].minor.yy424 = yylhsminor.yy424;
4119
        break;
4120 4121 4122 4123 4124 4125 4126 4127
      case 123: /* retention_list ::= retention */
      case 145: /* multi_create_clause ::= create_subtable_clause */ yytestcase(yyruleno==145);
      case 148: /* multi_drop_clause ::= drop_table_clause */ yytestcase(yyruleno==148);
      case 155: /* column_def_list ::= column_def */ yytestcase(yyruleno==155);
      case 199: /* rollup_func_list ::= rollup_func_name */ yytestcase(yyruleno==199);
      case 204: /* col_name_list ::= col_name */ yytestcase(yyruleno==204);
      case 253: /* tag_list_opt ::= tag_item */ yytestcase(yyruleno==253);
      case 264: /* func_list ::= func */ yytestcase(yyruleno==264);
4128 4129 4130 4131 4132 4133 4134 4135
      case 345: /* literal_list ::= signed_literal */ yytestcase(yyruleno==345);
      case 410: /* other_para_list ::= star_func_para */ yytestcase(yyruleno==410);
      case 416: /* when_then_list ::= when_then_expr */ yytestcase(yyruleno==416);
      case 471: /* select_list ::= select_item */ yytestcase(yyruleno==471);
      case 482: /* partition_list ::= partition_item */ yytestcase(yyruleno==482);
      case 535: /* sort_specification_list ::= sort_specification */ yytestcase(yyruleno==535);
{ yylhsminor.yy424 = createNodeList(pCxt, yymsp[0].minor.yy752); }
  yymsp[0].minor.yy424 = yylhsminor.yy424;
4136
        break;
4137 4138 4139 4140 4141 4142
      case 124: /* retention_list ::= retention_list NK_COMMA retention */
      case 156: /* column_def_list ::= column_def_list NK_COMMA column_def */ yytestcase(yyruleno==156);
      case 200: /* rollup_func_list ::= rollup_func_list NK_COMMA rollup_func_name */ yytestcase(yyruleno==200);
      case 205: /* col_name_list ::= col_name_list NK_COMMA col_name */ yytestcase(yyruleno==205);
      case 254: /* tag_list_opt ::= tag_list_opt NK_COMMA tag_item */ yytestcase(yyruleno==254);
      case 265: /* func_list ::= func_list NK_COMMA func */ yytestcase(yyruleno==265);
4143 4144 4145 4146 4147 4148 4149
      case 346: /* literal_list ::= literal_list NK_COMMA signed_literal */ yytestcase(yyruleno==346);
      case 411: /* other_para_list ::= other_para_list NK_COMMA star_func_para */ yytestcase(yyruleno==411);
      case 472: /* select_list ::= select_list NK_COMMA select_item */ yytestcase(yyruleno==472);
      case 483: /* partition_list ::= partition_list NK_COMMA partition_item */ yytestcase(yyruleno==483);
      case 536: /* sort_specification_list ::= sort_specification_list NK_COMMA sort_specification */ yytestcase(yyruleno==536);
{ yylhsminor.yy424 = addNodeToList(pCxt, yymsp[-2].minor.yy424, yymsp[0].minor.yy752); }
  yymsp[-2].minor.yy424 = yylhsminor.yy424;
4150
        break;
4151
      case 125: /* retention ::= NK_VARIABLE NK_COLON NK_VARIABLE */
4152 4153
{ yylhsminor.yy752 = createNodeListNodeEx(pCxt, createDurationValueNode(pCxt, &yymsp[-2].minor.yy0), createDurationValueNode(pCxt, &yymsp[0].minor.yy0)); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
4154
        break;
4155
      case 126: /* speed_opt ::= */
4156 4157
      case 296: /* bufsize_opt ::= */ yytestcase(yyruleno==296);
{ yymsp[1].minor.yy340 = 0; }
4158
        break;
4159
      case 127: /* speed_opt ::= MAX_SPEED NK_INTEGER */
4160 4161
      case 297: /* bufsize_opt ::= BUFSIZE NK_INTEGER */ yytestcase(yyruleno==297);
{ yymsp[-1].minor.yy340 = taosStr2Int32(yymsp[0].minor.yy0.z, NULL, 10); }
4162
        break;
4163 4164
      case 128: /* cmd ::= CREATE TABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def_opt table_options */
      case 130: /* cmd ::= CREATE STABLE not_exists_opt full_table_name NK_LP column_def_list NK_RP tags_def table_options */ yytestcase(yyruleno==130);
4165
{ pCxt->pRootNode = createCreateTableStmt(pCxt, yymsp[-6].minor.yy57, yymsp[-5].minor.yy752, yymsp[-3].minor.yy424, yymsp[-1].minor.yy424, yymsp[0].minor.yy752); }
4166
        break;
4167
      case 129: /* cmd ::= CREATE TABLE multi_create_clause */
4168
{ pCxt->pRootNode = createCreateMultiTableStmt(pCxt, yymsp[0].minor.yy424); }
4169
        break;
4170
      case 131: /* cmd ::= DROP TABLE multi_drop_clause */
4171
{ pCxt->pRootNode = createDropTableStmt(pCxt, yymsp[0].minor.yy424); }
4172
        break;
4173
      case 132: /* cmd ::= DROP STABLE exists_opt full_table_name */
4174
{ pCxt->pRootNode = createDropSuperTableStmt(pCxt, yymsp[-1].minor.yy57, yymsp[0].minor.yy752); }
4175
        break;
4176
      case 133: /* cmd ::= ALTER TABLE alter_table_clause */
4177 4178
      case 319: /* cmd ::= query_or_subquery */ yytestcase(yyruleno==319);
{ pCxt->pRootNode = yymsp[0].minor.yy752; }
4179
        break;
4180
      case 134: /* cmd ::= ALTER STABLE alter_table_clause */
4181
{ pCxt->pRootNode = setAlterSuperTableType(yymsp[0].minor.yy752); }
4182
        break;
4183
      case 135: /* alter_table_clause ::= full_table_name alter_table_options */
4184 4185
{ yylhsminor.yy752 = createAlterTableModifyOptions(pCxt, yymsp[-1].minor.yy752, yymsp[0].minor.yy752); }
  yymsp[-1].minor.yy752 = yylhsminor.yy752;
4186
        break;
4187
      case 136: /* alter_table_clause ::= full_table_name ADD COLUMN column_name type_name */
4188 4189
{ yylhsminor.yy752 = createAlterTableAddModifyCol(pCxt, yymsp[-4].minor.yy752, TSDB_ALTER_TABLE_ADD_COLUMN, &yymsp[-1].minor.yy849, yymsp[0].minor.yy384); }
  yymsp[-4].minor.yy752 = yylhsminor.yy752;
4190
        break;
4191
      case 137: /* alter_table_clause ::= full_table_name DROP COLUMN column_name */
4192 4193
{ yylhsminor.yy752 = createAlterTableDropCol(pCxt, yymsp[-3].minor.yy752, TSDB_ALTER_TABLE_DROP_COLUMN, &yymsp[0].minor.yy849); }
  yymsp[-3].minor.yy752 = yylhsminor.yy752;
4194
        break;
4195
      case 138: /* alter_table_clause ::= full_table_name MODIFY COLUMN column_name type_name */
4196 4197
{ yylhsminor.yy752 = createAlterTableAddModifyCol(pCxt, yymsp[-4].minor.yy752, TSDB_ALTER_TABLE_UPDATE_COLUMN_BYTES, &yymsp[-1].minor.yy849, yymsp[0].minor.yy384); }
  yymsp[-4].minor.yy752 = yylhsminor.yy752;
4198
        break;
4199
      case 139: /* alter_table_clause ::= full_table_name RENAME COLUMN column_name column_name */
4200 4201
{ yylhsminor.yy752 = createAlterTableRenameCol(pCxt, yymsp[-4].minor.yy752, TSDB_ALTER_TABLE_UPDATE_COLUMN_NAME, &yymsp[-1].minor.yy849, &yymsp[0].minor.yy849); }
  yymsp[-4].minor.yy752 = yylhsminor.yy752;
4202
        break;
4203
      case 140: /* alter_table_clause ::= full_table_name ADD TAG column_name type_name */
4204 4205
{ yylhsminor.yy752 = createAlterTableAddModifyCol(pCxt, yymsp[-4].minor.yy752, TSDB_ALTER_TABLE_ADD_TAG, &yymsp[-1].minor.yy849, yymsp[0].minor.yy384); }
  yymsp[-4].minor.yy752 = yylhsminor.yy752;
4206
        break;
4207
      case 141: /* alter_table_clause ::= full_table_name DROP TAG column_name */
4208 4209
{ yylhsminor.yy752 = createAlterTableDropCol(pCxt, yymsp[-3].minor.yy752, TSDB_ALTER_TABLE_DROP_TAG, &yymsp[0].minor.yy849); }
  yymsp[-3].minor.yy752 = yylhsminor.yy752;
4210
        break;
4211
      case 142: /* alter_table_clause ::= full_table_name MODIFY TAG column_name type_name */
4212 4213
{ yylhsminor.yy752 = createAlterTableAddModifyCol(pCxt, yymsp[-4].minor.yy752, TSDB_ALTER_TABLE_UPDATE_TAG_BYTES, &yymsp[-1].minor.yy849, yymsp[0].minor.yy384); }
  yymsp[-4].minor.yy752 = yylhsminor.yy752;
4214
        break;
4215
      case 143: /* alter_table_clause ::= full_table_name RENAME TAG column_name column_name */
4216 4217
{ yylhsminor.yy752 = createAlterTableRenameCol(pCxt, yymsp[-4].minor.yy752, TSDB_ALTER_TABLE_UPDATE_TAG_NAME, &yymsp[-1].minor.yy849, &yymsp[0].minor.yy849); }
  yymsp[-4].minor.yy752 = yylhsminor.yy752;
4218
        break;
4219
      case 144: /* alter_table_clause ::= full_table_name SET TAG column_name NK_EQ signed_literal */
4220 4221
{ yylhsminor.yy752 = createAlterTableSetTag(pCxt, yymsp[-5].minor.yy752, &yymsp[-2].minor.yy849, yymsp[0].minor.yy752); }
  yymsp[-5].minor.yy752 = yylhsminor.yy752;
4222
        break;
4223 4224
      case 146: /* multi_create_clause ::= multi_create_clause create_subtable_clause */
      case 149: /* multi_drop_clause ::= multi_drop_clause drop_table_clause */ yytestcase(yyruleno==149);
4225 4226 4227
      case 417: /* when_then_list ::= when_then_list when_then_expr */ yytestcase(yyruleno==417);
{ yylhsminor.yy424 = addNodeToList(pCxt, yymsp[-1].minor.yy424, yymsp[0].minor.yy752); }
  yymsp[-1].minor.yy424 = yylhsminor.yy424;
4228
        break;
4229
      case 147: /* create_subtable_clause ::= not_exists_opt full_table_name USING full_table_name specific_cols_opt TAGS NK_LP expression_list NK_RP table_options */
4230 4231
{ yylhsminor.yy752 = createCreateSubTableClause(pCxt, yymsp[-9].minor.yy57, yymsp[-8].minor.yy752, yymsp[-6].minor.yy752, yymsp[-5].minor.yy424, yymsp[-2].minor.yy424, yymsp[0].minor.yy752); }
  yymsp[-9].minor.yy752 = yylhsminor.yy752;
4232
        break;
4233
      case 150: /* drop_table_clause ::= exists_opt full_table_name */
4234 4235
{ yylhsminor.yy752 = createDropTableClause(pCxt, yymsp[-1].minor.yy57, yymsp[0].minor.yy752); }
  yymsp[-1].minor.yy752 = yylhsminor.yy752;
4236
        break;
4237 4238 4239
      case 151: /* specific_cols_opt ::= */
      case 182: /* tags_def_opt ::= */ yytestcase(yyruleno==182);
      case 252: /* tag_list_opt ::= */ yytestcase(yyruleno==252);
4240 4241 4242 4243
      case 480: /* partition_by_clause_opt ::= */ yytestcase(yyruleno==480);
      case 503: /* group_by_clause_opt ::= */ yytestcase(yyruleno==503);
      case 522: /* order_by_clause_opt ::= */ yytestcase(yyruleno==522);
{ yymsp[1].minor.yy424 = NULL; }
4244
        break;
4245
      case 152: /* specific_cols_opt ::= NK_LP col_name_list NK_RP */
4246
{ yymsp[-2].minor.yy424 = yymsp[-1].minor.yy424; }
4247
        break;
4248
      case 153: /* full_table_name ::= table_name */
4249 4250
{ yylhsminor.yy752 = createRealTableNode(pCxt, NULL, &yymsp[0].minor.yy849, NULL); }
  yymsp[0].minor.yy752 = yylhsminor.yy752;
4251
        break;
4252
      case 154: /* full_table_name ::= db_name NK_DOT table_name */
4253 4254
{ yylhsminor.yy752 = createRealTableNode(pCxt, &yymsp[-2].minor.yy849, &yymsp[0].minor.yy849, NULL); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
4255
        break;
4256
      case 157: /* column_def ::= column_name type_name */
4257 4258
{ yylhsminor.yy752 = createColumnDefNode(pCxt, &yymsp[-1].minor.yy849, yymsp[0].minor.yy384, NULL); }
  yymsp[-1].minor.yy752 = yylhsminor.yy752;
4259
        break;
4260
      case 158: /* column_def ::= column_name type_name COMMENT NK_STRING */
4261 4262
{ yylhsminor.yy752 = createColumnDefNode(pCxt, &yymsp[-3].minor.yy849, yymsp[-2].minor.yy384, &yymsp[0].minor.yy0); }
  yymsp[-3].minor.yy752 = yylhsminor.yy752;
4263
        break;
4264
      case 159: /* type_name ::= BOOL */
4265
{ yymsp[0].minor.yy384 = createDataType(TSDB_DATA_TYPE_BOOL); }
4266
        break;
4267
      case 160: /* type_name ::= TINYINT */
4268
{ yymsp[0].minor.yy384 = createDataType(TSDB_DATA_TYPE_TINYINT); }
4269
        break;
4270
      case 161: /* type_name ::= SMALLINT */
4271
{ yymsp[0].minor.yy384 = createDataType(TSDB_DATA_TYPE_SMALLINT); }
4272
        break;
4273 4274
      case 162: /* type_name ::= INT */
      case 163: /* type_name ::= INTEGER */ yytestcase(yyruleno==163);
4275
{ yymsp[0].minor.yy384 = createDataType(TSDB_DATA_TYPE_INT); }
4276
        break;
4277
      case 164: /* type_name ::= BIGINT */
4278
{ yymsp[0].minor.yy384 = createDataType(TSDB_DATA_TYPE_BIGINT); }
4279
        break;
4280
      case 165: /* type_name ::= FLOAT */
4281
{ yymsp[0].minor.yy384 = createDataType(TSDB_DATA_TYPE_FLOAT); }
4282
        break;
4283
      case 166: /* type_name ::= DOUBLE */
4284
{ yymsp[0].minor.yy384 = createDataType(TSDB_DATA_TYPE_DOUBLE); }
4285
        break;
4286
      case 167: /* type_name ::= BINARY NK_LP NK_INTEGER NK_RP */
4287
{ yymsp[-3].minor.yy384 = createVarLenDataType(TSDB_DATA_TYPE_BINARY, &yymsp[-1].minor.yy0); }
4288
        break;
4289
      case 168: /* type_name ::= TIMESTAMP */
4290
{ yymsp[0].minor.yy384 = createDataType(TSDB_DATA_TYPE_TIMESTAMP); }
4291
        break;
4292
      case 169: /* type_name ::= NCHAR NK_LP NK_INTEGER NK_RP */
4293
{ yymsp[-3].minor.yy384 = createVarLenDataType(TSDB_DATA_TYPE_NCHAR, &yymsp[-1].minor.yy0); }
4294
        break;
4295
      case 170: /* type_name ::= TINYINT UNSIGNED */
4296
{ yymsp[-1].minor.yy384 = createDataType(TSDB_DATA_TYPE_UTINYINT); }
4297
        break;
4298
      case 171: /* type_name ::= SMALLINT UNSIGNED */
4299
{ yymsp[-1].minor.yy384 = createDataType(TSDB_DATA_TYPE_USMALLINT); }
4300
        break;
4301
      case 172: /* type_name ::= INT UNSIGNED */
4302
{ yymsp[-1].minor.yy384 = createDataType(TSDB_DATA_TYPE_UINT); }
4303
        break;
4304
      case 173: /* type_name ::= BIGINT UNSIGNED */
4305
{ yymsp[-1].minor.yy384 = createDataType(TSDB_DATA_TYPE_UBIGINT); }
4306
        break;
4307
      case 174: /* type_name ::= JSON */
4308
{ yymsp[0].minor.yy384 = createDataType(TSDB_DATA_TYPE_JSON); }
4309
        break;
4310
      case 175: /* type_name ::= VARCHAR NK_LP NK_INTEGER NK_RP */
4311
{ yymsp[-3].minor.yy384 = createVarLenDataType(TSDB_DATA_TYPE_VARCHAR, &yymsp[-1].minor.yy0); }
4312
        break;
4313
      case 176: /* type_name ::= MEDIUMBLOB */
4314
{ yymsp[0].minor.yy384 = createDataType(TSDB_DATA_TYPE_MEDIUMBLOB); }
4315
        break;
4316
      case 177: /* type_name ::= BLOB */
4317
{ yymsp[0].minor.yy384 = createDataType(TSDB_DATA_TYPE_BLOB); }
4318
        break;
4319
      case 178: /* type_name ::= VARBINARY NK_LP NK_INTEGER NK_RP */
4320
{ yymsp[-3].minor.yy384 = createVarLenDataType(TSDB_DATA_TYPE_VARBINARY, &yymsp[-1].minor.yy0); }
4321
        break;
4322
      case 179: /* type_name ::= DECIMAL */
4323
{ yymsp[0].minor.yy384 = createDataType(TSDB_DATA_TYPE_DECIMAL); }
4324
        break;
4325
      case 180: /* type_name ::= DECIMAL NK_LP NK_INTEGER NK_RP */
4326
{ yymsp[-3].minor.yy384 = createDataType(TSDB_DATA_TYPE_DECIMAL); }
4327
        break;
4328
      case 181: /* type_name ::= DECIMAL NK_LP NK_INTEGER NK_COMMA NK_INTEGER NK_RP */
4329
{ yymsp[-5].minor.yy384 = createDataType(TSDB_DATA_TYPE_DECIMAL); }
4330
        break;
4331
      case 183: /* tags_def_opt ::= tags_def */
4332 4333 4334
      case 409: /* star_func_para_list ::= other_para_list */ yytestcase(yyruleno==409);
{ yylhsminor.yy424 = yymsp[0].minor.yy424; }
  yymsp[0].minor.yy424 = yylhsminor.yy424;
4335
        break;
4336
      case 184: /* tags_def ::= TAGS NK_LP column_def_list NK_RP */
4337
{ yymsp[-3].minor.yy424 = yymsp[-1].minor.yy424; }
4338
        break;
4339
      case 185: /* table_options ::= */
4340
{ yymsp[1].minor.yy752 = createDefaultTableOptions(pCxt); }
X
Xiaoyu Wang 已提交
4341
        break;
4342
      case 186: /* table_options ::= table_options COMMENT NK_STRING */
4343 4344
{ yylhsminor.yy752 = setTableOption(pCxt, yymsp[-2].minor.yy752, TABLE_OPTION_COMMENT, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
4345
        break;
4346
      case 187: /* table_options ::= table_options MAX_DELAY duration_list */
4347 4348
{ yylhsminor.yy752 = setTableOption(pCxt, yymsp[-2].minor.yy752, TABLE_OPTION_MAXDELAY, yymsp[0].minor.yy424); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
4349
        break;
4350
      case 188: /* table_options ::= table_options WATERMARK duration_list */
4351 4352
{ yylhsminor.yy752 = setTableOption(pCxt, yymsp[-2].minor.yy752, TABLE_OPTION_WATERMARK, yymsp[0].minor.yy424); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
4353
        break;
4354
      case 189: /* table_options ::= table_options ROLLUP NK_LP rollup_func_list NK_RP */
4355 4356
{ yylhsminor.yy752 = setTableOption(pCxt, yymsp[-4].minor.yy752, TABLE_OPTION_ROLLUP, yymsp[-1].minor.yy424); }
  yymsp[-4].minor.yy752 = yylhsminor.yy752;
4357
        break;
4358
      case 190: /* table_options ::= table_options TTL NK_INTEGER */
4359 4360
{ yylhsminor.yy752 = setTableOption(pCxt, yymsp[-2].minor.yy752, TABLE_OPTION_TTL, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
4361
        break;
4362
      case 191: /* table_options ::= table_options SMA NK_LP col_name_list NK_RP */
4363 4364
{ yylhsminor.yy752 = setTableOption(pCxt, yymsp[-4].minor.yy752, TABLE_OPTION_SMA, yymsp[-1].minor.yy424); }
  yymsp[-4].minor.yy752 = yylhsminor.yy752;
4365
        break;
4366
      case 192: /* table_options ::= table_options DELETE_MARK duration_list */
4367 4368
{ yylhsminor.yy752 = setTableOption(pCxt, yymsp[-2].minor.yy752, TABLE_OPTION_DELETE_MARK, yymsp[0].minor.yy424); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
4369
        break;
4370
      case 193: /* alter_table_options ::= alter_table_option */
4371 4372
{ yylhsminor.yy752 = createAlterTableOptions(pCxt); yylhsminor.yy752 = setTableOption(pCxt, yylhsminor.yy752, yymsp[0].minor.yy5.type, &yymsp[0].minor.yy5.val); }
  yymsp[0].minor.yy752 = yylhsminor.yy752;
4373
        break;
4374
      case 194: /* alter_table_options ::= alter_table_options alter_table_option */
4375 4376
{ yylhsminor.yy752 = setTableOption(pCxt, yymsp[-1].minor.yy752, yymsp[0].minor.yy5.type, &yymsp[0].minor.yy5.val); }
  yymsp[-1].minor.yy752 = yylhsminor.yy752;
X
Xiaoyu Wang 已提交
4377
        break;
4378
      case 195: /* alter_table_option ::= COMMENT NK_STRING */
4379
{ yymsp[-1].minor.yy5.type = TABLE_OPTION_COMMENT; yymsp[-1].minor.yy5.val = yymsp[0].minor.yy0; }
X
Xiaoyu Wang 已提交
4380
        break;
4381
      case 196: /* alter_table_option ::= TTL NK_INTEGER */
4382
{ yymsp[-1].minor.yy5.type = TABLE_OPTION_TTL; yymsp[-1].minor.yy5.val = yymsp[0].minor.yy0; }
X
Xiaoyu Wang 已提交
4383
        break;
4384
      case 197: /* duration_list ::= duration_literal */
4385 4386 4387
      case 374: /* expression_list ::= expr_or_subquery */ yytestcase(yyruleno==374);
{ yylhsminor.yy424 = createNodeList(pCxt, releaseRawExprNode(pCxt, yymsp[0].minor.yy752)); }
  yymsp[0].minor.yy424 = yylhsminor.yy424;
X
Xiaoyu Wang 已提交
4388
        break;
4389
      case 198: /* duration_list ::= duration_list NK_COMMA duration_literal */
4390 4391 4392
      case 375: /* expression_list ::= expression_list NK_COMMA expr_or_subquery */ yytestcase(yyruleno==375);
{ yylhsminor.yy424 = addNodeToList(pCxt, yymsp[-2].minor.yy424, releaseRawExprNode(pCxt, yymsp[0].minor.yy752)); }
  yymsp[-2].minor.yy424 = yylhsminor.yy424;
4393
        break;
4394
      case 201: /* rollup_func_name ::= function_name */
4395 4396
{ yylhsminor.yy752 = createFunctionNode(pCxt, &yymsp[0].minor.yy849, NULL); }
  yymsp[0].minor.yy752 = yylhsminor.yy752;
4397
        break;
4398 4399 4400
      case 202: /* rollup_func_name ::= FIRST */
      case 203: /* rollup_func_name ::= LAST */ yytestcase(yyruleno==203);
      case 256: /* tag_item ::= QTAGS */ yytestcase(yyruleno==256);
4401 4402
{ yylhsminor.yy752 = createFunctionNode(pCxt, &yymsp[0].minor.yy0, NULL); }
  yymsp[0].minor.yy752 = yylhsminor.yy752;
4403
        break;
4404 4405
      case 206: /* col_name ::= column_name */
      case 257: /* tag_item ::= column_name */ yytestcase(yyruleno==257);
4406 4407
{ yylhsminor.yy752 = createColumnNode(pCxt, NULL, &yymsp[0].minor.yy849); }
  yymsp[0].minor.yy752 = yylhsminor.yy752;
4408
        break;
4409
      case 207: /* cmd ::= SHOW DNODES */
4410
{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_DNODES_STMT); }
4411
        break;
4412
      case 208: /* cmd ::= SHOW USERS */
4413
{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_USERS_STMT); }
4414
        break;
4415
      case 209: /* cmd ::= SHOW USER PRIVILEGES */
4416 4417
{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_USER_PRIVILEGES_STMT); }
        break;
4418
      case 210: /* cmd ::= SHOW DATABASES */
4419
{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_DATABASES_STMT); }
4420
        break;
4421
      case 211: /* cmd ::= SHOW db_name_cond_opt TABLES like_pattern_opt */
4422
{ pCxt->pRootNode = createShowStmtWithCond(pCxt, QUERY_NODE_SHOW_TABLES_STMT, yymsp[-2].minor.yy752, yymsp[0].minor.yy752, OP_TYPE_LIKE); }
4423
        break;
4424
      case 212: /* cmd ::= SHOW db_name_cond_opt STABLES like_pattern_opt */
4425
{ pCxt->pRootNode = createShowStmtWithCond(pCxt, QUERY_NODE_SHOW_STABLES_STMT, yymsp[-2].minor.yy752, yymsp[0].minor.yy752, OP_TYPE_LIKE); }
4426
        break;
4427
      case 213: /* cmd ::= SHOW db_name_cond_opt VGROUPS */
4428
{ pCxt->pRootNode = createShowStmtWithCond(pCxt, QUERY_NODE_SHOW_VGROUPS_STMT, yymsp[-1].minor.yy752, NULL, OP_TYPE_LIKE); }
4429
        break;
4430
      case 214: /* cmd ::= SHOW MNODES */
4431
{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_MNODES_STMT); }
4432
        break;
4433
      case 215: /* cmd ::= SHOW QNODES */
4434
{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_QNODES_STMT); }
4435
        break;
4436
      case 216: /* cmd ::= SHOW FUNCTIONS */
4437
{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_FUNCTIONS_STMT); }
4438
        break;
4439
      case 217: /* cmd ::= SHOW INDEXES FROM table_name_cond from_db_opt */
4440
{ pCxt->pRootNode = createShowStmtWithCond(pCxt, QUERY_NODE_SHOW_INDEXES_STMT, yymsp[0].minor.yy752, yymsp[-1].minor.yy752, OP_TYPE_EQUAL); }
4441
        break;
4442
      case 218: /* cmd ::= SHOW STREAMS */
4443
{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_STREAMS_STMT); }
4444
        break;
4445
      case 219: /* cmd ::= SHOW ACCOUNTS */
4446
{ pCxt->errCode = generateSyntaxErrMsg(&pCxt->msgBuf, TSDB_CODE_PAR_EXPRIE_STATEMENT); }
4447
        break;
4448
      case 220: /* cmd ::= SHOW APPS */
4449
{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_APPS_STMT); }
4450
        break;
4451
      case 221: /* cmd ::= SHOW CONNECTIONS */
4452
{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_CONNECTIONS_STMT); }
4453
        break;
4454 4455
      case 222: /* cmd ::= SHOW LICENCES */
      case 223: /* cmd ::= SHOW GRANTS */ yytestcase(yyruleno==223);
X
Xiaoyu Wang 已提交
4456
{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_LICENCES_STMT); }
4457
        break;
4458
      case 224: /* cmd ::= SHOW CREATE DATABASE db_name */
4459
{ pCxt->pRootNode = createShowCreateDatabaseStmt(pCxt, &yymsp[0].minor.yy849); }
4460
        break;
4461
      case 225: /* cmd ::= SHOW CREATE TABLE full_table_name */
4462
{ pCxt->pRootNode = createShowCreateTableStmt(pCxt, QUERY_NODE_SHOW_CREATE_TABLE_STMT, yymsp[0].minor.yy752); }
4463
        break;
4464
      case 226: /* cmd ::= SHOW CREATE STABLE full_table_name */
4465
{ pCxt->pRootNode = createShowCreateTableStmt(pCxt, QUERY_NODE_SHOW_CREATE_STABLE_STMT, yymsp[0].minor.yy752); }
4466
        break;
4467
      case 227: /* cmd ::= SHOW QUERIES */
4468
{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_QUERIES_STMT); }
4469
        break;
4470
      case 228: /* cmd ::= SHOW SCORES */
4471
{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_SCORES_STMT); }
4472
        break;
4473
      case 229: /* cmd ::= SHOW TOPICS */
4474
{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_TOPICS_STMT); }
4475
        break;
4476 4477
      case 230: /* cmd ::= SHOW VARIABLES */
      case 231: /* cmd ::= SHOW CLUSTER VARIABLES */ yytestcase(yyruleno==231);
4478
{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_VARIABLES_STMT); }
X
Xiaoyu Wang 已提交
4479
        break;
4480
      case 232: /* cmd ::= SHOW LOCAL VARIABLES */
4481 4482
{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_LOCAL_VARIABLES_STMT); }
        break;
4483
      case 233: /* cmd ::= SHOW DNODE NK_INTEGER VARIABLES like_pattern_opt */
4484
{ pCxt->pRootNode = createShowDnodeVariablesStmt(pCxt, createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[-2].minor.yy0), yymsp[0].minor.yy752); }
4485
        break;
4486
      case 234: /* cmd ::= SHOW BNODES */
4487
{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_BNODES_STMT); }
4488
        break;
4489
      case 235: /* cmd ::= SHOW SNODES */
4490
{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_SNODES_STMT); }
4491
        break;
4492
      case 236: /* cmd ::= SHOW CLUSTER */
4493
{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_CLUSTER_STMT); }
4494
        break;
4495
      case 237: /* cmd ::= SHOW TRANSACTIONS */
4496 4497
{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_TRANSACTIONS_STMT); }
        break;
4498
      case 238: /* cmd ::= SHOW TABLE DISTRIBUTED full_table_name */
4499
{ pCxt->pRootNode = createShowTableDistributedStmt(pCxt, yymsp[0].minor.yy752); }
X
Xiaoyu Wang 已提交
4500
        break;
4501
      case 239: /* cmd ::= SHOW CONSUMERS */
4502
{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_CONSUMERS_STMT); }
X
Xiaoyu Wang 已提交
4503
        break;
4504
      case 240: /* cmd ::= SHOW SUBSCRIPTIONS */
4505
{ pCxt->pRootNode = createShowStmt(pCxt, QUERY_NODE_SHOW_SUBSCRIPTIONS_STMT); }
X
Xiaoyu Wang 已提交
4506
        break;
4507
      case 241: /* cmd ::= SHOW TAGS FROM table_name_cond from_db_opt */
4508
{ pCxt->pRootNode = createShowStmtWithCond(pCxt, QUERY_NODE_SHOW_TAGS_STMT, yymsp[0].minor.yy752, yymsp[-1].minor.yy752, OP_TYPE_EQUAL); }
4509
        break;
4510
      case 242: /* cmd ::= SHOW TABLE TAGS tag_list_opt FROM table_name_cond from_db_opt */
4511
{ pCxt->pRootNode = createShowTableTagsStmt(pCxt, yymsp[-1].minor.yy752, yymsp[0].minor.yy752, yymsp[-3].minor.yy424); }
4512
        break;
4513
      case 243: /* cmd ::= SHOW VNODES NK_INTEGER */
4514 4515
{ pCxt->pRootNode = createShowVnodesStmt(pCxt, createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0), NULL); }
        break;
4516
      case 244: /* cmd ::= SHOW VNODES NK_STRING */
4517
{ pCxt->pRootNode = createShowVnodesStmt(pCxt, NULL, createValueNode(pCxt, TSDB_DATA_TYPE_VARCHAR, &yymsp[0].minor.yy0)); }
4518
        break;
4519 4520
      case 245: /* db_name_cond_opt ::= */
      case 250: /* from_db_opt ::= */ yytestcase(yyruleno==250);
4521
{ yymsp[1].minor.yy752 = createDefaultDatabaseCondValue(pCxt); }
4522
        break;
4523
      case 246: /* db_name_cond_opt ::= db_name NK_DOT */
4524 4525
{ yylhsminor.yy752 = createIdentifierValueNode(pCxt, &yymsp[-1].minor.yy849); }
  yymsp[-1].minor.yy752 = yylhsminor.yy752;
X
Xiaoyu Wang 已提交
4526
        break;
4527
      case 247: /* like_pattern_opt ::= */
4528 4529 4530 4531 4532 4533 4534 4535 4536 4537 4538 4539 4540
      case 307: /* subtable_opt ::= */ yytestcase(yyruleno==307);
      case 419: /* case_when_else_opt ::= */ yytestcase(yyruleno==419);
      case 449: /* from_clause_opt ::= */ yytestcase(yyruleno==449);
      case 478: /* where_clause_opt ::= */ yytestcase(yyruleno==478);
      case 487: /* twindow_clause_opt ::= */ yytestcase(yyruleno==487);
      case 493: /* sliding_opt ::= */ yytestcase(yyruleno==493);
      case 495: /* fill_opt ::= */ yytestcase(yyruleno==495);
      case 507: /* having_clause_opt ::= */ yytestcase(yyruleno==507);
      case 509: /* range_opt ::= */ yytestcase(yyruleno==509);
      case 511: /* every_opt ::= */ yytestcase(yyruleno==511);
      case 524: /* slimit_clause_opt ::= */ yytestcase(yyruleno==524);
      case 528: /* limit_clause_opt ::= */ yytestcase(yyruleno==528);
{ yymsp[1].minor.yy752 = NULL; }
X
Xiaoyu Wang 已提交
4541
        break;
4542
      case 248: /* like_pattern_opt ::= LIKE NK_STRING */
4543
{ yymsp[-1].minor.yy752 = createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0); }
X
Xiaoyu Wang 已提交
4544
        break;
4545
      case 249: /* table_name_cond ::= table_name */
4546 4547
{ yylhsminor.yy752 = createIdentifierValueNode(pCxt, &yymsp[0].minor.yy849); }
  yymsp[0].minor.yy752 = yylhsminor.yy752;
X
Xiaoyu Wang 已提交
4548
        break;
4549
      case 251: /* from_db_opt ::= FROM db_name */
4550
{ yymsp[-1].minor.yy752 = createIdentifierValueNode(pCxt, &yymsp[0].minor.yy849); }
X
Xiaoyu Wang 已提交
4551
        break;
4552
      case 255: /* tag_item ::= TBNAME */
4553 4554
{ yylhsminor.yy752 = setProjectionAlias(pCxt, createFunctionNode(pCxt, &yymsp[0].minor.yy0, NULL), &yymsp[0].minor.yy0); }
  yymsp[0].minor.yy752 = yylhsminor.yy752;
4555
        break;
4556
      case 258: /* tag_item ::= column_name column_alias */
4557 4558
{ yylhsminor.yy752 = setProjectionAlias(pCxt, createColumnNode(pCxt, NULL, &yymsp[-1].minor.yy849), &yymsp[0].minor.yy849); }
  yymsp[-1].minor.yy752 = yylhsminor.yy752;
4559
        break;
4560
      case 259: /* tag_item ::= column_name AS column_alias */
4561 4562
{ yylhsminor.yy752 = setProjectionAlias(pCxt, createColumnNode(pCxt, NULL, &yymsp[-2].minor.yy849), &yymsp[0].minor.yy849); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
4563
        break;
4564
      case 260: /* cmd ::= CREATE SMA INDEX not_exists_opt full_table_name ON full_table_name index_options */
4565
{ pCxt->pRootNode = createCreateIndexStmt(pCxt, INDEX_TYPE_SMA, yymsp[-4].minor.yy57, yymsp[-3].minor.yy752, yymsp[-1].minor.yy752, NULL, yymsp[0].minor.yy752); }
X
Xiaoyu Wang 已提交
4566
        break;
4567
      case 261: /* cmd ::= DROP INDEX exists_opt full_table_name */
4568
{ pCxt->pRootNode = createDropIndexStmt(pCxt, yymsp[-1].minor.yy57, yymsp[0].minor.yy752); }
X
Xiaoyu Wang 已提交
4569
        break;
4570
      case 262: /* index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_RP sliding_opt sma_stream_opt */
4571
{ yymsp[-9].minor.yy752 = createIndexOption(pCxt, yymsp[-7].minor.yy424, releaseRawExprNode(pCxt, yymsp[-3].minor.yy752), NULL, yymsp[-1].minor.yy752, yymsp[0].minor.yy752); }
X
Xiaoyu Wang 已提交
4572
        break;
4573
      case 263: /* index_options ::= FUNCTION NK_LP func_list NK_RP INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt sma_stream_opt */
4574
{ yymsp[-11].minor.yy752 = createIndexOption(pCxt, yymsp[-9].minor.yy424, releaseRawExprNode(pCxt, yymsp[-5].minor.yy752), releaseRawExprNode(pCxt, yymsp[-3].minor.yy752), yymsp[-1].minor.yy752, yymsp[0].minor.yy752); }
X
Xiaoyu Wang 已提交
4575
        break;
4576 4577 4578
      case 266: /* func ::= sma_func_name NK_LP expression_list NK_RP */
{ yylhsminor.yy752 = createFunctionNode(pCxt, &yymsp[-3].minor.yy849, yymsp[-1].minor.yy424); }
  yymsp[-3].minor.yy752 = yylhsminor.yy752;
4579
        break;
4580 4581 4582
      case 272: /* sma_stream_opt ::= */
      case 300: /* stream_options ::= */ yytestcase(yyruleno==300);
{ yymsp[1].minor.yy752 = createStreamOptions(pCxt); }
4583
        break;
4584 4585 4586 4587
      case 273: /* sma_stream_opt ::= sma_stream_opt WATERMARK duration_literal */
      case 304: /* stream_options ::= stream_options WATERMARK duration_literal */ yytestcase(yyruleno==304);
{ ((SStreamOptions*)yymsp[-2].minor.yy752)->pWatermark = releaseRawExprNode(pCxt, yymsp[0].minor.yy752); yylhsminor.yy752 = yymsp[-2].minor.yy752; }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
X
Xiaoyu Wang 已提交
4588
        break;
4589 4590 4591
      case 274: /* sma_stream_opt ::= sma_stream_opt MAX_DELAY duration_literal */
{ ((SStreamOptions*)yymsp[-2].minor.yy752)->pDelay = releaseRawExprNode(pCxt, yymsp[0].minor.yy752); yylhsminor.yy752 = yymsp[-2].minor.yy752; }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
X
Xiaoyu Wang 已提交
4592
        break;
4593 4594 4595
      case 275: /* sma_stream_opt ::= sma_stream_opt DELETE_MARK duration_literal */
{ ((SStreamOptions*)yymsp[-2].minor.yy752)->pDeleteMark = releaseRawExprNode(pCxt, yymsp[0].minor.yy752); yylhsminor.yy752 = yymsp[-2].minor.yy752; }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
X
Xiaoyu Wang 已提交
4596
        break;
4597 4598
      case 276: /* cmd ::= CREATE TOPIC not_exists_opt topic_name AS query_or_subquery */
{ pCxt->pRootNode = createCreateTopicStmtUseQuery(pCxt, yymsp[-3].minor.yy57, &yymsp[-2].minor.yy849, yymsp[0].minor.yy752); }
X
Xiaoyu Wang 已提交
4599
        break;
4600 4601
      case 277: /* cmd ::= CREATE TOPIC not_exists_opt topic_name AS DATABASE db_name */
{ pCxt->pRootNode = createCreateTopicStmtUseDb(pCxt, yymsp[-4].minor.yy57, &yymsp[-3].minor.yy849, &yymsp[0].minor.yy849, false); }
4602
        break;
4603 4604
      case 278: /* cmd ::= CREATE TOPIC not_exists_opt topic_name WITH META AS DATABASE db_name */
{ pCxt->pRootNode = createCreateTopicStmtUseDb(pCxt, yymsp[-6].minor.yy57, &yymsp[-5].minor.yy849, &yymsp[0].minor.yy849, true); }
X
Xiaoyu Wang 已提交
4605
        break;
4606 4607
      case 279: /* cmd ::= CREATE TOPIC not_exists_opt topic_name AS STABLE full_table_name */
{ pCxt->pRootNode = createCreateTopicStmtUseTable(pCxt, yymsp[-4].minor.yy57, &yymsp[-3].minor.yy849, yymsp[0].minor.yy752, false); }
4608
        break;
4609 4610
      case 280: /* cmd ::= CREATE TOPIC not_exists_opt topic_name WITH META AS STABLE full_table_name */
{ pCxt->pRootNode = createCreateTopicStmtUseTable(pCxt, yymsp[-6].minor.yy57, &yymsp[-5].minor.yy849, yymsp[0].minor.yy752, true); }
4611
        break;
4612 4613
      case 281: /* cmd ::= DROP TOPIC exists_opt topic_name */
{ pCxt->pRootNode = createDropTopicStmt(pCxt, yymsp[-1].minor.yy57, &yymsp[0].minor.yy849); }
4614
        break;
4615 4616
      case 282: /* cmd ::= DROP CONSUMER GROUP exists_opt cgroup_name ON topic_name */
{ pCxt->pRootNode = createDropCGroupStmt(pCxt, yymsp[-3].minor.yy57, &yymsp[-2].minor.yy849, &yymsp[0].minor.yy849); }
4617
        break;
4618 4619 4620
      case 283: /* cmd ::= DESC full_table_name */
      case 284: /* cmd ::= DESCRIBE full_table_name */ yytestcase(yyruleno==284);
{ pCxt->pRootNode = createDescribeStmt(pCxt, yymsp[0].minor.yy752); }
4621
        break;
4622
      case 285: /* cmd ::= RESET QUERY CACHE */
4623
{ pCxt->pRootNode = createResetQueryCacheStmt(pCxt); }
4624
        break;
4625 4626
      case 286: /* cmd ::= EXPLAIN analyze_opt explain_options query_or_subquery */
{ pCxt->pRootNode = createExplainStmt(pCxt, yymsp[-2].minor.yy57, yymsp[-1].minor.yy752, yymsp[0].minor.yy752); }
4627
        break;
4628 4629
      case 289: /* explain_options ::= */
{ yymsp[1].minor.yy752 = createDefaultExplainOptions(pCxt); }
4630
        break;
4631 4632 4633
      case 290: /* explain_options ::= explain_options VERBOSE NK_BOOL */
{ yylhsminor.yy752 = setExplainVerbose(pCxt, yymsp[-2].minor.yy752, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
4634
        break;
4635 4636 4637
      case 291: /* explain_options ::= explain_options RATIO NK_FLOAT */
{ yylhsminor.yy752 = setExplainRatio(pCxt, yymsp[-2].minor.yy752, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
4638
        break;
4639 4640
      case 292: /* cmd ::= CREATE agg_func_opt FUNCTION not_exists_opt function_name AS NK_STRING OUTPUTTYPE type_name bufsize_opt */
{ pCxt->pRootNode = createCreateFunctionStmt(pCxt, yymsp[-6].minor.yy57, yymsp[-8].minor.yy57, &yymsp[-5].minor.yy849, &yymsp[-3].minor.yy0, yymsp[-1].minor.yy384, yymsp[0].minor.yy340); }
4641
        break;
4642 4643
      case 293: /* cmd ::= DROP FUNCTION exists_opt function_name */
{ pCxt->pRootNode = createDropFunctionStmt(pCxt, yymsp[-1].minor.yy57, &yymsp[0].minor.yy849); }
4644
        break;
4645 4646
      case 298: /* cmd ::= CREATE STREAM not_exists_opt stream_name stream_options INTO full_table_name tags_def_opt subtable_opt AS query_or_subquery */
{ pCxt->pRootNode = createCreateStreamStmt(pCxt, yymsp[-8].minor.yy57, &yymsp[-7].minor.yy849, yymsp[-4].minor.yy752, yymsp[-6].minor.yy752, yymsp[-3].minor.yy424, yymsp[-2].minor.yy752, yymsp[0].minor.yy752); }
4647
        break;
4648 4649
      case 299: /* cmd ::= DROP STREAM exists_opt stream_name */
{ pCxt->pRootNode = createDropStreamStmt(pCxt, yymsp[-1].minor.yy57, &yymsp[0].minor.yy849); }
4650
        break;
4651 4652 4653
      case 301: /* stream_options ::= stream_options TRIGGER AT_ONCE */
{ ((SStreamOptions*)yymsp[-2].minor.yy752)->triggerType = STREAM_TRIGGER_AT_ONCE; yylhsminor.yy752 = yymsp[-2].minor.yy752; }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
4654
        break;
4655 4656 4657
      case 302: /* stream_options ::= stream_options TRIGGER WINDOW_CLOSE */
{ ((SStreamOptions*)yymsp[-2].minor.yy752)->triggerType = STREAM_TRIGGER_WINDOW_CLOSE; yylhsminor.yy752 = yymsp[-2].minor.yy752; }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
4658
        break;
4659 4660 4661
      case 303: /* stream_options ::= stream_options TRIGGER MAX_DELAY duration_literal */
{ ((SStreamOptions*)yymsp[-3].minor.yy752)->triggerType = STREAM_TRIGGER_MAX_DELAY; ((SStreamOptions*)yymsp[-3].minor.yy752)->pDelay = releaseRawExprNode(pCxt, yymsp[0].minor.yy752); yylhsminor.yy752 = yymsp[-3].minor.yy752; }
  yymsp[-3].minor.yy752 = yylhsminor.yy752;
4662
        break;
4663 4664 4665
      case 305: /* stream_options ::= stream_options IGNORE EXPIRED NK_INTEGER */
{ ((SStreamOptions*)yymsp[-3].minor.yy752)->ignoreExpired = taosStr2Int8(yymsp[0].minor.yy0.z, NULL, 10); yylhsminor.yy752 = yymsp[-3].minor.yy752; }
  yymsp[-3].minor.yy752 = yylhsminor.yy752;
4666
        break;
4667 4668 4669
      case 306: /* stream_options ::= stream_options FILL_HISTORY NK_INTEGER */
{ ((SStreamOptions*)yymsp[-2].minor.yy752)->fillHistory = taosStr2Int8(yymsp[0].minor.yy0.z, NULL, 10); yylhsminor.yy752 = yymsp[-2].minor.yy752; }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
4670
        break;
4671 4672 4673 4674
      case 308: /* subtable_opt ::= SUBTABLE NK_LP expression NK_RP */
      case 494: /* sliding_opt ::= SLIDING NK_LP duration_literal NK_RP */ yytestcase(yyruleno==494);
      case 512: /* every_opt ::= EVERY NK_LP duration_literal NK_RP */ yytestcase(yyruleno==512);
{ yymsp[-3].minor.yy752 = releaseRawExprNode(pCxt, yymsp[-1].minor.yy752); }
4675
        break;
4676
      case 309: /* cmd ::= KILL CONNECTION NK_INTEGER */
4677 4678
{ pCxt->pRootNode = createKillStmt(pCxt, QUERY_NODE_KILL_CONNECTION_STMT, &yymsp[0].minor.yy0); }
        break;
4679
      case 310: /* cmd ::= KILL QUERY NK_STRING */
X
Xiaoyu Wang 已提交
4680
{ pCxt->pRootNode = createKillQueryStmt(pCxt, &yymsp[0].minor.yy0); }
4681
        break;
4682
      case 311: /* cmd ::= KILL TRANSACTION NK_INTEGER */
4683 4684
{ pCxt->pRootNode = createKillStmt(pCxt, QUERY_NODE_KILL_TRANSACTION_STMT, &yymsp[0].minor.yy0); }
        break;
4685
      case 312: /* cmd ::= BALANCE VGROUP */
X
Xiaoyu Wang 已提交
4686 4687
{ pCxt->pRootNode = createBalanceVgroupStmt(pCxt); }
        break;
4688
      case 313: /* cmd ::= MERGE VGROUP NK_INTEGER NK_INTEGER */
4689 4690
{ pCxt->pRootNode = createMergeVgroupStmt(pCxt, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0); }
        break;
4691 4692
      case 314: /* cmd ::= REDISTRIBUTE VGROUP NK_INTEGER dnode_list */
{ pCxt->pRootNode = createRedistributeVgroupStmt(pCxt, &yymsp[-1].minor.yy0, yymsp[0].minor.yy424); }
4693
        break;
4694
      case 315: /* cmd ::= SPLIT VGROUP NK_INTEGER */
4695 4696
{ pCxt->pRootNode = createSplitVgroupStmt(pCxt, &yymsp[0].minor.yy0); }
        break;
4697 4698 4699 4700 4701 4702 4703 4704 4705 4706 4707 4708 4709 4710 4711 4712 4713 4714 4715 4716 4717 4718 4719 4720 4721 4722 4723 4724 4725 4726 4727 4728 4729 4730 4731 4732 4733 4734 4735 4736 4737 4738 4739 4740 4741 4742 4743 4744 4745 4746 4747 4748 4749 4750 4751 4752 4753 4754 4755 4756 4757 4758 4759 4760 4761 4762 4763 4764 4765 4766 4767 4768 4769 4770 4771 4772
      case 316: /* dnode_list ::= DNODE NK_INTEGER */
{ yymsp[-1].minor.yy424 = createNodeList(pCxt, createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &yymsp[0].minor.yy0)); }
        break;
      case 318: /* cmd ::= DELETE FROM full_table_name where_clause_opt */
{ pCxt->pRootNode = createDeleteStmt(pCxt, yymsp[-1].minor.yy752, yymsp[0].minor.yy752); }
        break;
      case 320: /* cmd ::= INSERT INTO full_table_name NK_LP col_name_list NK_RP query_or_subquery */
{ pCxt->pRootNode = createInsertStmt(pCxt, yymsp[-4].minor.yy752, yymsp[-2].minor.yy424, yymsp[0].minor.yy752); }
        break;
      case 321: /* cmd ::= INSERT INTO full_table_name query_or_subquery */
{ pCxt->pRootNode = createInsertStmt(pCxt, yymsp[-1].minor.yy752, NULL, yymsp[0].minor.yy752); }
        break;
      case 322: /* literal ::= NK_INTEGER */
{ yylhsminor.yy752 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_UBIGINT, &yymsp[0].minor.yy0)); }
  yymsp[0].minor.yy752 = yylhsminor.yy752;
        break;
      case 323: /* literal ::= NK_FLOAT */
{ yylhsminor.yy752 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &yymsp[0].minor.yy0)); }
  yymsp[0].minor.yy752 = yylhsminor.yy752;
        break;
      case 324: /* literal ::= NK_STRING */
{ yylhsminor.yy752 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0)); }
  yymsp[0].minor.yy752 = yylhsminor.yy752;
        break;
      case 325: /* literal ::= NK_BOOL */
{ yylhsminor.yy752 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_BOOL, &yymsp[0].minor.yy0)); }
  yymsp[0].minor.yy752 = yylhsminor.yy752;
        break;
      case 326: /* literal ::= TIMESTAMP NK_STRING */
{ yylhsminor.yy752 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_TIMESTAMP, &yymsp[0].minor.yy0)); }
  yymsp[-1].minor.yy752 = yylhsminor.yy752;
        break;
      case 327: /* literal ::= duration_literal */
      case 337: /* signed_literal ::= signed */ yytestcase(yyruleno==337);
      case 357: /* expr_or_subquery ::= expression */ yytestcase(yyruleno==357);
      case 358: /* expression ::= literal */ yytestcase(yyruleno==358);
      case 359: /* expression ::= pseudo_column */ yytestcase(yyruleno==359);
      case 360: /* expression ::= column_reference */ yytestcase(yyruleno==360);
      case 361: /* expression ::= function_expression */ yytestcase(yyruleno==361);
      case 362: /* expression ::= case_when_expression */ yytestcase(yyruleno==362);
      case 392: /* function_expression ::= literal_func */ yytestcase(yyruleno==392);
      case 441: /* boolean_value_expression ::= boolean_primary */ yytestcase(yyruleno==441);
      case 445: /* boolean_primary ::= predicate */ yytestcase(yyruleno==445);
      case 447: /* common_expression ::= expr_or_subquery */ yytestcase(yyruleno==447);
      case 448: /* common_expression ::= boolean_value_expression */ yytestcase(yyruleno==448);
      case 451: /* table_reference_list ::= table_reference */ yytestcase(yyruleno==451);
      case 453: /* table_reference ::= table_primary */ yytestcase(yyruleno==453);
      case 454: /* table_reference ::= joined_table */ yytestcase(yyruleno==454);
      case 458: /* table_primary ::= parenthesized_joined_table */ yytestcase(yyruleno==458);
      case 514: /* query_simple ::= query_specification */ yytestcase(yyruleno==514);
      case 515: /* query_simple ::= union_query_expression */ yytestcase(yyruleno==515);
      case 518: /* query_simple_or_subquery ::= query_simple */ yytestcase(yyruleno==518);
      case 520: /* query_or_subquery ::= query_expression */ yytestcase(yyruleno==520);
{ yylhsminor.yy752 = yymsp[0].minor.yy752; }
  yymsp[0].minor.yy752 = yylhsminor.yy752;
        break;
      case 328: /* literal ::= NULL */
{ yylhsminor.yy752 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createValueNode(pCxt, TSDB_DATA_TYPE_NULL, &yymsp[0].minor.yy0)); }
  yymsp[0].minor.yy752 = yylhsminor.yy752;
        break;
      case 329: /* literal ::= NK_QUESTION */
{ yylhsminor.yy752 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createPlaceholderValueNode(pCxt, &yymsp[0].minor.yy0)); }
  yymsp[0].minor.yy752 = yylhsminor.yy752;
        break;
      case 330: /* duration_literal ::= NK_VARIABLE */
{ yylhsminor.yy752 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createDurationValueNode(pCxt, &yymsp[0].minor.yy0)); }
  yymsp[0].minor.yy752 = yylhsminor.yy752;
        break;
      case 331: /* signed ::= NK_INTEGER */
{ yylhsminor.yy752 = createValueNode(pCxt, TSDB_DATA_TYPE_UBIGINT, &yymsp[0].minor.yy0); }
  yymsp[0].minor.yy752 = yylhsminor.yy752;
        break;
      case 332: /* signed ::= NK_PLUS NK_INTEGER */
{ yymsp[-1].minor.yy752 = createValueNode(pCxt, TSDB_DATA_TYPE_UBIGINT, &yymsp[0].minor.yy0); }
        break;
      case 333: /* signed ::= NK_MINUS NK_INTEGER */
X
Xiaoyu Wang 已提交
4773 4774 4775
{ 
                                                                                    SToken t = yymsp[-1].minor.yy0;
                                                                                    t.n = (yymsp[0].minor.yy0.z + yymsp[0].minor.yy0.n) - yymsp[-1].minor.yy0.z;
4776
                                                                                    yylhsminor.yy752 = createValueNode(pCxt, TSDB_DATA_TYPE_BIGINT, &t);
X
Xiaoyu Wang 已提交
4777
                                                                                  }
4778
  yymsp[-1].minor.yy752 = yylhsminor.yy752;
X
Xiaoyu Wang 已提交
4779
        break;
4780 4781 4782
      case 334: /* signed ::= NK_FLOAT */
{ yylhsminor.yy752 = createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &yymsp[0].minor.yy0); }
  yymsp[0].minor.yy752 = yylhsminor.yy752;
X
Xiaoyu Wang 已提交
4783
        break;
4784 4785
      case 335: /* signed ::= NK_PLUS NK_FLOAT */
{ yymsp[-1].minor.yy752 = createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &yymsp[0].minor.yy0); }
X
Xiaoyu Wang 已提交
4786
        break;
4787
      case 336: /* signed ::= NK_MINUS NK_FLOAT */
X
Xiaoyu Wang 已提交
4788 4789 4790
{ 
                                                                                    SToken t = yymsp[-1].minor.yy0;
                                                                                    t.n = (yymsp[0].minor.yy0.z + yymsp[0].minor.yy0.n) - yymsp[-1].minor.yy0.z;
4791
                                                                                    yylhsminor.yy752 = createValueNode(pCxt, TSDB_DATA_TYPE_DOUBLE, &t);
X
Xiaoyu Wang 已提交
4792
                                                                                  }
4793 4794 4795 4796 4797 4798 4799 4800 4801 4802 4803 4804 4805 4806 4807 4808 4809 4810 4811 4812 4813 4814 4815 4816 4817 4818 4819 4820 4821 4822 4823 4824 4825 4826 4827 4828 4829 4830 4831
  yymsp[-1].minor.yy752 = yylhsminor.yy752;
        break;
      case 338: /* signed_literal ::= NK_STRING */
{ yylhsminor.yy752 = createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0); }
  yymsp[0].minor.yy752 = yylhsminor.yy752;
        break;
      case 339: /* signed_literal ::= NK_BOOL */
{ yylhsminor.yy752 = createValueNode(pCxt, TSDB_DATA_TYPE_BOOL, &yymsp[0].minor.yy0); }
  yymsp[0].minor.yy752 = yylhsminor.yy752;
        break;
      case 340: /* signed_literal ::= TIMESTAMP NK_STRING */
{ yymsp[-1].minor.yy752 = createValueNode(pCxt, TSDB_DATA_TYPE_TIMESTAMP, &yymsp[0].minor.yy0); }
        break;
      case 341: /* signed_literal ::= duration_literal */
      case 343: /* signed_literal ::= literal_func */ yytestcase(yyruleno==343);
      case 412: /* star_func_para ::= expr_or_subquery */ yytestcase(yyruleno==412);
      case 474: /* select_item ::= common_expression */ yytestcase(yyruleno==474);
      case 484: /* partition_item ::= expr_or_subquery */ yytestcase(yyruleno==484);
      case 519: /* query_simple_or_subquery ::= subquery */ yytestcase(yyruleno==519);
      case 521: /* query_or_subquery ::= subquery */ yytestcase(yyruleno==521);
      case 534: /* search_condition ::= common_expression */ yytestcase(yyruleno==534);
{ yylhsminor.yy752 = releaseRawExprNode(pCxt, yymsp[0].minor.yy752); }
  yymsp[0].minor.yy752 = yylhsminor.yy752;
        break;
      case 342: /* signed_literal ::= NULL */
{ yylhsminor.yy752 = createValueNode(pCxt, TSDB_DATA_TYPE_NULL, &yymsp[0].minor.yy0); }
  yymsp[0].minor.yy752 = yylhsminor.yy752;
        break;
      case 344: /* signed_literal ::= NK_QUESTION */
{ yylhsminor.yy752 = createPlaceholderValueNode(pCxt, &yymsp[0].minor.yy0); }
  yymsp[0].minor.yy752 = yylhsminor.yy752;
        break;
      case 363: /* expression ::= NK_LP expression NK_RP */
      case 446: /* boolean_primary ::= NK_LP boolean_value_expression NK_RP */ yytestcase(yyruleno==446);
      case 533: /* subquery ::= NK_LP subquery NK_RP */ yytestcase(yyruleno==533);
{ yylhsminor.yy752 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0, releaseRawExprNode(pCxt, yymsp[-1].minor.yy752)); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
        break;
      case 364: /* expression ::= NK_PLUS expr_or_subquery */
X
Xiaoyu Wang 已提交
4832
{
4833 4834
                                                                                    SToken t = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy752);
                                                                                    yylhsminor.yy752 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &t, releaseRawExprNode(pCxt, yymsp[0].minor.yy752));
X
Xiaoyu Wang 已提交
4835
                                                                                  }
4836
  yymsp[-1].minor.yy752 = yylhsminor.yy752;
X
Xiaoyu Wang 已提交
4837
        break;
4838
      case 365: /* expression ::= NK_MINUS expr_or_subquery */
X
Xiaoyu Wang 已提交
4839
{
4840 4841
                                                                                    SToken t = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy752);
                                                                                    yylhsminor.yy752 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &t, createOperatorNode(pCxt, OP_TYPE_MINUS, releaseRawExprNode(pCxt, yymsp[0].minor.yy752), NULL));
X
Xiaoyu Wang 已提交
4842
                                                                                  }
4843
  yymsp[-1].minor.yy752 = yylhsminor.yy752;
4844
        break;
4845
      case 366: /* expression ::= expr_or_subquery NK_PLUS expr_or_subquery */
4846
{
4847 4848 4849
                                                                                    SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy752);
                                                                                    SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy752);
                                                                                    yylhsminor.yy752 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_ADD, releaseRawExprNode(pCxt, yymsp[-2].minor.yy752), releaseRawExprNode(pCxt, yymsp[0].minor.yy752))); 
4850
                                                                                  }
4851
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
X
Xiaoyu Wang 已提交
4852
        break;
4853
      case 367: /* expression ::= expr_or_subquery NK_MINUS expr_or_subquery */
4854
{
4855 4856 4857
                                                                                    SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy752);
                                                                                    SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy752);
                                                                                    yylhsminor.yy752 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_SUB, releaseRawExprNode(pCxt, yymsp[-2].minor.yy752), releaseRawExprNode(pCxt, yymsp[0].minor.yy752))); 
4858
                                                                                  }
4859
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
4860
        break;
4861
      case 368: /* expression ::= expr_or_subquery NK_STAR expr_or_subquery */
4862
{
4863 4864 4865
                                                                                    SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy752);
                                                                                    SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy752);
                                                                                    yylhsminor.yy752 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_MULTI, releaseRawExprNode(pCxt, yymsp[-2].minor.yy752), releaseRawExprNode(pCxt, yymsp[0].minor.yy752))); 
4866
                                                                                  }
4867
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
4868
        break;
4869
      case 369: /* expression ::= expr_or_subquery NK_SLASH expr_or_subquery */
4870
{
4871 4872 4873
                                                                                    SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy752);
                                                                                    SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy752);
                                                                                    yylhsminor.yy752 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_DIV, releaseRawExprNode(pCxt, yymsp[-2].minor.yy752), releaseRawExprNode(pCxt, yymsp[0].minor.yy752))); 
4874
                                                                                  }
4875
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
4876
        break;
4877
      case 370: /* expression ::= expr_or_subquery NK_REM expr_or_subquery */
4878
{
4879 4880 4881
                                                                                    SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy752);
                                                                                    SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy752);
                                                                                    yylhsminor.yy752 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_REM, releaseRawExprNode(pCxt, yymsp[-2].minor.yy752), releaseRawExprNode(pCxt, yymsp[0].minor.yy752)));
4882
                                                                                  }
4883
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
4884
        break;
4885
      case 371: /* expression ::= column_reference NK_ARROW NK_STRING */
4886
{
4887 4888
                                                                                    SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy752);
                                                                                    yylhsminor.yy752 = createRawExprNodeExt(pCxt, &s, &yymsp[0].minor.yy0, createOperatorNode(pCxt, OP_TYPE_JSON_GET_VALUE, releaseRawExprNode(pCxt, yymsp[-2].minor.yy752), createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[0].minor.yy0))); 
4889
                                                                                  }
4890
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
4891
        break;
4892
      case 372: /* expression ::= expr_or_subquery NK_BITAND expr_or_subquery */
4893
{
4894 4895 4896
                                                                                    SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy752);
                                                                                    SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy752);
                                                                                    yylhsminor.yy752 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_BIT_AND, releaseRawExprNode(pCxt, yymsp[-2].minor.yy752), releaseRawExprNode(pCxt, yymsp[0].minor.yy752)));
4897
                                                                                  }
4898
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
4899
        break;
4900
      case 373: /* expression ::= expr_or_subquery NK_BITOR expr_or_subquery */
4901
{
4902 4903 4904
                                                                                    SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy752);
                                                                                    SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy752);
                                                                                    yylhsminor.yy752 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, OP_TYPE_BIT_OR, releaseRawExprNode(pCxt, yymsp[-2].minor.yy752), releaseRawExprNode(pCxt, yymsp[0].minor.yy752)));
4905
                                                                                  }
4906 4907 4908 4909 4910 4911 4912 4913 4914 4915 4916 4917 4918 4919 4920 4921 4922 4923 4924 4925 4926 4927 4928 4929 4930 4931 4932 4933 4934 4935 4936 4937 4938 4939 4940 4941 4942 4943 4944 4945 4946 4947 4948 4949 4950 4951 4952 4953 4954 4955 4956 4957 4958 4959 4960 4961 4962 4963 4964 4965 4966 4967 4968 4969 4970 4971
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
        break;
      case 376: /* column_reference ::= column_name */
{ yylhsminor.yy752 = createRawExprNode(pCxt, &yymsp[0].minor.yy849, createColumnNode(pCxt, NULL, &yymsp[0].minor.yy849)); }
  yymsp[0].minor.yy752 = yylhsminor.yy752;
        break;
      case 377: /* column_reference ::= table_name NK_DOT column_name */
{ yylhsminor.yy752 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy849, &yymsp[0].minor.yy849, createColumnNode(pCxt, &yymsp[-2].minor.yy849, &yymsp[0].minor.yy849)); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
        break;
      case 378: /* pseudo_column ::= ROWTS */
      case 379: /* pseudo_column ::= TBNAME */ yytestcase(yyruleno==379);
      case 381: /* pseudo_column ::= QSTART */ yytestcase(yyruleno==381);
      case 382: /* pseudo_column ::= QEND */ yytestcase(yyruleno==382);
      case 383: /* pseudo_column ::= QDURATION */ yytestcase(yyruleno==383);
      case 384: /* pseudo_column ::= WSTART */ yytestcase(yyruleno==384);
      case 385: /* pseudo_column ::= WEND */ yytestcase(yyruleno==385);
      case 386: /* pseudo_column ::= WDURATION */ yytestcase(yyruleno==386);
      case 387: /* pseudo_column ::= IROWTS */ yytestcase(yyruleno==387);
      case 388: /* pseudo_column ::= QTAGS */ yytestcase(yyruleno==388);
      case 394: /* literal_func ::= NOW */ yytestcase(yyruleno==394);
{ yylhsminor.yy752 = createRawExprNode(pCxt, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[0].minor.yy0, NULL)); }
  yymsp[0].minor.yy752 = yylhsminor.yy752;
        break;
      case 380: /* pseudo_column ::= table_name NK_DOT TBNAME */
{ yylhsminor.yy752 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy849, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[0].minor.yy0, createNodeList(pCxt, createValueNode(pCxt, TSDB_DATA_TYPE_BINARY, &yymsp[-2].minor.yy849)))); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
        break;
      case 389: /* function_expression ::= function_name NK_LP expression_list NK_RP */
      case 390: /* function_expression ::= star_func NK_LP star_func_para_list NK_RP */ yytestcase(yyruleno==390);
{ yylhsminor.yy752 = createRawExprNodeExt(pCxt, &yymsp[-3].minor.yy849, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[-3].minor.yy849, yymsp[-1].minor.yy424)); }
  yymsp[-3].minor.yy752 = yylhsminor.yy752;
        break;
      case 391: /* function_expression ::= CAST NK_LP expr_or_subquery AS type_name NK_RP */
{ yylhsminor.yy752 = createRawExprNodeExt(pCxt, &yymsp[-5].minor.yy0, &yymsp[0].minor.yy0, createCastFunctionNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy752), yymsp[-1].minor.yy384)); }
  yymsp[-5].minor.yy752 = yylhsminor.yy752;
        break;
      case 393: /* literal_func ::= noarg_func NK_LP NK_RP */
{ yylhsminor.yy752 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy849, &yymsp[0].minor.yy0, createFunctionNode(pCxt, &yymsp[-2].minor.yy849, NULL)); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
        break;
      case 408: /* star_func_para_list ::= NK_STAR */
{ yylhsminor.yy424 = createNodeList(pCxt, createColumnNode(pCxt, NULL, &yymsp[0].minor.yy0)); }
  yymsp[0].minor.yy424 = yylhsminor.yy424;
        break;
      case 413: /* star_func_para ::= table_name NK_DOT NK_STAR */
      case 477: /* select_item ::= table_name NK_DOT NK_STAR */ yytestcase(yyruleno==477);
{ yylhsminor.yy752 = createColumnNode(pCxt, &yymsp[-2].minor.yy849, &yymsp[0].minor.yy0); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
        break;
      case 414: /* case_when_expression ::= CASE when_then_list case_when_else_opt END */
{ yylhsminor.yy752 = createRawExprNodeExt(pCxt, &yymsp[-3].minor.yy0, &yymsp[0].minor.yy0, createCaseWhenNode(pCxt, NULL, yymsp[-2].minor.yy424, yymsp[-1].minor.yy752)); }
  yymsp[-3].minor.yy752 = yylhsminor.yy752;
        break;
      case 415: /* case_when_expression ::= CASE common_expression when_then_list case_when_else_opt END */
{ yylhsminor.yy752 = createRawExprNodeExt(pCxt, &yymsp[-4].minor.yy0, &yymsp[0].minor.yy0, createCaseWhenNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy752), yymsp[-2].minor.yy424, yymsp[-1].minor.yy752)); }
  yymsp[-4].minor.yy752 = yylhsminor.yy752;
        break;
      case 418: /* when_then_expr ::= WHEN common_expression THEN common_expression */
{ yymsp[-3].minor.yy752 = createWhenThenNode(pCxt, releaseRawExprNode(pCxt, yymsp[-2].minor.yy752), releaseRawExprNode(pCxt, yymsp[0].minor.yy752)); }
        break;
      case 420: /* case_when_else_opt ::= ELSE common_expression */
{ yymsp[-1].minor.yy752 = releaseRawExprNode(pCxt, yymsp[0].minor.yy752); }
        break;
      case 421: /* predicate ::= expr_or_subquery compare_op expr_or_subquery */
      case 426: /* predicate ::= expr_or_subquery in_op in_predicate_value */ yytestcase(yyruleno==426);
4972
{
4973 4974 4975
                                                                                    SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy752);
                                                                                    SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy752);
                                                                                    yylhsminor.yy752 = createRawExprNodeExt(pCxt, &s, &e, createOperatorNode(pCxt, yymsp[-1].minor.yy620, releaseRawExprNode(pCxt, yymsp[-2].minor.yy752), releaseRawExprNode(pCxt, yymsp[0].minor.yy752)));
4976
                                                                                  }
4977
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
4978
        break;
4979
      case 422: /* predicate ::= expr_or_subquery BETWEEN expr_or_subquery AND expr_or_subquery */
4980
{
4981 4982 4983
                                                                                    SToken s = getTokenFromRawExprNode(pCxt, yymsp[-4].minor.yy752);
                                                                                    SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy752);
                                                                                    yylhsminor.yy752 = createRawExprNodeExt(pCxt, &s, &e, createBetweenAnd(pCxt, releaseRawExprNode(pCxt, yymsp[-4].minor.yy752), releaseRawExprNode(pCxt, yymsp[-2].minor.yy752), releaseRawExprNode(pCxt, yymsp[0].minor.yy752)));
4984
                                                                                  }
4985
  yymsp[-4].minor.yy752 = yylhsminor.yy752;
4986
        break;
4987
      case 423: /* predicate ::= expr_or_subquery NOT BETWEEN expr_or_subquery AND expr_or_subquery */
4988
{
4989 4990 4991
                                                                                    SToken s = getTokenFromRawExprNode(pCxt, yymsp[-5].minor.yy752);
                                                                                    SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy752);
                                                                                    yylhsminor.yy752 = createRawExprNodeExt(pCxt, &s, &e, createNotBetweenAnd(pCxt, releaseRawExprNode(pCxt, yymsp[-5].minor.yy752), releaseRawExprNode(pCxt, yymsp[-2].minor.yy752), releaseRawExprNode(pCxt, yymsp[0].minor.yy752)));
4992
                                                                                  }
4993
  yymsp[-5].minor.yy752 = yylhsminor.yy752;
4994
        break;
4995
      case 424: /* predicate ::= expr_or_subquery IS NULL */
4996
{
4997 4998
                                                                                    SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy752);
                                                                                    yylhsminor.yy752 = createRawExprNodeExt(pCxt, &s, &yymsp[0].minor.yy0, createOperatorNode(pCxt, OP_TYPE_IS_NULL, releaseRawExprNode(pCxt, yymsp[-2].minor.yy752), NULL));
4999
                                                                                  }
5000
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
5001
        break;
5002
      case 425: /* predicate ::= expr_or_subquery IS NOT NULL */
5003
{
5004 5005
                                                                                    SToken s = getTokenFromRawExprNode(pCxt, yymsp[-3].minor.yy752);
                                                                                    yylhsminor.yy752 = createRawExprNodeExt(pCxt, &s, &yymsp[0].minor.yy0, createOperatorNode(pCxt, OP_TYPE_IS_NOT_NULL, releaseRawExprNode(pCxt, yymsp[-3].minor.yy752), NULL));
5006
                                                                                  }
5007
  yymsp[-3].minor.yy752 = yylhsminor.yy752;
5008
        break;
5009 5010
      case 427: /* compare_op ::= NK_LT */
{ yymsp[0].minor.yy620 = OP_TYPE_LOWER_THAN; }
5011
        break;
5012 5013
      case 428: /* compare_op ::= NK_GT */
{ yymsp[0].minor.yy620 = OP_TYPE_GREATER_THAN; }
5014
        break;
5015 5016
      case 429: /* compare_op ::= NK_LE */
{ yymsp[0].minor.yy620 = OP_TYPE_LOWER_EQUAL; }
5017
        break;
5018 5019
      case 430: /* compare_op ::= NK_GE */
{ yymsp[0].minor.yy620 = OP_TYPE_GREATER_EQUAL; }
5020
        break;
5021 5022
      case 431: /* compare_op ::= NK_NE */
{ yymsp[0].minor.yy620 = OP_TYPE_NOT_EQUAL; }
5023
        break;
5024 5025
      case 432: /* compare_op ::= NK_EQ */
{ yymsp[0].minor.yy620 = OP_TYPE_EQUAL; }
5026
        break;
5027 5028
      case 433: /* compare_op ::= LIKE */
{ yymsp[0].minor.yy620 = OP_TYPE_LIKE; }
5029
        break;
5030 5031
      case 434: /* compare_op ::= NOT LIKE */
{ yymsp[-1].minor.yy620 = OP_TYPE_NOT_LIKE; }
5032
        break;
5033 5034
      case 435: /* compare_op ::= MATCH */
{ yymsp[0].minor.yy620 = OP_TYPE_MATCH; }
5035
        break;
5036 5037
      case 436: /* compare_op ::= NMATCH */
{ yymsp[0].minor.yy620 = OP_TYPE_NMATCH; }
5038
        break;
5039 5040
      case 437: /* compare_op ::= CONTAINS */
{ yymsp[0].minor.yy620 = OP_TYPE_JSON_CONTAINS; }
5041
        break;
5042 5043
      case 438: /* in_op ::= IN */
{ yymsp[0].minor.yy620 = OP_TYPE_IN; }
5044
        break;
5045 5046
      case 439: /* in_op ::= NOT IN */
{ yymsp[-1].minor.yy620 = OP_TYPE_NOT_IN; }
5047
        break;
5048 5049 5050
      case 440: /* in_predicate_value ::= NK_LP literal_list NK_RP */
{ yylhsminor.yy752 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0, createNodeListNode(pCxt, yymsp[-1].minor.yy424)); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
5051
        break;
5052
      case 442: /* boolean_value_expression ::= NOT boolean_primary */
5053
{
5054 5055
                                                                                    SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy752);
                                                                                    yylhsminor.yy752 = createRawExprNodeExt(pCxt, &yymsp[-1].minor.yy0, &e, createLogicConditionNode(pCxt, LOGIC_COND_TYPE_NOT, releaseRawExprNode(pCxt, yymsp[0].minor.yy752), NULL));
5056
                                                                                  }
5057
  yymsp[-1].minor.yy752 = yylhsminor.yy752;
5058
        break;
5059
      case 443: /* boolean_value_expression ::= boolean_value_expression OR boolean_value_expression */
5060
{
5061 5062 5063
                                                                                    SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy752);
                                                                                    SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy752);
                                                                                    yylhsminor.yy752 = createRawExprNodeExt(pCxt, &s, &e, createLogicConditionNode(pCxt, LOGIC_COND_TYPE_OR, releaseRawExprNode(pCxt, yymsp[-2].minor.yy752), releaseRawExprNode(pCxt, yymsp[0].minor.yy752)));
5064
                                                                                  }
5065
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
5066
        break;
5067
      case 444: /* boolean_value_expression ::= boolean_value_expression AND boolean_value_expression */
5068
{
5069 5070 5071
                                                                                    SToken s = getTokenFromRawExprNode(pCxt, yymsp[-2].minor.yy752);
                                                                                    SToken e = getTokenFromRawExprNode(pCxt, yymsp[0].minor.yy752);
                                                                                    yylhsminor.yy752 = createRawExprNodeExt(pCxt, &s, &e, createLogicConditionNode(pCxt, LOGIC_COND_TYPE_AND, releaseRawExprNode(pCxt, yymsp[-2].minor.yy752), releaseRawExprNode(pCxt, yymsp[0].minor.yy752)));
5072
                                                                                  }
5073
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
5074
        break;
5075 5076 5077 5078
      case 450: /* from_clause_opt ::= FROM table_reference_list */
      case 479: /* where_clause_opt ::= WHERE search_condition */ yytestcase(yyruleno==479);
      case 508: /* having_clause_opt ::= HAVING search_condition */ yytestcase(yyruleno==508);
{ yymsp[-1].minor.yy752 = yymsp[0].minor.yy752; }
5079
        break;
5080 5081 5082
      case 452: /* table_reference_list ::= table_reference_list NK_COMMA table_reference */
{ yylhsminor.yy752 = createJoinTableNode(pCxt, JOIN_TYPE_INNER, yymsp[-2].minor.yy752, yymsp[0].minor.yy752, NULL); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
5083
        break;
5084 5085 5086
      case 455: /* table_primary ::= table_name alias_opt */
{ yylhsminor.yy752 = createRealTableNode(pCxt, NULL, &yymsp[-1].minor.yy849, &yymsp[0].minor.yy849); }
  yymsp[-1].minor.yy752 = yylhsminor.yy752;
5087
        break;
5088 5089 5090
      case 456: /* table_primary ::= db_name NK_DOT table_name alias_opt */
{ yylhsminor.yy752 = createRealTableNode(pCxt, &yymsp[-3].minor.yy849, &yymsp[-1].minor.yy849, &yymsp[0].minor.yy849); }
  yymsp[-3].minor.yy752 = yylhsminor.yy752;
5091
        break;
5092 5093 5094
      case 457: /* table_primary ::= subquery alias_opt */
{ yylhsminor.yy752 = createTempTableNode(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy752), &yymsp[0].minor.yy849); }
  yymsp[-1].minor.yy752 = yylhsminor.yy752;
5095
        break;
5096 5097
      case 459: /* alias_opt ::= */
{ yymsp[1].minor.yy849 = nil_token;  }
5098
        break;
5099 5100
      case 461: /* alias_opt ::= AS table_alias */
{ yymsp[-1].minor.yy849 = yymsp[0].minor.yy849; }
5101
        break;
5102 5103 5104
      case 462: /* parenthesized_joined_table ::= NK_LP joined_table NK_RP */
      case 463: /* parenthesized_joined_table ::= NK_LP parenthesized_joined_table NK_RP */ yytestcase(yyruleno==463);
{ yymsp[-2].minor.yy752 = yymsp[-1].minor.yy752; }
5105
        break;
5106 5107 5108
      case 464: /* joined_table ::= table_reference join_type JOIN table_reference ON search_condition */
{ yylhsminor.yy752 = createJoinTableNode(pCxt, yymsp[-4].minor.yy332, yymsp[-5].minor.yy752, yymsp[-2].minor.yy752, yymsp[0].minor.yy752); }
  yymsp[-5].minor.yy752 = yylhsminor.yy752;
5109
        break;
5110 5111
      case 465: /* join_type ::= */
{ yymsp[1].minor.yy332 = JOIN_TYPE_INNER; }
5112
        break;
5113 5114
      case 466: /* join_type ::= INNER */
{ yymsp[0].minor.yy332 = JOIN_TYPE_INNER; }
5115
        break;
5116
      case 467: /* query_specification ::= SELECT set_quantifier_opt select_list from_clause_opt where_clause_opt partition_by_clause_opt range_opt every_opt fill_opt twindow_clause_opt group_by_clause_opt having_clause_opt */
5117
{ 
5118 5119 5120 5121 5122 5123 5124 5125 5126
                                                                                    yymsp[-11].minor.yy752 = createSelectStmt(pCxt, yymsp[-10].minor.yy57, yymsp[-9].minor.yy424, yymsp[-8].minor.yy752);
                                                                                    yymsp[-11].minor.yy752 = addWhereClause(pCxt, yymsp[-11].minor.yy752, yymsp[-7].minor.yy752);
                                                                                    yymsp[-11].minor.yy752 = addPartitionByClause(pCxt, yymsp[-11].minor.yy752, yymsp[-6].minor.yy424);
                                                                                    yymsp[-11].minor.yy752 = addWindowClauseClause(pCxt, yymsp[-11].minor.yy752, yymsp[-2].minor.yy752);
                                                                                    yymsp[-11].minor.yy752 = addGroupByClause(pCxt, yymsp[-11].minor.yy752, yymsp[-1].minor.yy424);
                                                                                    yymsp[-11].minor.yy752 = addHavingClause(pCxt, yymsp[-11].minor.yy752, yymsp[0].minor.yy752);
                                                                                    yymsp[-11].minor.yy752 = addRangeClause(pCxt, yymsp[-11].minor.yy752, yymsp[-5].minor.yy752);
                                                                                    yymsp[-11].minor.yy752 = addEveryClause(pCxt, yymsp[-11].minor.yy752, yymsp[-4].minor.yy752);
                                                                                    yymsp[-11].minor.yy752 = addFillClause(pCxt, yymsp[-11].minor.yy752, yymsp[-3].minor.yy752);
5127 5128
                                                                                  }
        break;
5129 5130
      case 470: /* set_quantifier_opt ::= ALL */
{ yymsp[0].minor.yy57 = false; }
5131
        break;
5132 5133 5134
      case 473: /* select_item ::= NK_STAR */
{ yylhsminor.yy752 = createColumnNode(pCxt, NULL, &yymsp[0].minor.yy0); }
  yymsp[0].minor.yy752 = yylhsminor.yy752;
5135
        break;
5136 5137 5138 5139
      case 475: /* select_item ::= common_expression column_alias */
      case 485: /* partition_item ::= expr_or_subquery column_alias */ yytestcase(yyruleno==485);
{ yylhsminor.yy752 = setProjectionAlias(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy752), &yymsp[0].minor.yy849); }
  yymsp[-1].minor.yy752 = yylhsminor.yy752;
5140
        break;
5141 5142 5143 5144
      case 476: /* select_item ::= common_expression AS column_alias */
      case 486: /* partition_item ::= expr_or_subquery AS column_alias */ yytestcase(yyruleno==486);
{ yylhsminor.yy752 = setProjectionAlias(pCxt, releaseRawExprNode(pCxt, yymsp[-2].minor.yy752), &yymsp[0].minor.yy849); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
5145
        break;
5146 5147 5148 5149
      case 481: /* partition_by_clause_opt ::= PARTITION BY partition_list */
      case 504: /* group_by_clause_opt ::= GROUP BY group_by_list */ yytestcase(yyruleno==504);
      case 523: /* order_by_clause_opt ::= ORDER BY sort_specification_list */ yytestcase(yyruleno==523);
{ yymsp[-2].minor.yy424 = yymsp[0].minor.yy424; }
5150
        break;
5151 5152
      case 488: /* twindow_clause_opt ::= SESSION NK_LP column_reference NK_COMMA duration_literal NK_RP */
{ yymsp[-5].minor.yy752 = createSessionWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy752), releaseRawExprNode(pCxt, yymsp[-1].minor.yy752)); }
5153
        break;
5154 5155
      case 489: /* twindow_clause_opt ::= STATE_WINDOW NK_LP expr_or_subquery NK_RP */
{ yymsp[-3].minor.yy752 = createStateWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-1].minor.yy752)); }
5156
        break;
5157 5158
      case 490: /* twindow_clause_opt ::= INTERVAL NK_LP duration_literal NK_RP sliding_opt fill_opt */
{ yymsp[-5].minor.yy752 = createIntervalWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy752), NULL, yymsp[-1].minor.yy752, yymsp[0].minor.yy752); }
5159
        break;
5160 5161
      case 491: /* twindow_clause_opt ::= INTERVAL NK_LP duration_literal NK_COMMA duration_literal NK_RP sliding_opt fill_opt */
{ yymsp[-7].minor.yy752 = createIntervalWindowNode(pCxt, releaseRawExprNode(pCxt, yymsp[-5].minor.yy752), releaseRawExprNode(pCxt, yymsp[-3].minor.yy752), yymsp[-1].minor.yy752, yymsp[0].minor.yy752); }
X
Xiaoyu Wang 已提交
5162
        break;
5163 5164
      case 492: /* twindow_clause_opt ::= EVENT_WINDOW START WITH search_condition END WITH search_condition */
{ yymsp[-6].minor.yy752 = createEventWindowNode(pCxt, yymsp[-3].minor.yy752, yymsp[0].minor.yy752); }
5165
        break;
5166 5167
      case 496: /* fill_opt ::= FILL NK_LP fill_mode NK_RP */
{ yymsp[-3].minor.yy752 = createFillNode(pCxt, yymsp[-1].minor.yy214, NULL); }
5168
        break;
5169 5170
      case 497: /* fill_opt ::= FILL NK_LP VALUE NK_COMMA literal_list NK_RP */
{ yymsp[-5].minor.yy752 = createFillNode(pCxt, FILL_MODE_VALUE, createNodeListNode(pCxt, yymsp[-1].minor.yy424)); }
5171
        break;
5172 5173
      case 498: /* fill_mode ::= NONE */
{ yymsp[0].minor.yy214 = FILL_MODE_NONE; }
5174
        break;
5175 5176
      case 499: /* fill_mode ::= PREV */
{ yymsp[0].minor.yy214 = FILL_MODE_PREV; }
5177
        break;
5178 5179
      case 500: /* fill_mode ::= NULL */
{ yymsp[0].minor.yy214 = FILL_MODE_NULL; }
5180
        break;
5181 5182
      case 501: /* fill_mode ::= LINEAR */
{ yymsp[0].minor.yy214 = FILL_MODE_LINEAR; }
5183
        break;
5184 5185
      case 502: /* fill_mode ::= NEXT */
{ yymsp[0].minor.yy214 = FILL_MODE_NEXT; }
5186
        break;
5187 5188 5189
      case 505: /* group_by_list ::= expr_or_subquery */
{ yylhsminor.yy424 = createNodeList(pCxt, createGroupingSetNode(pCxt, releaseRawExprNode(pCxt, yymsp[0].minor.yy752))); }
  yymsp[0].minor.yy424 = yylhsminor.yy424;
5190
        break;
5191 5192 5193
      case 506: /* group_by_list ::= group_by_list NK_COMMA expr_or_subquery */
{ yylhsminor.yy424 = addNodeToList(pCxt, yymsp[-2].minor.yy424, createGroupingSetNode(pCxt, releaseRawExprNode(pCxt, yymsp[0].minor.yy752))); }
  yymsp[-2].minor.yy424 = yylhsminor.yy424;
X
Xiaoyu Wang 已提交
5194
        break;
5195 5196
      case 510: /* range_opt ::= RANGE NK_LP expr_or_subquery NK_COMMA expr_or_subquery NK_RP */
{ yymsp[-5].minor.yy752 = createInterpTimeRange(pCxt, releaseRawExprNode(pCxt, yymsp[-3].minor.yy752), releaseRawExprNode(pCxt, yymsp[-1].minor.yy752)); }
5197
        break;
5198
      case 513: /* query_expression ::= query_simple order_by_clause_opt slimit_clause_opt limit_clause_opt */
X
Xiaoyu Wang 已提交
5199
{
5200 5201 5202
                                                                                    yylhsminor.yy752 = addOrderByClause(pCxt, yymsp[-3].minor.yy752, yymsp[-2].minor.yy424);
                                                                                    yylhsminor.yy752 = addSlimitClause(pCxt, yylhsminor.yy752, yymsp[-1].minor.yy752);
                                                                                    yylhsminor.yy752 = addLimitClause(pCxt, yylhsminor.yy752, yymsp[0].minor.yy752);
5203
                                                                                  }
5204
  yymsp[-3].minor.yy752 = yylhsminor.yy752;
5205
        break;
5206 5207 5208
      case 516: /* union_query_expression ::= query_simple_or_subquery UNION ALL query_simple_or_subquery */
{ yylhsminor.yy752 = createSetOperator(pCxt, SET_OP_TYPE_UNION_ALL, yymsp[-3].minor.yy752, yymsp[0].minor.yy752); }
  yymsp[-3].minor.yy752 = yylhsminor.yy752;
X
Xiaoyu Wang 已提交
5209
        break;
5210 5211 5212
      case 517: /* union_query_expression ::= query_simple_or_subquery UNION query_simple_or_subquery */
{ yylhsminor.yy752 = createSetOperator(pCxt, SET_OP_TYPE_UNION, yymsp[-2].minor.yy752, yymsp[0].minor.yy752); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
X
Xiaoyu Wang 已提交
5213
        break;
5214 5215 5216
      case 525: /* slimit_clause_opt ::= SLIMIT NK_INTEGER */
      case 529: /* limit_clause_opt ::= LIMIT NK_INTEGER */ yytestcase(yyruleno==529);
{ yymsp[-1].minor.yy752 = createLimitNode(pCxt, &yymsp[0].minor.yy0, NULL); }
5217
        break;
5218 5219 5220
      case 526: /* slimit_clause_opt ::= SLIMIT NK_INTEGER SOFFSET NK_INTEGER */
      case 530: /* limit_clause_opt ::= LIMIT NK_INTEGER OFFSET NK_INTEGER */ yytestcase(yyruleno==530);
{ yymsp[-3].minor.yy752 = createLimitNode(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0); }
5221
        break;
5222 5223 5224
      case 527: /* slimit_clause_opt ::= SLIMIT NK_INTEGER NK_COMMA NK_INTEGER */
      case 531: /* limit_clause_opt ::= LIMIT NK_INTEGER NK_COMMA NK_INTEGER */ yytestcase(yyruleno==531);
{ yymsp[-3].minor.yy752 = createLimitNode(pCxt, &yymsp[0].minor.yy0, &yymsp[-2].minor.yy0); }
5225
        break;
5226 5227 5228
      case 532: /* subquery ::= NK_LP query_expression NK_RP */
{ yylhsminor.yy752 = createRawExprNodeExt(pCxt, &yymsp[-2].minor.yy0, &yymsp[0].minor.yy0, yymsp[-1].minor.yy752); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
5229
        break;
5230 5231 5232
      case 537: /* sort_specification ::= expr_or_subquery ordering_specification_opt null_ordering_opt */
{ yylhsminor.yy752 = createOrderByExprNode(pCxt, releaseRawExprNode(pCxt, yymsp[-2].minor.yy752), yymsp[-1].minor.yy538, yymsp[0].minor.yy777); }
  yymsp[-2].minor.yy752 = yylhsminor.yy752;
5233
        break;
5234 5235
      case 538: /* ordering_specification_opt ::= */
{ yymsp[1].minor.yy538 = ORDER_ASC; }
5236
        break;
5237 5238
      case 539: /* ordering_specification_opt ::= ASC */
{ yymsp[0].minor.yy538 = ORDER_ASC; }
5239
        break;
5240 5241
      case 540: /* ordering_specification_opt ::= DESC */
{ yymsp[0].minor.yy538 = ORDER_DESC; }
5242
        break;
5243 5244
      case 541: /* null_ordering_opt ::= */
{ yymsp[1].minor.yy777 = NULL_ORDER_DEFAULT; }
5245
        break;
5246 5247
      case 542: /* null_ordering_opt ::= NULLS FIRST */
{ yymsp[-1].minor.yy777 = NULL_ORDER_FIRST; }
5248
        break;
5249 5250
      case 543: /* null_ordering_opt ::= NULLS LAST */
{ yymsp[-1].minor.yy777 = NULL_ORDER_LAST; }
5251 5252 5253 5254 5255
        break;
      default:
        break;
/********** End reduce actions ************************************************/
  };
X
Xiaoyu Wang 已提交
5256 5257 5258
  assert( yyruleno<sizeof(yyRuleInfo)/sizeof(yyRuleInfo[0]) );
  yygoto = yyRuleInfo[yyruleno].lhs;
  yysize = yyRuleInfo[yyruleno].nrhs;
5259 5260 5261 5262 5263 5264 5265 5266 5267 5268 5269 5270 5271 5272 5273 5274 5275 5276 5277 5278 5279 5280 5281 5282
  yyact = yy_find_reduce_action(yymsp[yysize].stateno,(YYCODETYPE)yygoto);

  /* There are no SHIFTREDUCE actions on nonterminals because the table
  ** generator has simplified them to pure REDUCE actions. */
  assert( !(yyact>YY_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 */
){
X
Xiaoyu Wang 已提交
5283 5284
  ParseARG_FETCH
  ParseCTX_FETCH
5285 5286 5287 5288 5289 5290 5291 5292 5293 5294
#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 *****************************************/
X
Xiaoyu Wang 已提交
5295 5296
  ParseARG_STORE /* Suppress warning about unused %extra_argument variable */
  ParseCTX_STORE
5297 5298 5299 5300 5301 5302 5303 5304 5305
}
#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 */
X
Xiaoyu Wang 已提交
5306
  ParseTOKENTYPE yyminor         /* The minor type of the error token */
5307
){
X
Xiaoyu Wang 已提交
5308 5309
  ParseARG_FETCH
  ParseCTX_FETCH
5310 5311
#define TOKEN yyminor
/************ Begin %syntax_error code ****************************************/
5312

5313
  if (TSDB_CODE_SUCCESS == pCxt->errCode) {
5314
    if(TOKEN.z) {
5315
      pCxt->errCode = generateSyntaxErrMsg(&pCxt->msgBuf, TSDB_CODE_PAR_SYNTAX_ERROR, TOKEN.z);
5316
    } else {
5317
      pCxt->errCode = generateSyntaxErrMsg(&pCxt->msgBuf, TSDB_CODE_PAR_INCOMPLETE_SQL);
5318
    }
5319 5320
  } else if (TSDB_CODE_PAR_DB_NOT_SPECIFIED == pCxt->errCode && TK_NK_FLOAT == TOKEN.type) {
    pCxt->errCode = generateSyntaxErrMsg(&pCxt->msgBuf, TSDB_CODE_PAR_SYNTAX_ERROR, TOKEN.z);
5321 5322
  }
/************ End %syntax_error code ******************************************/
X
Xiaoyu Wang 已提交
5323 5324
  ParseARG_STORE /* Suppress warning about unused %extra_argument variable */
  ParseCTX_STORE
5325 5326 5327 5328 5329 5330 5331 5332
}

/*
** The following is executed when the parser accepts
*/
static void yy_accept(
  yyParser *yypParser           /* The parser */
){
X
Xiaoyu Wang 已提交
5333 5334
  ParseARG_FETCH
  ParseCTX_FETCH
5335 5336 5337 5338 5339 5340 5341 5342 5343 5344 5345 5346 5347
#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 *******************************************/
X
Xiaoyu Wang 已提交
5348 5349
  ParseARG_STORE /* Suppress warning about unused %extra_argument variable */
  ParseCTX_STORE
5350 5351 5352 5353
}

/* The main parser program.
** The first argument is a pointer to a structure obtained from
X
Xiaoyu Wang 已提交
5354
** "ParseAlloc" which describes the current state of the parser.
5355 5356 5357 5358 5359 5360 5361 5362 5363 5364 5365 5366 5367 5368 5369 5370
** 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:
** <ul>
** <li> A pointer to the parser (an opaque structure.)
** <li> The major token number.
** <li> The minor token number.
** <li> An option argument of a grammar-specified type.
** </ul>
**
** Outputs:
** None.
*/
X
Xiaoyu Wang 已提交
5371
void Parse(
5372 5373
  void *yyp,                   /* The parser */
  int yymajor,                 /* The major token code number */
X
Xiaoyu Wang 已提交
5374 5375
  ParseTOKENTYPE yyminor       /* The value for the token */
  ParseARG_PDECL               /* Optional %extra_argument parameter */
5376 5377 5378 5379 5380 5381 5382 5383 5384 5385
){
  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 */
X
Xiaoyu Wang 已提交
5386 5387
  ParseCTX_FETCH
  ParseARG_STORE
5388 5389 5390 5391 5392 5393 5394 5395 5396 5397 5398 5399 5400 5401 5402 5403 5404 5405 5406

  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

X
Xiaoyu Wang 已提交
5407
  do{
5408 5409 5410
    assert( yyact==yypParser->yytos->stateno );
    yyact = yy_find_shift_action((YYCODETYPE)yymajor,yyact);
    if( yyact >= YY_MIN_REDUCE ){
X
Xiaoyu Wang 已提交
5411 5412
      yyact = yy_reduce(yypParser,yyact-YY_MIN_REDUCE,yymajor,
                        yyminor ParseCTX_PARAM);
5413 5414 5415 5416 5417 5418 5419 5420 5421 5422 5423 5424 5425 5426 5427 5428 5429 5430 5431 5432 5433 5434 5435 5436 5437 5438 5439 5440 5441 5442 5443 5444 5445 5446 5447 5448 5449 5450 5451 5452 5453 5454 5455 5456 5457 5458 5459 5460 5461 5462 5463 5464 5465 5466 5467
    }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{
X
Xiaoyu Wang 已提交
5468 5469 5470 5471 5472
        while( yypParser->yytos >= yypParser->yystack
            && (yyact = yy_find_reduce_action(
                        yypParser->yytos->stateno,
                        YYERRORSYMBOL)) > YY_MAX_SHIFTREDUCE
        ){
5473 5474
          yy_pop_parser_stack(yypParser);
        }
X
Xiaoyu Wang 已提交
5475
        if( yypParser->yytos < yypParser->yystack || yymajor==0 ){
5476 5477 5478 5479 5480 5481 5482 5483 5484 5485 5486 5487 5488 5489 5490 5491 5492 5493 5494 5495 5496 5497 5498 5499 5500 5501 5502 5503 5504 5505 5506 5507 5508 5509 5510 5511 5512 5513 5514 5515 5516 5517 5518 5519 5520 5521 5522 5523 5524
          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
    }
X
Xiaoyu Wang 已提交
5525
  }while( yypParser->yytos>yypParser->yystack );
5526 5527 5528 5529 5530 5531 5532 5533 5534 5535 5536 5537 5538 5539 5540 5541 5542 5543 5544
#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.
*/
X
Xiaoyu Wang 已提交
5545
int ParseFallback(int iToken){
5546
#ifdef YYFALLBACK
X
Xiaoyu Wang 已提交
5547 5548 5549
  if( iToken<(int)(sizeof(yyFallback)/sizeof(yyFallback[0])) ){
    return yyFallback[iToken];
  }
5550 5551
#else
  (void)iToken;
D
dapan1121 已提交
5552
#endif
X
Xiaoyu Wang 已提交
5553
  return 0;
5554
}