OmniSciDB  8fa3bf436f
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Parser_wnd_pregen.cpp
Go to the documentation of this file.
1 #define YY_Parser_h_included
2 
3 /* A Bison++ parser, made from Parser/parser.y */
4 
5 /* with Bison++ version bison++ version 1.21-45, adapted from GNU Bison by
6  * coetmeur@icdc.fr
7  */
8 
9 /* -*-C-*- Note some compilers choke on comments on `#line' lines. */
10 /* Skeleton output parser for bison,
11  Copyright (C) 1984, 1989, 1990 Bob Corbett and Richard Stallman
12 
13  This program is free software; you can redistribute it and/or modify
14  it under the terms of the GNU General Public License as published by
15  the Free Software Foundation; either version 1, or (at your option)
16  any later version.
17 
18  This program is distributed in the hope that it will be useful,
19  but WITHOUT ANY WARRANTY; without even the implied warranty of
20  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21  GNU General Public License for more details.
22 
23  You should have received a copy of the GNU General Public License
24  along with this program; if not, write to the Free Software
25  Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
26 
27 /* HEADER SECTION */
28 #if defined(_MSDOS) || defined(MSDOS) || defined(__MSDOS__)
29 #define __MSDOS_AND_ALIKE
30 #endif
31 #if defined(_WINDOWS) && defined(_MSC_VER)
32 #define __HAVE_NO_ALLOCA
33 #define __MSDOS_AND_ALIKE
34 #endif
35 
36 #ifndef alloca
37 #if defined(__GNUC__)
38 #define alloca __builtin_alloca
39 
40 #elif (!defined(__STDC__) && defined(sparc)) || defined(__sparc__) || \
41  defined(__sparc) || defined(__sgi)
42 #include <alloca.h>
43 
44 #elif defined(__MSDOS_AND_ALIKE)
45 #include <malloc.h>
46 #ifndef __TURBOC__
47 /* MS C runtime lib */
48 #define alloca _alloca
49 #endif
50 
51 #elif defined(_AIX)
52 #include <malloc.h>
53 #pragma alloca
54 
55 #elif defined(__hpux)
56 #ifdef __cplusplus
57 extern "C" {
58 void* alloca(unsigned int);
59 };
60 #else /* not __cplusplus */
61 void* alloca();
62 #endif /* not __cplusplus */
63 
64 #endif /* not _AIX not MSDOS, or __TURBOC__ or _AIX, not sparc. */
65 #endif /* alloca not defined. */
66 #ifdef c_plusplus
67 #ifndef __cplusplus
68 #define __cplusplus
69 #endif
70 #endif
71 #ifdef __cplusplus
72 #ifndef YY_USE_CLASS
73 #define YY_USE_CLASS
74 #endif
75 #else
76 #ifndef __STDC__
77 #define const
78 #endif
79 #endif
80 #include <stdio.h>
81 #define YYBISON 1
82 
83 #define YY_Parser_CLASS SQLParser
84 #define YY_Parser_LVAL yylval
85 #define YY_Parser_CONSTRUCTOR_INIT : lexer(yylval)
86 #define YY_Parser_MEMBERS \
87  virtual ~SQLParser() {} \
88  int parse(const std::string& inputStrOrig, \
89  std::list<std::unique_ptr<Stmt>>& parseTrees, \
90  std::string& lastParsed) { \
91  auto inputStr = boost::algorithm::trim_right_copy_if( \
92  inputStrOrig, boost::is_any_of(";") || boost::is_space()) + \
93  ";"; \
94  boost::regex create_view_expr{ \
95  R"(CREATE\s+VIEW\s+(IF\s+NOT\s+EXISTS\s+)?([A-Za-z_][A-Za-z0-9\$_]*)\s+AS\s+(.*);?)", \
96  boost::regex::extended | boost::regex::icase}; \
97  std::lock_guard<std::mutex> lock(mutex_); \
98  boost::smatch what; \
99  const auto trimmed_input = boost::algorithm::trim_copy(inputStr); \
100  if (boost::regex_match( \
101  trimmed_input.cbegin(), trimmed_input.cend(), what, create_view_expr)) { \
102  const bool if_not_exists = what[1].length() > 0; \
103  const auto view_name = what[2].str(); \
104  const auto select_query = what[3].str(); \
105  parseTrees.emplace_back( \
106  new CreateViewStmt(view_name, select_query, if_not_exists)); \
107  return 0; \
108  } \
109  std::istringstream ss(inputStr); \
110  lexer.switch_streams(&ss, 0); \
111  yyparse(parseTrees); \
112  lastParsed = lexer.YYText(); \
113  if (!errors_.empty()) { \
114  throw std::runtime_error(errors_[0]); \
115  } \
116  return yynerrs; \
117  } \
118  \
119  private: \
120  SQLLexer lexer; \
121  std::mutex mutex_; \
122  std::vector<std::string> errors_;
123 #define YY_Parser_LEX_BODY \
124  { return lexer.yylex(); }
125 #define YY_Parser_ERROR_BODY \
126  {} /*{ std::cerr << "Syntax error on line " << lexer.lineno() << ". Last word parsed: \
127  " << lexer.YYText() << std::endl; } */
128 
129 #include <boost/algorithm/string/predicate.hpp>
130 #include <boost/algorithm/string/trim.hpp>
131 #include <boost/regex.hpp>
132 #include <cstdlib>
133 #include <fstream>
134 #include <iostream>
135 #include <list>
136 #include <mutex>
137 #include <sstream>
138 #include <stdexcept>
139 #include <string>
140 #include <utility>
141 #include "Parser/FlexLexer.h"
142 #include "ParserNode.h"
143 #include "ReservedKeywords.h"
144 #include "TrackedPtr.h"
145 
146 #ifdef DELETE
147 #undef DELETE
148 #endif
149 
150 #ifdef IN
151 #undef IN
152 #endif
153 
154 using namespace Parser;
155 #define YY_Parser_PARSE_PARAM std::list<std::unique_ptr<Stmt>>& parseTrees
156 
157 typedef union {
158  bool boolval;
159  int64_t intval;
160  float floatval;
161  double doubleval;
169 #define YY_Parser_STYPE yy_Parser_stype
170 
171 class SQLLexer : public yyFlexLexer {
172  public:
173  SQLLexer(YY_Parser_STYPE& lval) : yylval(lval){};
175  std::vector<std::unique_ptr<TrackedPtr<std::string>>> parsed_str_tokens_{};
176  std::vector<std::unique_ptr<TrackedListPtr<std::string>>> parsed_str_list_tokens_{};
177  std::vector<std::unique_ptr<TrackedPtr<Node>>> parsed_node_tokens_{};
178  std::vector<std::unique_ptr<TrackedListPtr<Node>>> parsed_node_list_tokens_{};
179 };
180 
181 /* %{ and %header{ and %union, during decl */
182 #define YY_Parser_BISON 1
183 #ifndef YY_Parser_COMPATIBILITY
184 #ifndef YY_USE_CLASS
185 #define YY_Parser_COMPATIBILITY 1
186 #else
187 #define YY_Parser_COMPATIBILITY 0
188 #endif
189 #endif
190 
191 #if YY_Parser_COMPATIBILITY != 0
192 /* backward compatibility */
193 #ifdef YYLTYPE
194 #ifndef YY_Parser_LTYPE
195 #define YY_Parser_LTYPE YYLTYPE
196 #endif
197 #endif
198 #ifdef YYSTYPE
199 #ifndef YY_Parser_STYPE
200 #define YY_Parser_STYPE YYSTYPE
201 #endif
202 #endif
203 #ifdef YYDEBUG
204 #ifndef YY_Parser_DEBUG
205 #define YY_Parser_DEBUG YYDEBUG
206 #endif
207 #endif
208 #ifdef YY_Parser_STYPE
209 #ifndef yystype
210 #define yystype YY_Parser_STYPE
211 #endif
212 #endif
213 /* use goto to be compatible */
214 #ifndef YY_Parser_USE_GOTO
215 #define YY_Parser_USE_GOTO 1
216 #endif
217 #endif
218 
219 /* use no goto to be clean in C++ */
220 #ifndef YY_Parser_USE_GOTO
221 #define YY_Parser_USE_GOTO 0
222 #endif
223 
224 #ifndef YY_Parser_PURE
225 
226 /* YY_Parser_PURE */
227 #endif
228 
229 /* section apres lecture def, avant lecture grammaire S2 */
230 
231 /* prefix */
232 #ifndef YY_Parser_DEBUG
233 
234 /* YY_Parser_DEBUG */
235 #endif
236 
237 #ifndef YY_Parser_LSP_NEEDED
238 
239 /* YY_Parser_LSP_NEEDED*/
240 #endif
241 
242 /* DEFAULT LTYPE*/
243 #ifdef YY_Parser_LSP_NEEDED
244 #ifndef YY_Parser_LTYPE
245 typedef struct yyltype {
246  int timestamp;
247  int first_line;
248  int first_column;
249  int last_line;
250  int last_column;
251  char* text;
252 } yyltype;
253 
254 #define YY_Parser_LTYPE yyltype
255 #endif
256 #endif
257 /* DEFAULT STYPE*/
258 /* We used to use `unsigned long' as YY_Parser_STYPE on MSDOS,
259  but it seems better to be consistent.
260  Most programs should declare their own type anyway. */
261 
262 #ifndef YY_Parser_STYPE
263 #define YY_Parser_STYPE int
264 #endif
265 /* DEFAULT MISCELANEOUS */
266 #ifndef YY_Parser_PARSE
267 #define YY_Parser_PARSE yyparse
268 #endif
269 #ifndef YY_Parser_LEX
270 #define YY_Parser_LEX yylex
271 #endif
272 #ifndef YY_Parser_LVAL
273 #define YY_Parser_LVAL yylval
274 #endif
275 #ifndef YY_Parser_LLOC
276 #define YY_Parser_LLOC yylloc
277 #endif
278 #ifndef YY_Parser_CHAR
279 #define YY_Parser_CHAR yychar
280 #endif
281 #ifndef YY_Parser_NERRS
282 #define YY_Parser_NERRS yynerrs
283 #endif
284 #ifndef YY_Parser_DEBUG_FLAG
285 #define YY_Parser_DEBUG_FLAG yydebug
286 #endif
287 #ifndef YY_Parser_ERROR
288 #define YY_Parser_ERROR yyerror
289 #endif
290 #ifndef YY_Parser_PARSE_PARAM
291 #ifndef __STDC__
292 #ifndef __cplusplus
293 #ifndef YY_USE_CLASS
294 #define YY_Parser_PARSE_PARAM
295 #ifndef YY_Parser_PARSE_PARAM_DEF
296 #define YY_Parser_PARSE_PARAM_DEF
297 #endif
298 #endif
299 #endif
300 #endif
301 #ifndef YY_Parser_PARSE_PARAM
302 #define YY_Parser_PARSE_PARAM void
303 #endif
304 #endif
305 #if YY_Parser_COMPATIBILITY != 0
306 /* backward compatibility */
307 #ifdef YY_Parser_LTYPE
308 #ifndef YYLTYPE
309 #define YYLTYPE YY_Parser_LTYPE
310 #else
311 /* WARNING obsolete !!! user defined YYLTYPE not reported into generated header */
312 #endif
313 #endif
314 #ifndef YYSTYPE
315 #define YYSTYPE YY_Parser_STYPE
316 #else
317 /* WARNING obsolete !!! user defined YYSTYPE not reported into generated header */
318 #endif
319 #ifdef YY_Parser_PURE
320 #ifndef YYPURE
321 #define YYPURE YY_Parser_PURE
322 #endif
323 #endif
324 #ifdef YY_Parser_DEBUG
325 #ifndef YYDEBUG
326 #define YYDEBUG YY_Parser_DEBUG
327 #endif
328 #endif
329 #ifndef YY_Parser_ERROR_VERBOSE
330 #ifdef YYERROR_VERBOSE
331 #define YY_Parser_ERROR_VERBOSE YYERROR_VERBOSE
332 #endif
333 #endif
334 #ifndef YY_Parser_LSP_NEEDED
335 #ifdef YYLSP_NEEDED
336 #define YY_Parser_LSP_NEEDED YYLSP_NEEDED
337 #endif
338 #endif
339 #endif
340 #ifndef YY_USE_CLASS
341 /* TOKEN C */
342 
343 #define NAME 258
344 #define DASHEDNAME 259
345 #define EMAIL 260
346 #define STRING 261
347 #define FWDSTR 262
348 #define SELECTSTRING 263
349 #define QUOTED_IDENTIFIER 264
350 #define INTNUM 265
351 #define FIXEDNUM 266
352 #define OR 267
353 #define AND 268
354 #define NOT 269
355 #define EQUAL 270
356 #define COMPARISON 271
357 #define UMINUS 272
358 #define ADD 273
359 #define ALL 274
360 #define ALTER 275
361 #define AMMSC 276
362 #define ANY 277
363 #define ARCHIVE 278
364 #define ARRAY 279
365 #define AS 280
366 #define ASC 281
367 #define AUTHORIZATION 282
368 #define BETWEEN 283
369 #define BIGINT 284
370 #define BOOLEAN 285
371 #define BY 286
372 #define CASE 287
373 #define CAST 288
374 #define CHAR_LENGTH 289
375 #define CHARACTER 290
376 #define CHECK 291
377 #define CLOSE 292
378 #define CLUSTER 293
379 #define COLUMN 294
380 #define COMMIT 295
381 #define CONTINUE 296
382 #define COPY 297
383 #define CREATE 298
384 #define CURRENT 299
385 #define CURSOR 300
386 #define DATABASE 301
387 #define DATAFRAME 302
388 #define DATE 303
389 #define DATETIME 304
390 #define DATE_TRUNC 305
391 #define DECIMAL 306
392 #define DECLARE 307
393 #define DEFAULT 308
394 #define DELETE 309
395 #define DESC 310
396 #define DICTIONARY 311
397 #define DISTINCT 312
398 #define DOUBLE 313
399 #define DROP 314
400 #define DUMP 315
401 #define ELSE 316
402 #define END 317
403 #define EXISTS 318
404 #define EXTRACT 319
405 #define FETCH 320
406 #define FIRST 321
407 #define FLOAT 322
408 #define FOR 323
409 #define FOREIGN 324
410 #define FOUND 325
411 #define FROM 326
412 #define GEOGRAPHY 327
413 #define GEOMETRY 328
414 #define GRANT 329
415 #define GROUP 330
416 #define HAVING 331
417 #define IF 332
418 #define ILIKE 333
419 #define IN 334
420 #define INSERT 335
421 #define INTEGER 336
422 #define INTO 337
423 #define IS 338
424 #define LANGUAGE 339
425 #define LAST 340
426 #define LENGTH 341
427 #define LIKE 342
428 #define LIMIT 343
429 #define LINESTRING 344
430 #define MOD 345
431 #define MULTIPOLYGON 346
432 #define NOW 347
433 #define NULLX 348
434 #define NUMERIC 349
435 #define OF 350
436 #define OFFSET 351
437 #define ON 352
438 #define OPEN 353
439 #define OPTIMIZE 354
440 #define OPTIMIZED 355
441 #define OPTION 356
442 #define ORDER 357
443 #define PARAMETER 358
444 #define POINT 359
445 #define POLYGON 360
446 #define PRECISION 361
447 #define PRIMARY 362
448 #define PRIVILEGES 363
449 #define PROCEDURE 364
450 #define SERVER 365
451 #define SMALLINT 366
452 #define SOME 367
453 #define TABLE 368
454 #define TEMPORARY 369
455 #define TEXT 370
456 #define THEN 371
457 #define TIME 372
458 #define TIMESTAMP 373
459 #define TINYINT 374
460 #define TO 375
461 #define TRUNCATE 376
462 #define UNION 377
463 #define PUBLIC 378
464 #define REAL 379
465 #define REFERENCES 380
466 #define RENAME 381
467 #define RESTORE 382
468 #define REVOKE 383
469 #define ROLE 384
470 #define ROLLBACK 385
471 #define SCHEMA 386
472 #define SELECT 387
473 #define SET 388
474 #define SHARD 389
475 #define SHARED 390
476 #define SHOW 391
477 #define UNIQUE 392
478 #define UPDATE 393
479 #define USER 394
480 #define VALIDATE 395
481 #define VALUES 396
482 #define VIEW 397
483 #define WHEN 398
484 #define WHENEVER 399
485 #define WHERE 400
486 #define WITH 401
487 #define WORK 402
488 #define EDIT 403
489 #define ACCESS 404
490 #define DASHBOARD 405
491 #define SQL 406
492 #define EDITOR 407
493 
494 /* #defines tokens */
495 #else
496 /* CLASS */
497 #ifndef YY_Parser_CLASS
498 #define YY_Parser_CLASS Parser
499 #endif
500 #ifndef YY_Parser_INHERIT
501 #define YY_Parser_INHERIT
502 #endif
503 #ifndef YY_Parser_MEMBERS
504 #define YY_Parser_MEMBERS
505 #endif
506 #ifndef YY_Parser_LEX_BODY
507 #define YY_Parser_LEX_BODY
508 #endif
509 #ifndef YY_Parser_ERROR_BODY
510 #define YY_Parser_ERROR_BODY
511 #endif
512 #ifndef YY_Parser_CONSTRUCTOR_PARAM
513 #define YY_Parser_CONSTRUCTOR_PARAM
514 #endif
515 #ifndef YY_Parser_CONSTRUCTOR_CODE
516 #define YY_Parser_CONSTRUCTOR_CODE
517 #endif
518 #ifndef YY_Parser_CONSTRUCTOR_INIT
519 #define YY_Parser_CONSTRUCTOR_INIT
520 #endif
521 /* choose between enum and const */
522 #ifndef YY_Parser_USE_CONST_TOKEN
523 #define YY_Parser_USE_CONST_TOKEN 0
524 /* yes enum is more compatible with flex, */
525 /* so by default we use it */
526 #endif
527 #if YY_Parser_USE_CONST_TOKEN != 0
528 #ifndef YY_Parser_ENUM_TOKEN
529 #define YY_Parser_ENUM_TOKEN yy_Parser_enum_token
530 #endif
531 #endif
532 
533 class YY_Parser_CLASS YY_Parser_INHERIT {
534  public:
535 #if YY_Parser_USE_CONST_TOKEN != 0
536  /* static const int token ... */
537 
538  static const int NAME;
539  static const int DASHEDNAME;
540  static const int EMAIL;
541  static const int STRING;
542  static const int FWDSTR;
543  static const int SELECTSTRING;
544  static const int QUOTED_IDENTIFIER;
545  static const int INTNUM;
546  static const int FIXEDNUM;
547  static const int OR;
548  static const int AND;
549  static const int NOT;
550  static const int EQUAL;
551  static const int COMPARISON;
552  static const int UMINUS;
553  static const int ADD;
554  static const int ALL;
555  static const int ALTER;
556  static const int AMMSC;
557  static const int ANY;
558  static const int ARCHIVE;
559  static const int ARRAY;
560  static const int AS;
561  static const int ASC;
562  static const int AUTHORIZATION;
563  static const int BETWEEN;
564  static const int BIGINT;
565  static const int BOOLEAN;
566  static const int BY;
567  static const int CASE;
568  static const int CAST;
569  static const int CHAR_LENGTH;
570  static const int CHARACTER;
571  static const int CHECK;
572  static const int CLOSE;
573  static const int CLUSTER;
574  static const int COLUMN;
575  static const int COMMIT;
576  static const int CONTINUE;
577  static const int COPY;
578  static const int CREATE;
579  static const int CURRENT;
580  static const int CURSOR;
581  static const int DATABASE;
582  static const int DATAFRAME;
583  static const int DATE;
584  static const int DATETIME;
585  static const int DATE_TRUNC;
586  static const int DECIMAL;
587  static const int DECLARE;
588  static const int DEFAULT;
589  static const int DELETE;
590  static const int DESC;
591  static const int DICTIONARY;
592  static const int DISTINCT;
593  static const int DOUBLE;
594  static const int DROP;
595  static const int DUMP;
596  static const int ELSE;
597  static const int END;
598  static const int EXISTS;
599  static const int EXTRACT;
600  static const int FETCH;
601  static const int FIRST;
602  static const int FLOAT;
603  static const int FOR;
604  static const int FOREIGN;
605  static const int FOUND;
606  static const int FROM;
607  static const int GEOGRAPHY;
608  static const int GEOMETRY;
609  static const int GRANT;
610  static const int GROUP;
611  static const int HAVING;
612  static const int IF;
613  static const int ILIKE;
614  static const int IN;
615  static const int INSERT;
616  static const int INTEGER;
617  static const int INTO;
618  static const int IS;
619  static const int LANGUAGE;
620  static const int LAST;
621  static const int LENGTH;
622  static const int LIKE;
623  static const int LIMIT;
624  static const int LINESTRING;
625  static const int MOD;
626  static const int MULTIPOLYGON;
627  static const int NOW;
628  static const int NULLX;
629  static const int NUMERIC;
630  static const int OF;
631  static const int OFFSET;
632  static const int ON;
633  static const int OPEN;
634  static const int OPTIMIZE;
635  static const int OPTIMIZED;
636  static const int OPTION;
637  static const int ORDER;
638  static const int PARAMETER;
639  static const int POINT;
640  static const int POLYGON;
641  static const int PRECISION;
642  static const int PRIMARY;
643  static const int PRIVILEGES;
644  static const int PROCEDURE;
645  static const int SERVER;
646  static const int SMALLINT;
647  static const int SOME;
648  static const int TABLE;
649  static const int TEMPORARY;
650  static const int TEXT;
651  static const int THEN;
652  static const int TIME;
653  static const int TIMESTAMP;
654  static const int TINYINT;
655  static const int TO;
656  static const int TRUNCATE;
657  static const int UNION;
658  static const int PUBLIC;
659  static const int REAL;
660  static const int REFERENCES;
661  static const int RENAME;
662  static const int RESTORE;
663  static const int REVOKE;
664  static const int ROLE;
665  static const int ROLLBACK;
666  static const int SCHEMA;
667  static const int SELECT;
668  static const int SET;
669  static const int SHARD;
670  static const int SHARED;
671  static const int SHOW;
672  static const int UNIQUE;
673  static const int UPDATE;
674  static const int USER;
675  static const int VALIDATE;
676  static const int VALUES;
677  static const int VIEW;
678  static const int WHEN;
679  static const int WHENEVER;
680  static const int WHERE;
681  static const int WITH;
682  static const int WORK;
683  static const int EDIT;
684  static const int ACCESS;
685  static const int DASHBOARD;
686  static const int SQL;
687  static const int EDITOR;
688 
689  /* decl const */
690 #else
691  enum YY_Parser_ENUM_TOKEN {
692  YY_Parser_NULL_TOKEN = 0
693 
694  ,
695  NAME = 258,
696  DASHEDNAME = 259,
697  EMAIL = 260,
698  STRING = 261,
699  FWDSTR = 262,
700  SELECTSTRING = 263,
701  QUOTED_IDENTIFIER = 264,
702  INTNUM = 265,
703  FIXEDNUM = 266,
704  OR = 267,
705  AND = 268,
706  NOT = 269,
707  EQUAL = 270,
708  COMPARISON = 271,
709  UMINUS = 272,
710  ADD = 273,
711  ALL = 274,
712  ALTER = 275,
713  AMMSC = 276,
714  ANY = 277,
715  ARCHIVE = 278,
716  ARRAY = 279,
717  AS = 280,
718  ASC = 281,
719  AUTHORIZATION = 282,
720  BETWEEN = 283,
721  BIGINT = 284,
722  BOOLEAN = 285,
723  BY = 286,
724  CASE = 287,
725  CAST = 288,
726  CHAR_LENGTH = 289,
727  CHARACTER = 290,
728  CHECK = 291,
729  CLOSE = 292,
730  CLUSTER = 293,
731  COLUMN = 294,
732  COMMIT = 295,
733  CONTINUE = 296,
734  COPY = 297,
735  CREATE = 298,
736  CURRENT = 299,
737  CURSOR = 300,
738  DATABASE = 301,
739  DATAFRAME = 302,
740  DATE = 303,
741  DATETIME = 304,
742  DATE_TRUNC = 305,
743  DECIMAL = 306,
744  DECLARE = 307,
745  DEFAULT = 308,
746  DELETE = 309,
747  DESC = 310,
748  DICTIONARY = 311,
749  DISTINCT = 312,
750  DOUBLE = 313,
751  DROP = 314,
752  DUMP = 315,
753  ELSE = 316,
754  END = 317,
755  EXISTS = 318,
756  EXTRACT = 319,
757  FETCH = 320,
758  FIRST = 321,
759  FLOAT = 322,
760  FOR = 323,
761  FOREIGN = 324,
762  FOUND = 325,
763  FROM = 326,
764  GEOGRAPHY = 327,
765  GEOMETRY = 328,
766  GRANT = 329,
767  GROUP = 330,
768  HAVING = 331,
769  IF = 332,
770  ILIKE = 333,
771  IN = 334,
772  INSERT = 335,
773  INTEGER = 336,
774  INTO = 337,
775  IS = 338,
776  LANGUAGE = 339,
777  LAST = 340,
778  LENGTH = 341,
779  LIKE = 342,
780  LIMIT = 343,
781  LINESTRING = 344,
782  MOD = 345,
783  MULTIPOLYGON = 346,
784  NOW = 347,
785  NULLX = 348,
786  NUMERIC = 349,
787  OF = 350,
788  OFFSET = 351,
789  ON = 352,
790  OPEN = 353,
791  OPTIMIZE = 354,
792  OPTIMIZED = 355,
793  OPTION = 356,
794  ORDER = 357,
795  PARAMETER = 358,
796  POINT = 359,
797  POLYGON = 360,
798  PRECISION = 361,
799  PRIMARY = 362,
800  PRIVILEGES = 363,
801  PROCEDURE = 364,
802  SERVER = 365,
803  SMALLINT = 366,
804  SOME = 367,
805  TABLE = 368,
806  TEMPORARY = 369,
807  TEXT = 370,
808  THEN = 371,
809  TIME = 372,
810  TIMESTAMP = 373,
811  TINYINT = 374,
812  TO = 375,
813  TRUNCATE = 376,
814  UNION = 377,
815  PUBLIC = 378,
816  REAL = 379,
817  REFERENCES = 380,
818  RENAME = 381,
819  RESTORE = 382,
820  REVOKE = 383,
821  ROLE = 384,
822  ROLLBACK = 385,
823  SCHEMA = 386,
824  SELECT = 387,
825  SET = 388,
826  SHARD = 389,
827  SHARED = 390,
828  SHOW = 391,
829  UNIQUE = 392,
830  UPDATE = 393,
831  USER = 394,
832  VALIDATE = 395,
833  VALUES = 396,
834  VIEW = 397,
835  WHEN = 398,
836  WHENEVER = 399,
837  WHERE = 400,
838  WITH = 401,
839  WORK = 402,
840  EDIT = 403,
841  ACCESS = 404,
842  DASHBOARD = 405,
843  SQL = 406,
844  EDITOR = 407
845 
846  /* enum token */
847  }; /* end of enum declaration */
848 #endif
849  public:
851  virtual void YY_Parser_ERROR(const char* msg) YY_Parser_ERROR_BODY;
852 #ifdef YY_Parser_PURE
853 #ifdef YY_Parser_LSP_NEEDED
855  YY_Parser_LTYPE* YY_Parser_LLOC) YY_Parser_LEX_BODY;
856 #else
857  virtual int YY_Parser_LEX(YY_Parser_STYPE* YY_Parser_LVAL) YY_Parser_LEX_BODY;
858 #endif
859 #else
860  virtual int YY_Parser_LEX() YY_Parser_LEX_BODY;
862 #ifdef YY_Parser_LSP_NEEDED
863  YY_Parser_LTYPE YY_Parser_LLOC;
864 #endif
865  int YY_Parser_NERRS;
866  int YY_Parser_CHAR;
867 #endif
868 #if YY_Parser_DEBUG != 0
869  int YY_Parser_DEBUG_FLAG; /* nonzero means print parse trace */
870 #endif
871  public:
872  YY_Parser_CLASS(YY_Parser_CONSTRUCTOR_PARAM);
873 
874  public:
876 };
877 /* other declare folow */
878 #if YY_Parser_USE_CONST_TOKEN != 0
879 
880 const int YY_Parser_CLASS::NAME = 258;
881 const int YY_Parser_CLASS::DASHEDNAME = 259;
882 const int YY_Parser_CLASS::EMAIL = 260;
883 const int YY_Parser_CLASS::STRING = 261;
884 const int YY_Parser_CLASS::FWDSTR = 262;
885 const int YY_Parser_CLASS::SELECTSTRING = 263;
886 const int YY_Parser_CLASS::QUOTED_IDENTIFIER = 264;
887 const int YY_Parser_CLASS::INTNUM = 265;
888 const int YY_Parser_CLASS::FIXEDNUM = 266;
889 const int YY_Parser_CLASS::OR = 267;
890 const int YY_Parser_CLASS::AND = 268;
891 const int YY_Parser_CLASS::NOT = 269;
892 const int YY_Parser_CLASS::EQUAL = 270;
893 const int YY_Parser_CLASS::COMPARISON = 271;
894 const int YY_Parser_CLASS::UMINUS = 272;
895 const int YY_Parser_CLASS::ADD = 273;
896 const int YY_Parser_CLASS::ALL = 274;
897 const int YY_Parser_CLASS::ALTER = 275;
898 const int YY_Parser_CLASS::AMMSC = 276;
899 const int YY_Parser_CLASS::ANY = 277;
900 const int YY_Parser_CLASS::ARCHIVE = 278;
901 const int YY_Parser_CLASS::ARRAY = 279;
902 const int YY_Parser_CLASS::AS = 280;
903 const int YY_Parser_CLASS::ASC = 281;
904 const int YY_Parser_CLASS::AUTHORIZATION = 282;
905 const int YY_Parser_CLASS::BETWEEN = 283;
906 const int YY_Parser_CLASS::BIGINT = 284;
907 const int YY_Parser_CLASS::BOOLEAN = 285;
908 const int YY_Parser_CLASS::BY = 286;
909 const int YY_Parser_CLASS::CASE = 287;
910 const int YY_Parser_CLASS::CAST = 288;
911 const int YY_Parser_CLASS::CHAR_LENGTH = 289;
912 const int YY_Parser_CLASS::CHARACTER = 290;
913 const int YY_Parser_CLASS::CHECK = 291;
914 const int YY_Parser_CLASS::CLOSE = 292;
915 const int YY_Parser_CLASS::CLUSTER = 293;
916 const int YY_Parser_CLASS::COLUMN = 294;
917 const int YY_Parser_CLASS::COMMIT = 295;
918 const int YY_Parser_CLASS::CONTINUE = 296;
919 const int YY_Parser_CLASS::COPY = 297;
920 const int YY_Parser_CLASS::CREATE = 298;
921 const int YY_Parser_CLASS::CURRENT = 299;
922 const int YY_Parser_CLASS::CURSOR = 300;
923 const int YY_Parser_CLASS::DATABASE = 301;
924 const int YY_Parser_CLASS::DATAFRAME = 302;
925 const int YY_Parser_CLASS::DATE = 303;
926 const int YY_Parser_CLASS::DATETIME = 304;
927 const int YY_Parser_CLASS::DATE_TRUNC = 305;
928 const int YY_Parser_CLASS::DECIMAL = 306;
929 const int YY_Parser_CLASS::DECLARE = 307;
930 const int YY_Parser_CLASS::DEFAULT = 308;
931 const int YY_Parser_CLASS::DELETE = 309;
932 const int YY_Parser_CLASS::DESC = 310;
933 const int YY_Parser_CLASS::DICTIONARY = 311;
934 const int YY_Parser_CLASS::DISTINCT = 312;
935 const int YY_Parser_CLASS::DOUBLE = 313;
936 const int YY_Parser_CLASS::DROP = 314;
937 const int YY_Parser_CLASS::DUMP = 315;
938 const int YY_Parser_CLASS::ELSE = 316;
939 const int YY_Parser_CLASS::END = 317;
940 const int YY_Parser_CLASS::EXISTS = 318;
941 const int YY_Parser_CLASS::EXTRACT = 319;
942 const int YY_Parser_CLASS::FETCH = 320;
943 const int YY_Parser_CLASS::FIRST = 321;
944 const int YY_Parser_CLASS::FLOAT = 322;
945 const int YY_Parser_CLASS::FOR = 323;
946 const int YY_Parser_CLASS::FOREIGN = 324;
947 const int YY_Parser_CLASS::FOUND = 325;
948 const int YY_Parser_CLASS::FROM = 326;
949 const int YY_Parser_CLASS::GEOGRAPHY = 327;
950 const int YY_Parser_CLASS::GEOMETRY = 328;
951 const int YY_Parser_CLASS::GRANT = 329;
952 const int YY_Parser_CLASS::GROUP = 330;
953 const int YY_Parser_CLASS::HAVING = 331;
954 const int YY_Parser_CLASS::IF = 332;
955 const int YY_Parser_CLASS::ILIKE = 333;
956 const int YY_Parser_CLASS::IN = 334;
957 const int YY_Parser_CLASS::INSERT = 335;
958 const int YY_Parser_CLASS::INTEGER = 336;
959 const int YY_Parser_CLASS::INTO = 337;
960 const int YY_Parser_CLASS::IS = 338;
961 const int YY_Parser_CLASS::LANGUAGE = 339;
962 const int YY_Parser_CLASS::LAST = 340;
963 const int YY_Parser_CLASS::LENGTH = 341;
964 const int YY_Parser_CLASS::LIKE = 342;
965 const int YY_Parser_CLASS::LIMIT = 343;
966 const int YY_Parser_CLASS::LINESTRING = 344;
967 const int YY_Parser_CLASS::MOD = 345;
968 const int YY_Parser_CLASS::MULTIPOLYGON = 346;
969 const int YY_Parser_CLASS::NOW = 347;
970 const int YY_Parser_CLASS::NULLX = 348;
971 const int YY_Parser_CLASS::NUMERIC = 349;
972 const int YY_Parser_CLASS::OF = 350;
973 const int YY_Parser_CLASS::OFFSET = 351;
974 const int YY_Parser_CLASS::ON = 352;
975 const int YY_Parser_CLASS::OPEN = 353;
976 const int YY_Parser_CLASS::OPTIMIZE = 354;
977 const int YY_Parser_CLASS::OPTIMIZED = 355;
978 const int YY_Parser_CLASS::OPTION = 356;
979 const int YY_Parser_CLASS::ORDER = 357;
980 const int YY_Parser_CLASS::PARAMETER = 358;
981 const int YY_Parser_CLASS::POINT = 359;
982 const int YY_Parser_CLASS::POLYGON = 360;
983 const int YY_Parser_CLASS::PRECISION = 361;
984 const int YY_Parser_CLASS::PRIMARY = 362;
985 const int YY_Parser_CLASS::PRIVILEGES = 363;
986 const int YY_Parser_CLASS::PROCEDURE = 364;
987 const int YY_Parser_CLASS::SERVER = 365;
988 const int YY_Parser_CLASS::SMALLINT = 366;
989 const int YY_Parser_CLASS::SOME = 367;
990 const int YY_Parser_CLASS::TABLE = 368;
991 const int YY_Parser_CLASS::TEMPORARY = 369;
992 const int YY_Parser_CLASS::TEXT = 370;
993 const int YY_Parser_CLASS::THEN = 371;
994 const int YY_Parser_CLASS::TIME = 372;
995 const int YY_Parser_CLASS::TIMESTAMP = 373;
996 const int YY_Parser_CLASS::TINYINT = 374;
997 const int YY_Parser_CLASS::TO = 375;
998 const int YY_Parser_CLASS::TRUNCATE = 376;
999 const int YY_Parser_CLASS::UNION = 377;
1000 const int YY_Parser_CLASS::PUBLIC = 378;
1001 const int YY_Parser_CLASS::REAL = 379;
1002 const int YY_Parser_CLASS::REFERENCES = 380;
1003 const int YY_Parser_CLASS::RENAME = 381;
1004 const int YY_Parser_CLASS::RESTORE = 382;
1005 const int YY_Parser_CLASS::REVOKE = 383;
1006 const int YY_Parser_CLASS::ROLE = 384;
1007 const int YY_Parser_CLASS::ROLLBACK = 385;
1008 const int YY_Parser_CLASS::SCHEMA = 386;
1009 const int YY_Parser_CLASS::SELECT = 387;
1010 const int YY_Parser_CLASS::SET = 388;
1011 const int YY_Parser_CLASS::SHARD = 389;
1012 const int YY_Parser_CLASS::SHARED = 390;
1013 const int YY_Parser_CLASS::SHOW = 391;
1014 const int YY_Parser_CLASS::UNIQUE = 392;
1015 const int YY_Parser_CLASS::UPDATE = 393;
1016 const int YY_Parser_CLASS::USER = 394;
1017 const int YY_Parser_CLASS::VALIDATE = 395;
1018 const int YY_Parser_CLASS::VALUES = 396;
1019 const int YY_Parser_CLASS::VIEW = 397;
1020 const int YY_Parser_CLASS::WHEN = 398;
1021 const int YY_Parser_CLASS::WHENEVER = 399;
1022 const int YY_Parser_CLASS::WHERE = 400;
1023 const int YY_Parser_CLASS::WITH = 401;
1024 const int YY_Parser_CLASS::WORK = 402;
1025 const int YY_Parser_CLASS::EDIT = 403;
1026 const int YY_Parser_CLASS::ACCESS = 404;
1027 const int YY_Parser_CLASS::DASHBOARD = 405;
1028 const int YY_Parser_CLASS::SQL = 406;
1029 const int YY_Parser_CLASS::EDITOR = 407;
1030 
1031 /* const YY_Parser_CLASS::token */
1032 #endif
1033 /*apres const */
1034 YY_Parser_CLASS::YY_Parser_CLASS(YY_Parser_CONSTRUCTOR_PARAM) YY_Parser_CONSTRUCTOR_INIT {
1035 #if YY_Parser_DEBUG != 0
1037 #endif
1038  YY_Parser_CONSTRUCTOR_CODE;
1039 };
1040 #endif
1041 
1042 #define YYFINAL 686
1043 #define YYFLAG -32768
1044 #define YYNTBASE 167
1045 
1046 #define YYTRANSLATE(x) ((unsigned)(x) <= 407 ? yytranslate[x] : 288)
1047 
1048 static const short yytranslate[] = {
1049  0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
1050  2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
1051  2, 2, 2, 21, 2, 2, 159, 160, 19, 17, 161, 18, 166, 20, 2, 2, 2,
1052  2, 2, 2, 2, 2, 2, 2, 2, 158, 2, 2, 2, 2, 2, 2, 2, 2,
1053  2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
1054  2, 2, 2, 2, 2, 2, 162, 2, 163, 2, 2, 2, 2, 2, 2, 2, 2,
1055  2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
1056  2, 2, 2, 2, 164, 2, 165, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
1057  2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
1058  2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
1059  2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
1060  2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
1061  2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
1062  2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
1063  2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2,
1064  2, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16,
1065  22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38,
1066  39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55,
1067  56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72,
1068  73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89,
1069  90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106,
1070  107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, 122, 123,
1071  124, 125, 126, 127, 128, 129, 130, 131, 132, 133, 134, 135, 136, 137, 138, 139, 140,
1072  141, 142, 143, 144, 145, 146, 147, 148, 149, 150, 151, 152, 153, 154, 155, 156, 157};
1073 
1074 #if YY_Parser_DEBUG != 0
1075 static const short yyprhs[] = {
1076  0, 0, 3, 7, 9, 11, 13, 15, 17, 19, 21, 23, 25, 27,
1077  29, 31, 33, 35, 37, 39, 41, 43, 45, 47, 49, 51, 53, 55,
1078  57, 59, 61, 63, 68, 76, 81, 88, 95, 99, 106, 113, 115, 119,
1079  123, 127, 128, 130, 131, 140, 150, 160, 170, 175, 178, 179, 184, 188,
1080  195, 204, 205, 207, 209, 213, 220, 228, 233, 235, 239, 243, 249, 257,
1081  259, 261, 268, 275, 279, 283, 291, 299, 304, 309, 314, 318, 320, 324,
1082  326, 328, 332, 337, 340, 346, 347, 350, 354, 359, 362, 365, 368, 373,
1083  376, 382, 387, 393, 401, 412, 418, 429, 434, 436, 440, 445, 446, 451,
1084  452, 456, 457, 461, 463, 467, 471, 475, 476, 478, 480, 481, 484, 487,
1085  489, 491, 493, 495, 497, 502, 511, 517, 518, 520, 522, 524, 528, 532,
1086  538, 539, 541, 544, 547, 548, 551, 555, 556, 561, 563, 567, 572, 574,
1087  578, 586, 588, 590, 593, 595, 599, 601, 604, 607, 608, 612, 614, 618,
1088  619, 622, 626, 630, 633, 637, 639, 641, 643, 645, 647, 649, 651, 653,
1089  655, 659, 663, 670, 676, 682, 687, 693, 698, 699, 702, 707, 711, 716,
1090  720, 727, 733, 735, 739, 744, 749, 751, 753, 755, 757, 759, 762, 766,
1091  771, 777, 780, 781, 786, 795, 802, 807, 812, 817, 821, 825, 829, 833,
1092  837, 844, 847, 850, 852, 854, 856, 860, 867, 869, 871, 873, 874, 876,
1093  879, 883, 884, 886, 890, 892, 894, 899, 905, 911, 916, 918, 920, 924,
1094  929, 931, 933, 935, 938, 942, 947, 949, 951, 955, 956, 958, 960, 962,
1095  963, 965, 967, 969, 971, 973, 975, 979, 981, 983, 985, 989, 991, 993,
1096  995, 999, 1001, 1004, 1006, 1008, 1010, 1012, 1014, 1016, 1018, 1020, 1022, 1024,
1097  1026, 1029, 1032, 1035, 1038, 1041, 1044, 1047, 1050, 1053, 1056, 1059, 1063, 1065,
1098  1067, 1069, 1071, 1073, 1075, 1077, 1079, 1083, 1087, 1089, 1091, 1093, 1095, 1097,
1099  1102, 1104, 1109, 1116, 1118, 1123, 1130, 1132, 1134, 1136, 1138, 1140, 1143, 1145,
1100  1147, 1149, 1154, 1156, 1161, 1163, 1165, 1169, 1174, 1176, 1178, 1180, 1182, 1187,
1101  1194, 1199, 1206, 1208, 1210};
1102 
1103 static const short yyrhs[] = {
1104  168, 158, 0, 167, 168, 158, 0, 179, 0, 180, 0, 181, 0, 182, 0, 214, 0,
1105  184, 0, 185, 0, 186, 0, 187, 0, 190, 0, 191, 0, 194, 0, 169, 0, 170,
1106  0, 171, 0, 172, 0, 173, 0, 174, 0, 198, 0, 199, 0, 200, 0, 201, 0,
1107  202, 0, 204, 0, 205, 0, 203, 0, 196, 0, 197, 0, 48, 51, 177, 3, 0,
1108  48, 51, 177, 3, 159, 175, 160, 0, 64, 51, 183, 3, 0, 25, 51, 3, 131,
1109  125, 3, 0, 48, 144, 272, 159, 175, 160, 0, 64, 144, 272, 0, 25, 144, 272,
1110  159, 175, 160, 0, 25, 144, 272, 131, 125, 272, 0, 176, 0, 175, 161, 176, 0,
1111  3, 15, 267, 0, 82, 14, 68, 0, 0, 119, 0, 0, 48, 178, 118, 177, 270,
1112  30, 8, 213, 0, 48, 178, 118, 177, 270, 159, 206, 160, 213, 0, 48, 3, 118,
1113  177, 270, 159, 206, 160, 213, 0, 48, 52, 270, 159, 206, 160, 76, 6, 213, 0,
1114  141, 48, 118, 270, 0, 82, 68, 0, 0, 64, 118, 183, 270, 0, 126, 118, 270,
1115  0, 25, 118, 270, 131, 125, 270, 0, 25, 118, 270, 131, 44, 286, 125, 286, 0,
1116  0, 44, 0, 208, 0, 189, 161, 208, 0, 25, 118, 270, 23, 188, 208, 0, 25,
1117  118, 270, 23, 159, 189, 160, 0, 25, 118, 270, 192, 0, 193, 0, 192, 161, 193,
1118  0, 64, 188, 286, 0, 47, 270, 76, 6, 213, 0, 47, 159, 7, 160, 125, 6,
1119  213, 0, 65, 0, 28, 0, 195, 118, 270, 125, 6, 213, 0, 132, 118, 270, 76,
1120  6, 213, 0, 48, 134, 274, 0, 64, 134, 274, 0, 79, 277, 102, 279, 280, 125,
1121  275, 0, 133, 277, 102, 279, 280, 76, 275, 0, 79, 273, 125, 275, 0, 133, 273,
1122  76, 275, 0, 104, 118, 271, 213, 0, 145, 43, 213, 0, 207, 0, 206, 161, 207,
1123  0, 208, 0, 211, 0, 286, 283, 209, 0, 286, 283, 210, 209, 0, 3, 3, 0,
1124  3, 3, 159, 10, 160, 0, 0, 14, 98, 0, 14, 98, 142, 0, 14, 98, 112,
1125  3, 0, 58, 267, 0, 58, 98, 0, 58, 144, 0, 41, 159, 243, 160, 0, 130,
1126  270, 0, 130, 270, 159, 286, 160, 0, 142, 159, 212, 160, 0, 112, 3, 159, 212,
1127  160, 0, 74, 3, 159, 212, 160, 130, 270, 0, 74, 3, 159, 212, 160, 130, 270,
1128  159, 212, 160, 0, 139, 3, 159, 286, 160, 0, 140, 61, 159, 286, 160, 130, 270,
1129  159, 286, 160, 0, 41, 159, 243, 160, 0, 286, 0, 212, 161, 286, 0, 151, 159,
1130  175, 160, 0, 0, 64, 147, 183, 270, 0, 0, 159, 212, 160, 0, 0, 107, 36,
1131  217, 0, 218, 0, 217, 161, 218, 0, 10, 219, 220, 0, 281, 219, 220, 0, 0,
1132  31, 0, 60, 0, 0, 98, 71, 0, 98, 90, 0, 221, 0, 222, 0, 223, 0,
1133  231, 0, 227, 0, 59, 76, 270, 228, 0, 85, 87, 270, 215, 146, 159, 251, 160,
1134  0, 85, 87, 270, 215, 8, 0, 0, 24, 0, 62, 0, 226, 0, 225, 161, 226,
1135  0, 286, 15, 243, 0, 143, 270, 138, 225, 228, 0, 0, 239, 0, 93, 10, 0,
1136  93, 24, 0, 0, 101, 10, 0, 101, 10, 3, 0, 0, 232, 216, 229, 230, 0,
1137  233, 0, 232, 127, 233, 0, 232, 127, 24, 233, 0, 234, 0, 159, 232, 160, 0,
1138  137, 224, 235, 236, 228, 240, 242, 0, 264, 0, 19, 0, 76, 237, 0, 238, 0,
1139  237, 161, 238, 0, 270, 0, 270, 287, 0, 150, 243, 0, 0, 80, 36, 241, 0,
1140  243, 0, 241, 161, 243, 0, 0, 81, 243, 0, 243, 12, 243, 0, 243, 13, 243,
1141  0, 14, 243, 0, 159, 243, 160, 0, 244, 0, 245, 0, 246, 0, 247, 0, 249,
1142  0, 250, 0, 252, 0, 255, 0, 262, 0, 262, 253, 262, 0, 262, 253, 256, 0,
1143  262, 14, 33, 262, 13, 262, 0, 262, 33, 262, 13, 262, 0, 262, 14, 92, 265,
1144  248, 0, 262, 92, 265, 248, 0, 262, 14, 83, 265, 248, 0, 262, 83, 265, 248,
1145  0, 0, 3, 265, 0, 281, 88, 14, 98, 0, 281, 88, 98, 0, 262, 14, 84,
1146  256, 0, 262, 84, 256, 0, 262, 14, 84, 159, 251, 160, 0, 262, 84, 159, 251,
1147  160, 0, 265, 0, 251, 161, 265, 0, 262, 253, 254, 256, 0, 262, 253, 254, 262,
1148  0, 15, 0, 16, 0, 27, 0, 24, 0, 117, 0, 68, 256, 0, 159, 234, 160,
1149  0, 148, 243, 121, 243, 0, 257, 148, 243, 121, 243, 0, 66, 243, 0, 0, 37,
1150  257, 258, 67, 0, 82, 159, 243, 161, 243, 161, 243, 160, 0, 82, 159, 243, 161,
1151  243, 160, 0, 39, 159, 262, 160, 0, 91, 159, 262, 160, 0, 281, 162, 262, 163,
1152  0, 262, 17, 262, 0, 262, 18, 262, 0, 262, 19, 262, 0, 262, 20, 262, 0,
1153  262, 21, 262, 0, 95, 159, 262, 161, 262, 160, 0, 17, 262, 0, 18, 262, 0,
1154  265, 0, 281, 0, 266, 0, 159, 262, 160, 0, 38, 159, 243, 30, 283, 160, 0,
1155  259, 0, 260, 0, 261, 0, 0, 243, 0, 243, 3, 0, 243, 30, 3, 0, 0,
1156  263, 0, 264, 161, 263, 0, 267, 0, 144, 0, 3, 159, 19, 160, 0, 3, 159,
1157  62, 243, 160, 0, 3, 159, 24, 243, 160, 0, 3, 159, 243, 160, 0, 6, 0,
1158  10, 0, 97, 159, 160, 0, 54, 159, 243, 160, 0, 11, 0, 72, 0, 63, 0,
1159  283, 6, 0, 164, 269, 165, 0, 29, 162, 269, 163, 0, 98, 0, 267, 0, 268,
1160  161, 267, 0, 0, 268, 0, 3, 0, 9, 0, 0, 270, 0, 3, 0, 5, 0,
1161  4, 0, 9, 0, 274, 0, 273, 161, 274, 0, 3, 0, 4, 0, 276, 0, 275,
1162  161, 276, 0, 272, 0, 274, 0, 278, 0, 277, 161, 278, 0, 24, 0, 24, 113,
1163  0, 48, 0, 137, 0, 85, 0, 126, 0, 143, 0, 59, 0, 25, 0, 64, 0,
1164  147, 0, 153, 0, 154, 0, 25, 115, 0, 48, 115, 0, 48, 118, 0, 48, 147,
1165  0, 137, 147, 0, 64, 147, 0, 64, 115, 0, 48, 155, 0, 153, 155, 0, 147,
1166  155, 0, 59, 155, 0, 147, 156, 157, 0, 51, 0, 118, 0, 155, 0, 147, 0,
1167  115, 0, 3, 0, 10, 0, 3, 0, 3, 166, 3, 0, 3, 166, 19, 0, 10,
1168  0, 34, 0, 120, 0, 35, 0, 40, 0, 40, 159, 282, 160, 0, 99, 0, 99,
1169  159, 282, 160, 0, 99, 159, 282, 161, 282, 160, 0, 56, 0, 56, 159, 282, 160,
1170  0, 56, 159, 282, 161, 282, 160, 0, 86, 0, 124, 0, 116, 0, 72, 0, 129,
1171  0, 63, 111, 0, 63, 0, 53, 0, 122, 0, 122, 159, 282, 160, 0, 123, 0,
1172  123, 159, 282, 160, 0, 284, 0, 285, 0, 283, 162, 163, 0, 283, 162, 282, 163,
1173  0, 109, 0, 94, 0, 110, 0, 96, 0, 77, 159, 284, 160, 0, 77, 159, 284,
1174  161, 10, 160, 0, 78, 159, 284, 160, 0, 78, 159, 284, 161, 10, 160, 0, 3,
1175  0, 9, 0, 3, 0};
1176 
1177 #endif
1178 
1179 #if YY_Parser_DEBUG != 0
1180 static const short yyrline[] = {
1181  0, 120, 122, 130, 132, 133, 134, 136, 137, 138, 139, 140, 141, 142,
1182  143, 144, 145, 146, 147, 148, 149, 150, 151, 152, 153, 154, 155, 156,
1183  157, 158, 159, 185, 190, 195, 201, 208, 214, 220, 225, 232, 237, 243,
1184  246, 248, 251, 253, 256, 263, 268, 274, 281, 287, 289, 292, 298, 304,
1185  311, 318, 319, 321, 323, 330, 335, 341, 345, 347, 350, 353, 358, 368,
1186  369, 371, 378, 385, 391, 397, 403, 409, 415, 422, 429, 436, 438, 445,
1187  447, 450, 453, 457, 465, 472, 475, 477, 478, 484, 485, 486, 487, 488,
1188  489, 492, 495, 501, 508, 514, 522, 529, 533, 535, 542, 545, 549, 556,
1189  558, 613, 615, 618, 620, 627, 630, 634, 636, 637, 640, 642, 643, 648,
1190  651, 657, 660, 662, 683, 688, 693, 715, 717, 718, 728, 731, 738, 743,
1191  759, 761, 764, 766, 767, 769, 771, 778, 784, 791, 793, 795, 799, 801,
1192  804, 816, 818, 821, 825, 827, 834, 836, 839, 843, 845, 848, 850, 857,
1193  859, 864, 867, 869, 871, 872, 875, 877, 878, 879, 880, 881, 882, 883,
1194  886, 889, 896, 899, 903, 906, 908, 910, 914, 916, 928, 930, 933, 936,
1195  948, 950, 954, 956, 963, 968, 974, 976, 979, 981, 982, 985, 989, 993,
1196  998, 1004, 1006, 1009, 1013, 1018, 1025, 1027, 1032, 1040, 1042, 1043, 1044, 1045,
1197  1046, 1047, 1048, 1049, 1050, 1051, 1052, 1053, 1055, 1056, 1057, 1060, 1062, 1063,
1198  1064, 1067, 1069, 1070, 1077, 1079, 1092, 1094, 1095, 1096, 1099, 1101, 1102, 1103,
1199  1104, 1105, 1106, 1107, 1108, 1109, 1110, 1113, 1115, 1122, 1124, 1129, 1139, 1142,
1200  1144, 1146, 1147, 1147, 1147, 1150, 1152, 1159, 1160, 1163, 1165, 1172, 1173, 1176,
1201  1178, 1185, 1187, 1188, 1189, 1190, 1191, 1192, 1193, 1194, 1195, 1196, 1197, 1198,
1202  1199, 1200, 1201, 1202, 1203, 1204, 1205, 1206, 1207, 1208, 1209, 1210, 1213, 1215,
1203  1216, 1217, 1218, 1221, 1223, 1227, 1229, 1230, 1234, 1243, 1245, 1246, 1247, 1248,
1204  1249, 1250, 1251, 1252, 1253, 1254, 1255, 1256, 1257, 1258, 1260, 1261, 1262, 1263,
1205  1264, 1265, 1266, 1267, 1268, 1270, 1271, 1278, 1288, 1289, 1290, 1291, 1294, 1296,
1206  1299, 1301, 1306, 1315, 1330};
1207 
1208 static const char* const yytname[] = {"$",
1209  "error",
1210  "$illegal.",
1211  "NAME",
1212  "DASHEDNAME",
1213  "EMAIL",
1214  "STRING",
1215  "FWDSTR",
1216  "SELECTSTRING",
1217  "QUOTED_IDENTIFIER",
1218  "INTNUM",
1219  "FIXEDNUM",
1220  "OR",
1221  "AND",
1222  "NOT",
1223  "EQUAL",
1224  "COMPARISON",
1225  "'+'",
1226  "'-'",
1227  "'*'",
1228  "'/'",
1229  "'%'",
1230  "UMINUS",
1231  "ADD",
1232  "ALL",
1233  "ALTER",
1234  "AMMSC",
1235  "ANY",
1236  "ARCHIVE",
1237  "ARRAY",
1238  "AS",
1239  "ASC",
1240  "AUTHORIZATION",
1241  "BETWEEN",
1242  "BIGINT",
1243  "BOOLEAN",
1244  "BY",
1245  "CASE",
1246  "CAST",
1247  "CHAR_LENGTH",
1248  "CHARACTER",
1249  "CHECK",
1250  "CLOSE",
1251  "CLUSTER",
1252  "COLUMN",
1253  "COMMIT",
1254  "CONTINUE",
1255  "COPY",
1256  "CREATE",
1257  "CURRENT",
1258  "CURSOR",
1259  "DATABASE",
1260  "DATAFRAME",
1261  "DATE",
1262  "DATETIME",
1263  "DATE_TRUNC",
1264  "DECIMAL",
1265  "DECLARE",
1266  "DEFAULT",
1267  "DELETE",
1268  "DESC",
1269  "DICTIONARY",
1270  "DISTINCT",
1271  "DOUBLE",
1272  "DROP",
1273  "DUMP",
1274  "ELSE",
1275  "END",
1276  "EXISTS",
1277  "EXTRACT",
1278  "FETCH",
1279  "FIRST",
1280  "FLOAT",
1281  "FOR",
1282  "FOREIGN",
1283  "FOUND",
1284  "FROM",
1285  "GEOGRAPHY",
1286  "GEOMETRY",
1287  "GRANT",
1288  "GROUP",
1289  "HAVING",
1290  "IF",
1291  "ILIKE",
1292  "IN",
1293  "INSERT",
1294  "INTEGER",
1295  "INTO",
1296  "IS",
1297  "LANGUAGE",
1298  "LAST",
1299  "LENGTH",
1300  "LIKE",
1301  "LIMIT",
1302  "LINESTRING",
1303  "MOD",
1304  "MULTIPOLYGON",
1305  "NOW",
1306  "NULLX",
1307  "NUMERIC",
1308  "OF",
1309  "OFFSET",
1310  "ON",
1311  "OPEN",
1312  "OPTIMIZE",
1313  "OPTIMIZED",
1314  "OPTION",
1315  "ORDER",
1316  "PARAMETER",
1317  "POINT",
1318  "POLYGON",
1319  "PRECISION",
1320  "PRIMARY",
1321  "PRIVILEGES",
1322  "PROCEDURE",
1323  "SERVER",
1324  "SMALLINT",
1325  "SOME",
1326  "TABLE",
1327  "TEMPORARY",
1328  "TEXT",
1329  "THEN",
1330  "TIME",
1331  "TIMESTAMP",
1332  "TINYINT",
1333  "TO",
1334  "TRUNCATE",
1335  "UNION",
1336  "PUBLIC",
1337  "REAL",
1338  "REFERENCES",
1339  "RENAME",
1340  "RESTORE",
1341  "REVOKE",
1342  "ROLE",
1343  "ROLLBACK",
1344  "SCHEMA",
1345  "SELECT",
1346  "SET",
1347  "SHARD",
1348  "SHARED",
1349  "SHOW",
1350  "UNIQUE",
1351  "UPDATE",
1352  "USER",
1353  "VALIDATE",
1354  "VALUES",
1355  "VIEW",
1356  "WHEN",
1357  "WHENEVER",
1358  "WHERE",
1359  "WITH",
1360  "WORK",
1361  "EDIT",
1362  "ACCESS",
1363  "DASHBOARD",
1364  "SQL",
1365  "EDITOR",
1366  "';'",
1367  "'('",
1368  "')'",
1369  "','",
1370  "'['",
1371  "']'",
1372  "'{'",
1373  "'}'",
1374  "'.'",
1375  "sql_list",
1376  "sql",
1377  "create_database_statement",
1378  "drop_database_statement",
1379  "rename_database_statement",
1380  "create_user_statement",
1381  "drop_user_statement",
1382  "alter_user_statement",
1383  "name_eq_value_list",
1384  "name_eq_value",
1385  "opt_if_not_exists",
1386  "opt_temporary",
1387  "create_table_as_statement",
1388  "create_table_statement",
1389  "create_dataframe_statement",
1390  "show_table_schema",
1391  "opt_if_exists",
1392  "drop_table_statement",
1393  "truncate_table_statement",
1394  "rename_table_statement",
1395  "rename_column_statement",
1396  "opt_column",
1397  "column_defs",
1398  "add_column_statement",
1399  "drop_column_statement",
1400  "drop_columns",
1401  "drop_column",
1402  "copy_table_statement",
1403  "dump_or_archive",
1404  "dump_table_statement",
1405  "restore_table_statement",
1406  "create_role_statement",
1407  "drop_role_statement",
1408  "grant_privileges_statement",
1409  "revoke_privileges_statement",
1410  "grant_role_statement",
1411  "revoke_role_statement",
1412  "optimize_table_statement",
1413  "validate_system_statement",
1414  "base_table_element_commalist",
1415  "base_table_element",
1416  "column_def",
1417  "opt_compression",
1418  "column_constraint_def",
1419  "table_constraint_def",
1420  "column_commalist",
1421  "opt_with_option_list",
1422  "drop_view_statement",
1423  "opt_column_commalist",
1424  "opt_order_by_clause",
1425  "ordering_spec_commalist",
1426  "ordering_spec",
1427  "opt_asc_desc",
1428  "opt_null_order",
1429  "manipulative_statement",
1430  "delete_statement",
1431  "insert_statement",
1432  "opt_all_distinct",
1433  "assignment_commalist",
1434  "assignment",
1435  "update_statement",
1436  "opt_where_clause",
1437  "opt_limit_clause",
1438  "opt_offset_clause",
1439  "select_statement",
1440  "query_exp",
1441  "query_term",
1442  "query_spec",
1443  "selection",
1444  "from_clause",
1445  "table_ref_commalist",
1446  "table_ref",
1447  "where_clause",
1448  "opt_group_by_clause",
1449  "exp_commalist",
1450  "opt_having_clause",
1451  "general_exp",
1452  "predicate",
1453  "comparison_predicate",
1454  "between_predicate",
1455  "like_predicate",
1456  "opt_escape",
1457  "test_for_null",
1458  "in_predicate",
1459  "atom_commalist",
1460  "all_or_any_predicate",
1461  "comparison",
1462  "any_all_some",
1463  "existence_test",
1464  "subquery",
1465  "when_then_list",
1466  "opt_else_expr",
1467  "case_exp",
1468  "charlength_exp",
1469  "array_at_exp",
1470  "scalar_exp",
1471  "select_entry",
1472  "select_entry_commalist",
1473  "atom",
1474  "function_ref",
1475  "literal",
1476  "literal_commalist",
1477  "opt_literal_commalist",
1478  "table",
1479  "opt_table",
1480  "username",
1481  "rolenames",
1482  "rolename",
1483  "grantees",
1484  "grantee",
1485  "privileges",
1486  "privilege",
1487  "privileges_target_type",
1488  "privileges_target",
1489  "column_ref",
1490  "non_neg_int",
1491  "data_type",
1492  "geo_type",
1493  "geometry_type",
1494  "column",
1495  "range_variable",
1496  "range_variable"};
1497 #endif
1498 
1499 static const short yyr1[] = {
1500  0, 167, 167, 168, 168, 168, 168, 168, 168, 168, 168, 168, 168, 168, 168, 168, 168,
1501  168, 168, 168, 168, 168, 168, 168, 168, 168, 168, 168, 168, 168, 168, 169, 169, 170,
1502  171, 172, 173, 174, 174, 175, 175, 176, 177, 177, 178, 178, 179, 180, 180, 181, 182,
1503  183, 183, 184, 185, 186, 187, 188, 188, 189, 189, 190, 190, 191, 192, 192, 193, 194,
1504  194, 195, 195, 196, 197, 198, 199, 200, 201, 202, 203, 204, 205, 206, 206, 207, 207,
1505  208, 208, 209, 209, 209, 210, 210, 210, 210, 210, 210, 210, 210, 210, 211, 211, 211,
1506  211, 211, 211, 211, 212, 212, 213, 213, 214, 215, 215, 216, 216, 217, 217, 218, 218,
1507  219, 219, 219, 220, 220, 220, 168, 221, 221, 221, 221, 222, 223, 223, 224, 224, 224,
1508  225, 225, 226, 227, 228, 228, 229, 229, 229, 230, 230, 230, 231, 232, 232, 232, 233,
1509  233, 234, 235, 235, 236, 237, 237, 238, 238, 239, 240, 240, 241, 241, 242, 242, 243,
1510  243, 243, 243, 243, 244, 244, 244, 244, 244, 244, 244, 244, 245, 245, 246, 246, 247,
1511  247, 247, 247, 248, 248, 249, 249, 250, 250, 250, 250, 251, 251, 252, 252, 253, 253,
1512  254, 254, 254, 255, 256, 257, 257, 258, 258, 259, 259, 259, 260, 260, 261, 262, 262,
1513  262, 262, 262, 262, 262, 262, 262, 262, 262, 262, 262, 262, 262, 262, 263, 263, 263,
1514  263, 264, 264, 264, 265, 265, 266, 266, 266, 266, 267, 267, 267, 267, 267, 267, 267,
1515  267, 267, 267, 267, 268, 268, 269, 269, 270, 270, 271, 271, 272, 272, 272, 272, 273,
1516  273, 274, 274, 275, 275, 276, 276, 277, 277, 278, 278, 278, 278, 278, 278, 278, 278,
1517  278, 278, 278, 278, 278, 278, 278, 278, 278, 278, 278, 278, 278, 278, 278, 278, 278,
1518  279, 279, 279, 279, 279, 280, 280, 281, 281, 281, 282, 283, 283, 283, 283, 283, 283,
1519  283, 283, 283, 283, 283, 283, 283, 283, 283, 283, 283, 283, 283, 283, 283, 283, 283,
1520  283, 283, 283, 283, 284, 284, 284, 284, -1, -1, 285, 285, 286, 286, 287};
1521 
1522 static const short yyr2[] = {
1523  0, 2, 3, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
1524  1, 1, 1, 4, 7, 4, 6, 6, 3, 6, 6, 1, 3, 3, 3, 0, 1, 0, 8, 9, 9, 9, 4, 2, 0, 4, 3, 6,
1525  8, 0, 1, 1, 3, 6, 7, 4, 1, 3, 3, 5, 7, 1, 1, 6, 6, 3, 3, 7, 7, 4, 4, 4, 3, 1, 3, 1,
1526  1, 3, 4, 2, 5, 0, 2, 3, 4, 2, 2, 2, 4, 2, 5, 4, 5, 7, 10, 5, 10, 4, 1, 3, 4, 0, 4, 0,
1527  3, 0, 3, 1, 3, 3, 3, 0, 1, 1, 0, 2, 2, 1, 1, 1, 1, 1, 4, 8, 5, 0, 1, 1, 1, 3, 3, 5,
1528  0, 1, 2, 2, 0, 2, 3, 0, 4, 1, 3, 4, 1, 3, 7, 1, 1, 2, 1, 3, 1, 2, 2, 0, 3, 1, 3, 0,
1529  2, 3, 3, 2, 3, 1, 1, 1, 1, 1, 1, 1, 1, 1, 3, 3, 6, 5, 5, 4, 5, 4, 0, 2, 4, 3, 4, 3,
1530  6, 5, 1, 3, 4, 4, 1, 1, 1, 1, 1, 2, 3, 4, 5, 2, 0, 4, 8, 6, 4, 4, 4, 3, 3, 3, 3, 3,
1531  6, 2, 2, 1, 1, 1, 3, 6, 1, 1, 1, 0, 1, 2, 3, 0, 1, 3, 1, 1, 4, 5, 5, 4, 1, 1, 3, 4,
1532  1, 1, 1, 2, 3, 4, 1, 1, 3, 0, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 3, 1, 1, 1, 3, 1, 1, 1,
1533  3, 1, 2, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 3, 1, 1,
1534  1, 1, 1, 1, 1, 1, 3, 3, 1, 1, 1, 1, 1, 4, 1, 4, 6, 1, 4, 6, 1, 1, 1, 1, 1, 2, 1, 1,
1535  1, 4, 1, 4, 1, 1, 3, 4, 1, 1, 1, 1, 4, 6, 4, 6, 1, 1, 1};
1536 
1537 static const short yydefact[] = {
1538  0, 0, 70, 0, 45, 0, 0, 69, 0, 0, 0, 0, 0, 0, 133, 0, 0,
1539  0, 0, 0, 0, 15, 16, 17, 18, 19, 20, 3, 4, 5, 6, 8, 9, 10,
1540  11, 12, 13, 14, 0, 29, 30, 21, 22, 23, 24, 25, 28, 26, 27, 7, 125,
1541  126, 127, 129, 128, 113, 149, 152, 0, 0, 0, 263, 264, 0, 0, 0, 43, 0,
1542  44, 0, 0, 0, 0, 52, 52, 0, 0, 52, 273, 274, 281, 289, 283, 288, 290,
1543  285, 286, 284, 287, 291, 292, 293, 0, 271, 0, 279, 0, 265, 0, 0, 0, 0,
1544  134, 135, 235, 0, 0, 109, 0, 0, 1, 0, 0, 0, 144, 0, 0, 267, 269,
1545  268, 270, 0, 0, 0, 43, 0, 0, 0, 73, 0, 43, 140, 0, 0, 0, 74,
1546  36, 0, 282, 294, 295, 296, 297, 301, 304, 300, 299, 298, 303, 0, 302, 0, 0,
1547  0, 0, 111, 266, 109, 54, 0, 0, 0, 313, 248, 249, 252, 0, 0, 0, 156,
1548  0, 317, 319, 0, 0, 0, 320, 335, 0, 325, 254, 0, 253, 0, 0, 328, 0,
1549  345, 0, 347, 0, 258, 322, 344, 346, 330, 318, 336, 338, 329, 332, 243, 0, 261,
1550  0, 236, 173, 174, 175, 176, 177, 178, 179, 180, 232, 233, 234, 181, 240, 155, 227,
1551  229, 242, 228, 0, 340, 341, 0, 0, 0, 80, 153, 2, 0, 0, 0, 150, 0,
1552  147, 0, 57, 57, 0, 63, 64, 0, 0, 0, 109, 0, 0, 31, 0, 0, 0,
1553  0, 130, 141, 51, 33, 53, 110, 305, 267, 269, 277, 278, 77, 275, 272, 306, 310,
1554  307, 309, 308, 0, 280, 0, 0, 79, 0, 78, 0, 0, 0, 171, 0, 225, 228,
1555  226, 261, 0, 212, 0, 0, 0, 0, 0, 333, 0, 207, 0, 0, 0, 0, 0,
1556  0, 0, 0, 0, 181, 259, 262, 0, 0, 140, 237, 0, 0, 0, 0, 202, 203,
1557  0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 235, 0, 0, 255, 0, 50, 352,
1558  353, 140, 136, 0, 0, 0, 313, 119, 114, 115, 119, 151, 142, 143, 0, 148, 0,
1559  58, 0, 0, 0, 0, 0, 0, 0, 0, 0, 39, 0, 67, 0, 42, 0, 0,
1560  0, 0, 0, 0, 0, 0, 81, 83, 84, 0, 0, 0, 162, 0, 311, 312, 0,
1561  0, 106, 132, 0, 109, 0, 0, 0, 0, 0, 314, 315, 0, 0, 0, 0, 0,
1562  0, 0, 0, 316, 0, 0, 0, 0, 0, 0, 0, 0, 250, 0, 0, 0, 172,
1563  230, 0, 256, 157, 158, 160, 163, 169, 170, 238, 0, 0, 0, 0, 219, 220, 221,
1564  222, 223, 0, 190, 0, 195, 190, 205, 204, 206, 0, 0, 183, 182, 241, 0, 193,
1565  0, 342, 0, 0, 139, 0, 0, 109, 120, 121, 122, 0, 122, 145, 34, 0, 59,
1566  61, 66, 0, 55, 65, 38, 0, 37, 0, 109, 0, 0, 0, 0, 0, 0, 0,
1567  0, 0, 0, 334, 331, 89, 35, 0, 0, 276, 0, 112, 0, 0, 72, 0, 244,
1568  0, 0, 247, 257, 0, 211, 0, 213, 0, 216, 321, 251, 326, 0, 208, 350, 0,
1569  0, 217, 0, 323, 0, 337, 339, 260, 0, 354, 161, 0, 167, 0, 190, 0, 194,
1570  190, 0, 0, 189, 0, 198, 187, 200, 201, 192, 218, 343, 137, 138, 108, 71, 0,
1571  117, 116, 118, 146, 62, 0, 0, 41, 40, 68, 0, 32, 0, 0, 0, 0, 0,
1572  0, 0, 82, 0, 0, 0, 0, 0, 85, 89, 109, 0, 75, 107, 0, 76, 246,
1573  245, 209, 0, 0, 0, 0, 0, 0, 0, 159, 0, 0, 154, 0, 188, 0, 186,
1574  185, 191, 197, 0, 123, 124, 60, 56, 109, 105, 0, 0, 0, 0, 99, 109, 87,
1575  90, 0, 94, 95, 93, 97, 86, 46, 109, 131, 210, 231, 327, 351, 215, 0, 224,
1576  324, 164, 165, 168, 184, 196, 199, 48, 0, 100, 103, 0, 49, 0, 0, 91, 0,
1577  0, 47, 0, 0, 0, 0, 0, 92, 96, 0, 214, 166, 101, 0, 88, 98, 0,
1578  0, 0, 0, 102, 104, 0, 0};
1579 
1580 static const short yydefgoto[] = {
1581  19, 20, 21, 22, 23, 24, 25, 26, 366, 367, 126, 71, 27, 28, 29, 30,
1582  133, 31, 32, 33, 34, 359, 474, 35, 36, 243, 244, 37, 38, 39, 40, 41,
1583  42, 43, 44, 45, 46, 47, 48, 379, 380, 381, 586, 587, 382, 391, 230, 49,
1584  278, 114, 348, 349, 469, 561, 50, 51, 52, 104, 341, 342, 53, 256, 238, 355,
1585  54, 55, 56, 57, 204, 315, 428, 429, 257, 539, 647, 607, 205, 206, 207, 208,
1586  209, 547, 210, 211, 548, 212, 332, 453, 213, 300, 292, 408, 214, 215, 216, 217,
1587  218, 219, 220, 221, 222, 312, 313, 430, 157, 265, 92, 266, 267, 268, 94, 95,
1588  275, 390, 223, 412, 224, 225, 226, 383, 537};
1589 
1590 static const short yypact[] = {
1591  1499, 167, -32768, 13, 204, -39, 160, -32768, 277, -7,
1592  18, 41, 103, 277, 28, 127, 317, 188, 139, 268,
1593  107, -32768, -32768, -32768, -32768, -32768, -32768, -32768, -32768, -32768,
1594  -32768, -32768, -32768, -32768, -32768, -32768, -32768, -32768, 172, -32768,
1595  -32768, -32768, -32768, -32768, -32768, -32768, -32768, -32768, -32768, -32768,
1596  -32768, -32768, -32768, -32768, -32768, 192, -32768, -32768, 300, 317,
1597  431, -32768, -32768, 324, 280, 272, 262, 317, -32768, 336,
1598  431, 274, 317, 288, 288, 336, 431, 288, -32768, -32768,
1599  286, 289, 132, 271, 117, -32768, -32768, 260, -32768, -84,
1600  282, -32768, -38, -32768, 97, -32768, 317, 317, 317, 317,
1601  -6, 123, -32768, -32768, 604, 292, 322, 314, 77, 265,
1602  -32768, 317, 441, 58, 374, 347, 66, -32768, -32768, -32768,
1603  -32768, 55, 325, 482, 262, 485, 493, 353, -32768, 362,
1604  262, 378, 433, 528, 317, -32768, -32768, 317, -32768, -32768,
1605  -32768, -32768, -32768, -32768, -32768, -32768, -32768, -32768, -32768, 390,
1606  -32768, 445, 336, 270, 752, 392, -32768, 314, -32768, 477,
1607  445, 270, 171, -32768, -32768, -32768, 829, 1054, 1054, -32768,
1608  393, -32768, -32768, 404, 397, 398, 400, -32768, 402, 405,
1609  11, 406, 20, 407, 409, -32768, 410, -32768, 417, -32768,
1610  418, -32768, 419, -32768, -32768, -32768, -32768, 420, 421, -32768,
1611  -32768, -32768, 829, 1463, 487, 305, -32768, -32768, -32768, -32768,
1612  -32768, -32768, -32768, -32768, -32768, -32768, -32768, 633, -32768, 422,
1613  -32768, -32768, -32768, -57, 21, -32768, -32768, 317, 319, 425,
1614  -32768, -32768, -32768, 456, 342, 139, -32768, 230, 488, 466,
1615  44, 549, 35, 434, -32768, 469, 594, 478, 314, 317,
1616  533, 443, 448, 594, 317, 829, -32768, -32768, -32768, -32768,
1617  -32768, -32768, -32768, -32768, -32768, -32768, -32768, 447, -32768, -32768,
1618  -32768, -32768, -32768, -32768, -32768, 351, -32768, 319, 45, -32768,
1619  598, 447, 351, 476, 65, -32768, 1054, -32768, 444, -32768,
1620  1463, 829, 75, 829, 1054, 599, 829, 599, -32768, 474,
1621  -32768, 312, 829, 1054, 1054, 452, 599, 599, 599, 27,
1622  360, -32768, 458, 451, 317, 378, -32768, 829, 829, 610,
1623  183, -32768, -32768, 1054, 1054, 1054, 1054, 1054, 1054, 1307,
1624  465, 1307, 732, 829, 112, 1054, -32768, -2, -32768, -32768,
1625  -32768, 136, -32768, 602, 594, 619, 460, 68, 467, -32768,
1626  68, -32768, -32768, -32768, 617, -32768, 626, -32768, 319, 319,
1627  319, 319, 317, 566, 431, 616, 226, -32768, 628, -32768,
1628  473, -32768, 594, 486, 634, 643, 652, 575, 497, 255,
1629  -32768, -32768, -32768, 1561, 258, -15, 416, 445, -32768, -32768,
1630  534, 278, -32768, -32768, 502, 314, 586, 503, 829, 829,
1631  29, -32768, -32768, 93, 505, 94, 829, 829, 603, 330,
1632  209, -32768, 509, 34, 285, 511, 295, 23, 242, 83,
1633  -32768, 298, 513, 514, -32768, -32768, 1463, -32768, 517, -32768,
1634  672, 597, 666, -32768, -32768, 1054, 1307, 521, 1307, 376,
1635  376, -32768, -32768, -32768, 455, 678, 1228, -32768, 678, -32768,
1636  -32768, -32768, 926, 1151, -32768, 516, -32768, 585, -32768, 57,
1637  -32768, 522, 319, -32768, 829, 302, 314, -32768, -32768, 589,
1638  342, 589, 681, -32768, 323, -32768, -32768, -32768, 563, -32768,
1639  -32768, -32768, 1463, -32768, 594, 314, 448, 331, 829, 530,
1640  532, 535, 537, 319, 621, 448, 581, -32768, 40, -32768,
1641  685, 448, -32768, 445, -32768, 319, 1307, -32768, 445, -32768,
1642  36, 38, -32768, -32768, 829, 416, 156, -32768, 1561, -32768,
1643  -32768, -32768, -32768, 599, -32768, -32768, 694, 829, -32768, 1054,
1644  -32768, 599, -32768, -32768, -32768, 317, -32768, -32768, 669, 625,
1645  506, 678, 1228, -32768, 678, 1054, 1307, -32768, 337, -32768,
1646  -32768, -32768, 516, -32768, -32768, -32768, -32768, 416, -32768, -32768,
1647  50, -32768, -32768, -32768, -32768, -32768, 319, 319, -32768, -32768,
1648  -32768, 343, -32768, 46, 319, 319, 319, 319, 346, 701,
1649  -32768, 705, 611, 551, 1384, 317, -32768, 708, 314, 348,
1650  447, -32768, 357, 447, -32768, -32768, 416, 829, 211, 552,
1651  555, 32, 252, 558, -32768, 829, 829, -32768, 1054, -32768,
1652  380, -32768, 516, -32768, -32768, 1307, -32768, -32768, -32768, -32768,
1653  314, -32768, 382, 385, 559, 561, -32768, 314, 564, 170,
1654  829, -32768, -32768, -32768, 570, -32768, -32768, 314, -32768, 416,
1655  -32768, -32768, -32768, -32768, 829, -32768, -32768, 569, 416, 416,
1656  516, -32768, -32768, -32768, 592, -32768, -32768, 601, -32768, 722,
1657  731, -32768, 48, 319, -32768, 53, 829, 317, 317, 576,
1658  -32768, -32768, 577, -32768, 416, 580, 582, -32768, -32768, 319,
1659  319, 389, 584, -32768, -32768, 740, -32768};
1660 
1661 static const short yypgoto[] = {
1662  -32768, 726, -32768, -32768, -32768, -32768, -32768, -32768, -224, 263,
1663  259, -32768, -32768, -32768, -32768, -32768, 281, -32768, -32768, -32768,
1664  -32768, 510, -32768, -32768, -32768, -32768, 383, -32768, -32768, -32768,
1665  -32768, -32768, -32768, -32768, -32768, -32768, -32768, -32768, -32768, -152,
1666  257, -347, 166, -32768, -32768, -489, -156, -32768, -32768, -32768,
1667  -32768, 284, 408, 291, -32768, -32768, -32768, -32768, -32768, 293,
1668  -32768, -232, -32768, -32768, -32768, 739, -89, -294, -32768, -32768,
1669  -32768, 225, -32768, -32768, -32768, -32768, -164, -32768, -32768, -32768,
1670  -32768, -332, -32768, -32768, -306, -32768, -32768, -32768, -32768, -215,
1671  -32768, -32768, -32768, -32768, -32768, -147, 432, -32768, -301, -32768,
1672  -193, -32768, 483, -3, -32768, -51, 751, 49, -157, 387,
1673  762, 624, 618, 498, -161, -274, -369, 480, -32768, -210,
1674  -32768};
1675 
1676 #define YYLAST 1690
1677 
1678 static const short yytable[] = {
1679  64, 279, 285, 281, 578, 415, 288, 288, 411, 121, 311, 475, 476, 106, 498, 500,
1680  61, -334, 343, 129, 287, 289, 62, 414, 236, 136, -331, 336, 445, 384, 448, 334,
1681  421, 422, 423, 317, 318, 72, 309, 317, 318, 317, 318, 581, 317, 318, 317, 318,
1682  317, 318, 317, 318, 102, 393, 582, 310, 116, 93, 317, 318, 317, 318, 93, 461,
1683  127, 317, 318, 392, 401, 131, 160, 148, 149, 350, 323, 324, 325, 326, 327, 361,
1684  96, 583, 235, 431, 402, 622, 623, 151, 357, 240, 103, 386, 369, 155, 156, 158,
1685  159, 311, 584, 467, 323, 324, 325, 326, 327, 335, 317, 318, 233, 463, 323, 324,
1686  325, 326, 327, 447, 550, 454, 128, 400, 465, 616, 298, 152, 135, 288, 457, 405,
1687  468, 409, 241, 260, 413, 288, 261, 541, 97, 544, 417, 403, 617, 406, 288, 288,
1688  501, 549, 351, 410, 487, 598, 477, 478, 415, 432, 433, 152, 418, 419, 415, 98,
1689  362, 460, 288, 288, 288, 288, 288, 288, 317, 318, 585, 288, 63, -334, 288, 105,
1690  439, 440, 441, 442, 443, 444, -331, 337, 527, 455, 245, 424, 459, 512, 681, 394,
1691  643, 644, 521, 14, 594, 242, 595, 153, 592, 269, 337, 358, 113, 549, 621, 65,
1692  671, 609, 458, 73, 611, 673, 246, 514, 435, 18, 58, 618, 554, 99, 543, 407,
1693  338, 161, 323, 324, 325, 326, 327, 107, 145, 534, 510, 511, 610, 231, 551, 507,
1694  352, 549, 515, 516, 529, 613, 370, 140, 415, 599, 141, 385, 343, 425, 353, 66,
1695  67, 603, 154, 323, 324, 325, 326, 327, 146, 110, 436, 437, 685, 323, 324, 325,
1696  326, 327, 288, 438, 14, 597, 74, 142, 78, 79, 660, 392, 154, 59, 255, 143,
1697  540, 568, 111, 288, 288, 1, 75, 591, 2, 462, 18, 112, 557, 80, 81, 115,
1698  76, 403, 552, 77, 316, 350, 559, 60, 661, 481, 652, 3, 4, 317, 318, 113,
1699  61, 270, 339, 68, 573, 82, 62, 5, 340, 570, 283, 122, 6, 7, 571, 319,
1700  83, 284, 69, 78, 79, 84, 317, 318, 125, 346, 590, 8, 70, 589, 596, 593,
1701  347, 9, 388, 134, 123, 619, 137, 479, 518, 389, 85, 601, 392, 392, 624, 625,
1702  288, 519, 132, 640, 10, 337, 320, 321, 322, 323, 324, 325, 326, 327, 602, 249,
1703  288, 271, 483, 484, 272, 254, 124, 633, 130, 328, 11, 325, 326, 327, 612, 138,
1704  12, 13, 528, 86, 139, 14, 187, 147, 189, 15, 227, 16, 645, 17, 87, 494,
1705  495, 273, 499, 484, 88, 193, 194, 232, 89, 274, 144, 18, 317, 318, 90, 91,
1706  636, 639, 117, 118, 119, 150, 504, 505, 120, 648, 649, 329, 330, 522, 523, 288,
1707  263, 264, 119, 339, 331, 672, 120, 525, 526, 340, 530, 531, 228, 650, 558, 484,
1708  653, 229, 662, 237, 545, 392, 682, 658, 323, 324, 325, 326, 327, 234, 239, 162,
1709  665, 664, 163, 565, 566, 247, 164, 165, 248, 373, 166, 572, 484, 167, 168, 397,
1710  251, 614, 615, 250, 398, 258, 674, 620, 495, 170, 626, 505, 637, 495, 171, 172,
1711  252, 173, 174, 175, 176, 638, 615, 608, 425, 253, 374, 323, 324, 325, 326, 327,
1712  255, 177, 178, 259, 179, 323, 324, 325, 326, 327, 399, 180, 651, 615, 654, 505,
1713  181, 655, 505, 262, 182, 683, 505, 277, 291, 280, 183, 290, 293, 294, 184, 295,
1714  375, 296, 185, 314, 297, 299, 301, 186, 302, 303, 187, 188, 189, 190, 191, 192,
1715  304, 305, 306, 307, 308, 345, 634, 333, 344, 193, 194, 376, 377, 354, 378, 356,
1716  195, 357, 364, 363, 196, 365, 197, 198, 199, 371, 372, 368, 395, 200, 335, 162,
1717  387, 411, 163, 14, 420, 434, 164, 165, 427, 464, 166, 426, 201, 167, 168, 169,
1718  446, 466, 284, 472, 470, 473, 241, 482, 486, 170, 485, 202, 492, 489, 171, 172,
1719  203, 173, 174, 175, 176, 488, 490, 320, 321, 322, 323, 324, 325, 326, 327, 491,
1720  493, 177, 178, 503, 179, 506, 508, 509, 675, 676, 328, 180, 513, 520, 517, 524,
1721  181, 532, 533, 536, 182, 538, 535, 318, 542, 546, 183, 553, 564, 555, 184, 560,
1722  567, 574, 185, 575, 298, 588, 576, 186, 577, 579, 187, 188, 189, 190, 191, 192,
1723  600, 605, 606, 627, 628, 629, 630, 581, 641, 193, 194, 642, 329, 330, 646, 656,
1724  195, 657, 667, 659, 196, 331, 197, 198, 199, 663, 666, 668, 669, 200, 670, 162,
1725  677, 678, 163, 679, 686, 680, 164, 165, 684, 109, 480, 569, 201, 167, 168, 360,
1726  580, 635, 562, 556, 449, 108, 471, 450, 604, 170, 563, 202, 100, 456, 171, 172,
1727  203, 173, 174, 175, 176, 404, 502, 101, 80, 81, 276, 282, 396, 416, 0, 0,
1728  0, 177, 178, 0, 179, 0, 0, 0, 0, 0, 0, 180, 0, 0, 0, 0,
1729  82, 0, 0, 0, 182, 0, 0, 0, 0, 0, 183, 83, 0, 0, 184, 0,
1730  84, 0, 185, 0, 0, 0, 0, 186, 0, 0, 187, 188, 189, 190, 191, 192,
1731  162, 0, 0, 163, 0, 85, 0, 164, 165, 193, 194, 166, 0, 0, 167, 168,
1732  195, 451, 0, 0, 196, 0, 197, 198, 199, 0, 170, 0, 0, 200, 0, 171,
1733  172, 0, 173, 174, 175, 176, 0, 0, 0, 0, 0, 0, 201, 0, 86, 0,
1734  0, 0, 177, 178, 0, 179, 0, 0, 0, 87, 0, 452, 180, 0, 0, 88,
1735  203, 181, 0, 89, 0, 182, 0, 0, 0, 90, 91, 183, 0, 0, 0, 184,
1736  0, 0, 0, 185, 0, 0, 0, 0, 186, 0, 0, 187, 188, 189, 190, 191,
1737  192, 162, 0, 0, 163, 0, 0, 0, 164, 165, 193, 194, 0, 0, 0, 167,
1738  168, 195, 0, 0, 0, 196, 0, 197, 198, 199, 0, 170, 0, 0, 200, 0,
1739  171, 172, 0, 173, 174, 175, 176, 0, 0, 0, 0, 0, 0, 201, 0, 0,
1740  0, 0, 0, 177, 178, 0, 179, 0, 0, 0, 0, 0, 202, 180, 0, 0,
1741  0, 203, 0, 0, 0, 0, 182, 0, 0, 0, 0, 0, 183, 0, 0, 0,
1742  184, 0, 0, 0, 185, 0, 0, 0, 0, 186, 0, 0, 187, 188, 189, 190,
1743  191, 192, 0, 0, 0, 0, 0, 0, 0, 0, 0, 193, 194, 0, 0, 0,
1744  0, 0, 195, 0, 0, 0, 196, 0, 197, 198, 199, 0, 0, 0, 0, 200,
1745  0, 162, 0, 0, 163, 0, 0, 14, 164, 165, 0, 0, 0, 0, 201, 167,
1746  168, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 170, 0, 286, 0, 0,
1747  171, 172, 203, 173, 174, 175, 176, 0, 0, 0, 0, 0, 0, 0, 0, 0,
1748  0, 0, 0, 177, 178, 0, 179, 0, 0, 0, 0, 0, 0, 180, 0, 0,
1749  0, 0, 0, 0, 0, 0, 182, 0, 0, 0, 0, 0, 183, 0, 0, 0,
1750  184, 0, 0, 0, 185, 0, 0, 0, 0, 186, 0, 0, 187, 188, 189, 190,
1751  191, 192, 162, 0, 0, 163, 0, 0, 0, 164, 165, 193, 194, 0, 0, 0,
1752  167, 168, 195, 0, 0, 0, 196, 0, 197, 198, 199, 0, 170, 0, 0, 200,
1753  0, 171, 172, 0, 173, 174, 175, 176, 0, 0, 0, 0, 0, 0, 201, 0,
1754  0, 0, 0, 0, 177, 178, 0, 179, 0, 0, 0, 0, 0, 286, 180, 0,
1755  0, 0, 203, 0, 0, 0, 0, 182, 0, 0, 0, 0, 0, 183, 0, 0,
1756  0, 184, 163, 0, 0, 185, 164, 165, 0, 0, 186, 0, 0, 187, 188, 189,
1757  190, 191, 192, 0, 0, 0, 0, 0, 0, 170, 0, 0, 193, 194, 171, 172,
1758  0, 0, 0, 195, 176, 0, 0, 196, 0, 197, 198, 199, 0, 0, 0, 0,
1759  200, 177, 178, 0, 179, 0, 0, 0, 0, 0, 0, 180, 0, 0, 0, 201,
1760  0, 0, 0, 0, 182, 0, 0, 0, 0, 0, 183, 0, 0, 0, 452, 0,
1761  0, 163, 185, 203, 0, 164, 165, 0, 0, 0, 187, 0, 189, 190, 191, 192,
1762  0, 0, 0, 0, 0, 0, 0, 0, 170, 193, 194, 0, 0, 171, 172, 0,
1763  195, 0, 0, 176, 196, 0, 197, 198, 199, 0, 0, 0, 0, 200, 0, 0,
1764  177, 178, 0, 179, 0, 14, 0, 0, 0, 0, 180, 0, 201, 0, 0, 0,
1765  0, 0, 0, 182, 0, 0, 0, 0, 0, 183, 0, 0, 0, 0, 163, 0,
1766  203, 185, 164, 165, 0, 0, 0, 0, 0, 187, 0, 189, 190, 191, 192, 0,
1767  0, 0, 0, 0, 0, 170, 0, 0, 193, 194, 171, 172, 0, 0, 0, 195,
1768  176, 0, 0, 196, 0, 197, 198, 199, 0, 0, 0, 0, 200, 177, 178, 0,
1769  179, 0, 0, 0, 0, 0, 0, 180, 0, 0, 0, 201, 0, 0, 0, 0,
1770  182, 0, 0, 0, 0, 0, 183, 0, 0, 0, 0, 0, 0, 163, 185, 203,
1771  0, 164, 165, 0, 0, 0, 187, 0, 189, 190, 631, 192, 0, 0, 0, 0,
1772  0, 0, 0, 0, 170, 193, 194, 0, 0, 171, 172, 0, 195, 0, 0, 176,
1773  196, 0, 197, 198, 199, 0, 0, 0, 0, 200, 0, 0, 177, 178, 0, 179,
1774  0, 0, 0, 0, 1, 0, 180, 2, 632, 0, 0, 0, 0, 0, 0, 182,
1775  0, 0, 0, 0, 0, 183, 0, 0, 0, 0, 3, 4, 203, 185, 0, 0,
1776  0, 0, 0, 0, 0, 187, 5, 189, 190, 191, 192, 6, 7, 0, 0, 0,
1777  0, 0, 0, 0, 193, 194, 0, 0, 0, 0, 8, 195, 0, 0, 0, 196,
1778  9, 197, 198, 199, 0, 0, 0, 0, 200, 0, 0, 171, 172, 0, 0, 0,
1779  0, 176, 0, 10, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 177, 0,
1780  0, 179, 0, 0, 0, 0, 0, 0, 496, 11, 0, 203, 0, 0, 0, 12,
1781  13, 497, 0, 0, 14, 0, 0, 183, 15, 0, 16, 0, 17, 0, 0, 185,
1782  0, 0, 0, 0, 0, 0, 0, 187, 0, 189, 18, 0, 192, 0, 0, 0,
1783  0, 0, 0, 0, 0, 0, 193, 194, 0, 0, 0, 0, 0, 195, 0, 0,
1784  0, 196, 0, 197, 198, 199, 0, 0, 0, 0, 200};
1785 
1786 static const short yycheck[] = {
1787  3, 157, 166, 160, 493, 299, 167, 168, 10, 60, 203, 358, 359, 16, 383, 30, 3,
1788  6, 228, 70, 167, 168, 9, 297, 113, 76, 6, 6, 329, 253, 331, 88, 306, 307,
1789  308, 12, 13, 76, 202, 12, 13, 12, 13, 3, 12, 13, 12, 13, 12, 13, 12,
1790  13, 24, 8, 14, 202, 59, 8, 12, 13, 12, 13, 13, 337, 67, 12, 13, 277,
1791  3, 72, 76, 155, 156, 234, 17, 18, 19, 20, 21, 44, 87, 41, 24, 315, 19,
1792  574, 575, 125, 44, 23, 62, 255, 248, 96, 97, 98, 99, 290, 58, 31, 17, 18,
1793  19, 20, 21, 162, 12, 13, 111, 341, 17, 18, 19, 20, 21, 330, 448, 332, 69,
1794  283, 344, 71, 111, 161, 75, 286, 14, 291, 60, 293, 64, 134, 296, 294, 137, 436,
1795  118, 438, 302, 286, 90, 66, 303, 304, 159, 446, 235, 294, 372, 518, 360, 361, 446,
1796  317, 318, 161, 303, 304, 452, 118, 125, 163, 323, 324, 325, 326, 327, 328, 12, 13,
1797  130, 332, 159, 162, 335, 48, 323, 324, 325, 326, 327, 328, 162, 162, 161, 332, 131,
1798  160, 335, 160, 679, 146, 160, 161, 160, 137, 160, 131, 160, 102, 506, 152, 162, 159,
1799  127, 506, 160, 3, 160, 541, 98, 51, 544, 160, 159, 121, 33, 159, 51, 566, 163,
1800  118, 437, 148, 227, 102, 17, 18, 19, 20, 21, 43, 115, 426, 398, 399, 542, 160,
1801  453, 395, 10, 542, 406, 407, 161, 546, 249, 115, 542, 523, 118, 254, 462, 160, 24,
1802  51, 52, 531, 161, 17, 18, 19, 20, 21, 147, 158, 83, 84, 0, 17, 18, 19,
1803  20, 21, 435, 92, 137, 121, 118, 147, 3, 4, 112, 493, 161, 118, 150, 155, 435,
1804  482, 118, 452, 453, 25, 134, 505, 28, 161, 159, 107, 464, 24, 25, 3, 144, 452,
1805  453, 147, 3, 470, 466, 144, 142, 364, 615, 47, 48, 12, 13, 127, 3, 51, 3,
1806  119, 488, 48, 9, 59, 9, 485, 159, 7, 64, 65, 486, 30, 59, 166, 134, 3,
1807  4, 64, 12, 13, 82, 3, 503, 79, 144, 501, 514, 508, 10, 85, 3, 74, 76,
1808  567, 77, 362, 30, 10, 85, 527, 574, 575, 576, 577, 529, 160, 82, 160, 104, 162,
1809  14, 15, 16, 17, 18, 19, 20, 21, 529, 124, 545, 115, 160, 161, 118, 130, 118,
1810  584, 118, 33, 126, 19, 20, 21, 545, 113, 132, 133, 160, 126, 115, 137, 94, 147,
1811  96, 141, 118, 143, 160, 145, 137, 160, 161, 147, 160, 161, 143, 109, 110, 158, 147,
1812  155, 155, 159, 12, 13, 153, 154, 588, 597, 3, 4, 5, 155, 160, 161, 9, 605,
1813  606, 83, 84, 160, 161, 608, 3, 4, 5, 3, 92, 663, 9, 160, 161, 9, 160,
1814  161, 138, 608, 160, 161, 620, 151, 630, 93, 13, 679, 680, 627, 17, 18, 19, 20,
1815  21, 36, 131, 3, 644, 637, 6, 160, 161, 160, 10, 11, 6, 41, 14, 160, 161,
1816  17, 18, 19, 3, 160, 161, 14, 24, 68, 666, 160, 161, 29, 160, 161, 160, 161,
1817  34, 35, 159, 37, 38, 39, 40, 160, 161, 13, 160, 159, 74, 17, 18, 19, 20,
1818  21, 150, 53, 54, 3, 56, 17, 18, 19, 20, 21, 62, 63, 160, 161, 160, 161,
1819  68, 160, 161, 157, 72, 160, 161, 159, 148, 76, 78, 162, 159, 159, 82, 159, 112,
1820  159, 86, 76, 159, 159, 159, 91, 159, 159, 94, 95, 96, 97, 98, 99, 159, 159,
1821  159, 159, 159, 125, 585, 161, 159, 109, 110, 139, 140, 101, 142, 125, 116, 44, 125,
1822  161, 120, 3, 122, 123, 124, 68, 159, 125, 6, 129, 162, 3, 161, 10, 6, 137,
1823  160, 3, 10, 11, 165, 15, 14, 161, 144, 17, 18, 19, 159, 6, 166, 10, 161,
1824  3, 64, 15, 159, 29, 6, 159, 61, 3, 34, 35, 164, 37, 38, 39, 40, 159,
1825  3, 14, 15, 16, 17, 18, 19, 20, 21, 3, 159, 53, 54, 125, 56, 159, 76,
1826  160, 667, 668, 33, 63, 163, 160, 67, 160, 68, 160, 160, 3, 72, 80, 161, 13,
1827  159, 3, 78, 98, 3, 163, 82, 98, 125, 159, 86, 159, 111, 8, 159, 91, 159,
1828  76, 94, 95, 96, 97, 98, 99, 10, 36, 81, 6, 3, 98, 159, 3, 160, 109,
1829  110, 160, 83, 84, 160, 160, 116, 160, 130, 159, 120, 92, 122, 123, 124, 159, 161,
1830  130, 10, 129, 3, 3, 160, 160, 6, 159, 0, 159, 10, 11, 160, 19, 363, 484,
1831  144, 17, 18, 241, 495, 587, 470, 462, 24, 18, 350, 27, 535, 29, 471, 159, 13,
1832  333, 34, 35, 164, 37, 38, 39, 40, 290, 387, 13, 24, 25, 154, 161, 282, 301,
1833  -1, -1, -1, 53, 54, -1, 56, -1, -1, -1, -1, -1, -1, 63, -1, -1, -1,
1834  -1, 48, -1, -1, -1, 72, -1, -1, -1, -1, -1, 78, 59, -1, -1, 82, -1,
1835  64, -1, 86, -1, -1, -1, -1, 91, -1, -1, 94, 95, 96, 97, 98, 99, 3,
1836  -1, -1, 6, -1, 85, -1, 10, 11, 109, 110, 14, -1, -1, 17, 18, 116, 117,
1837  -1, -1, 120, -1, 122, 123, 124, -1, 29, -1, -1, 129, -1, 34, 35, -1, 37,
1838  38, 39, 40, -1, -1, -1, -1, -1, -1, 144, -1, 126, -1, -1, -1, 53, 54,
1839  -1, 56, -1, -1, -1, 137, -1, 159, 63, -1, -1, 143, 164, 68, -1, 147, -1,
1840  72, -1, -1, -1, 153, 154, 78, -1, -1, -1, 82, -1, -1, -1, 86, -1, -1,
1841  -1, -1, 91, -1, -1, 94, 95, 96, 97, 98, 99, 3, -1, -1, 6, -1, -1,
1842  -1, 10, 11, 109, 110, -1, -1, -1, 17, 18, 116, -1, -1, -1, 120, -1, 122,
1843  123, 124, -1, 29, -1, -1, 129, -1, 34, 35, -1, 37, 38, 39, 40, -1, -1,
1844  -1, -1, -1, -1, 144, -1, -1, -1, -1, -1, 53, 54, -1, 56, -1, -1, -1,
1845  -1, -1, 159, 63, -1, -1, -1, 164, -1, -1, -1, -1, 72, -1, -1, -1, -1,
1846  -1, 78, -1, -1, -1, 82, -1, -1, -1, 86, -1, -1, -1, -1, 91, -1, -1,
1847  94, 95, 96, 97, 98, 99, -1, -1, -1, -1, -1, -1, -1, -1, -1, 109, 110,
1848  -1, -1, -1, -1, -1, 116, -1, -1, -1, 120, -1, 122, 123, 124, -1, -1, -1,
1849  -1, 129, -1, 3, -1, -1, 6, -1, -1, 137, 10, 11, -1, -1, -1, -1, 144,
1850  17, 18, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 29, -1, 159, -1, -1,
1851  34, 35, 164, 37, 38, 39, 40, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
1852  -1, -1, 53, 54, -1, 56, -1, -1, -1, -1, -1, -1, 63, -1, -1, -1, -1,
1853  -1, -1, -1, -1, 72, -1, -1, -1, -1, -1, 78, -1, -1, -1, 82, -1, -1,
1854  -1, 86, -1, -1, -1, -1, 91, -1, -1, 94, 95, 96, 97, 98, 99, 3, -1,
1855  -1, 6, -1, -1, -1, 10, 11, 109, 110, -1, -1, -1, 17, 18, 116, -1, -1,
1856  -1, 120, -1, 122, 123, 124, -1, 29, -1, -1, 129, -1, 34, 35, -1, 37, 38,
1857  39, 40, -1, -1, -1, -1, -1, -1, 144, -1, -1, -1, -1, -1, 53, 54, -1,
1858  56, -1, -1, -1, -1, -1, 159, 63, -1, -1, -1, 164, -1, -1, -1, -1, 72,
1859  -1, -1, -1, -1, -1, 78, -1, -1, -1, 82, 6, -1, -1, 86, 10, 11, -1,
1860  -1, 91, -1, -1, 94, 95, 96, 97, 98, 99, -1, -1, -1, -1, -1, -1, 29,
1861  -1, -1, 109, 110, 34, 35, -1, -1, -1, 116, 40, -1, -1, 120, -1, 122, 123,
1862  124, -1, -1, -1, -1, 129, 53, 54, -1, 56, -1, -1, -1, -1, -1, -1, 63,
1863  -1, -1, -1, 144, -1, -1, -1, -1, 72, -1, -1, -1, -1, -1, 78, -1, -1,
1864  -1, 159, -1, -1, 6, 86, 164, -1, 10, 11, -1, -1, -1, 94, -1, 96, 97,
1865  98, 99, -1, -1, -1, -1, -1, -1, -1, -1, 29, 109, 110, -1, -1, 34, 35,
1866  -1, 116, -1, -1, 40, 120, -1, 122, 123, 124, -1, -1, -1, -1, 129, -1, -1,
1867  53, 54, -1, 56, -1, 137, -1, -1, -1, -1, 63, -1, 144, -1, -1, -1, -1,
1868  -1, -1, 72, -1, -1, -1, -1, -1, 78, -1, -1, -1, -1, 6, -1, 164, 86,
1869  10, 11, -1, -1, -1, -1, -1, 94, -1, 96, 97, 98, 99, -1, -1, -1, -1,
1870  -1, -1, 29, -1, -1, 109, 110, 34, 35, -1, -1, -1, 116, 40, -1, -1, 120,
1871  -1, 122, 123, 124, -1, -1, -1, -1, 129, 53, 54, -1, 56, -1, -1, -1, -1,
1872  -1, -1, 63, -1, -1, -1, 144, -1, -1, -1, -1, 72, -1, -1, -1, -1, -1,
1873  78, -1, -1, -1, -1, -1, -1, 6, 86, 164, -1, 10, 11, -1, -1, -1, 94,
1874  -1, 96, 97, 98, 99, -1, -1, -1, -1, -1, -1, -1, -1, 29, 109, 110, -1,
1875  -1, 34, 35, -1, 116, -1, -1, 40, 120, -1, 122, 123, 124, -1, -1, -1, -1,
1876  129, -1, -1, 53, 54, -1, 56, -1, -1, -1, -1, 25, -1, 63, 28, 144, -1,
1877  -1, -1, -1, -1, -1, 72, -1, -1, -1, -1, -1, 78, -1, -1, -1, -1, 47,
1878  48, 164, 86, -1, -1, -1, -1, -1, -1, -1, 94, 59, 96, 97, 98, 99, 64,
1879  65, -1, -1, -1, -1, -1, -1, -1, 109, 110, -1, -1, -1, -1, 79, 116, -1,
1880  -1, -1, 120, 85, 122, 123, 124, -1, -1, -1, -1, 129, -1, -1, 34, 35, -1,
1881  -1, -1, -1, 40, -1, 104, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, 53,
1882  -1, -1, 56, -1, -1, -1, -1, -1, -1, 63, 126, -1, 164, -1, -1, -1, 132,
1883  133, 72, -1, -1, 137, -1, -1, 78, 141, -1, 143, -1, 145, -1, -1, 86, -1,
1884  -1, -1, -1, -1, -1, -1, 94, -1, 96, 159, -1, 99, -1, -1, -1, -1, -1,
1885  -1, -1, -1, -1, 109, 110, -1, -1, -1, -1, -1, 116, -1, -1, -1, 120, -1,
1886  122, 123, 124, -1, -1, -1, -1, 129};
1887 
1888 /* fattrs + tables */
1889 
1890 /* parser code folow */
1891 
1892 /* This is the parser code that is written into each bison parser
1893  when the %semantic_parser declaration is not specified in the grammar.
1894  It was written by Richard Stallman by simplifying the hairy parser
1895  used when %semantic_parser is specified. */
1896 
1897 /* Note: dollar marks section change
1898  the next is replaced by the list of actions, each action
1899  as one case of the switch. */
1900 
1901 #if YY_Parser_USE_GOTO != 0
1902 /*
1903  SUPRESSION OF GOTO : on some C++ compiler (sun c++)
1904  the goto is strictly forbidden if any constructor/destructor
1905  is used in the whole function (very stupid isn't it ?)
1906  so goto are to be replaced with a 'while/switch/case construct'
1907  here are the macro to keep some apparent compatibility
1908 */
1909 #define YYGOTO(lb) \
1910  { \
1911  yy_gotostate = lb; \
1912  continue; \
1913  }
1914 #define YYBEGINGOTO \
1915  enum yy_labels yy_gotostate = yygotostart; \
1916  for (;;) \
1917  switch (yy_gotostate) { \
1918  case yygotostart: {
1919 #define YYLABEL(lb) \
1920  } \
1921  case lb: {
1922 #define YYENDGOTO \
1923  } \
1924  }
1925 #define YYBEGINDECLARELABEL enum yy_labels { yygotostart
1926 #define YYDECLARELABEL(lb) , lb
1927 #define YYENDDECLARELABEL \
1928  } \
1929  ;
1930 #else
1931 /* macro to keep goto */
1932 #define YYGOTO(lb) goto lb
1933 #define YYBEGINGOTO
1934 #define YYLABEL(lb) \
1935  lb:
1936 #define YYENDGOTO
1937 #define YYBEGINDECLARELABEL
1938 #define YYDECLARELABEL(lb)
1939 #define YYENDDECLARELABEL
1940 #endif
1941 /* LABEL DECLARATION */
1943 YYDECLARELABEL(yynewstate)
1944 YYDECLARELABEL(yybackup)
1945 /* YYDECLARELABEL(yyresume) */
1946 YYDECLARELABEL(yydefault)
1947 YYDECLARELABEL(yyreduce)
1948 YYDECLARELABEL(yyerrlab) /* here on detecting error */
1949 YYDECLARELABEL(yyerrlab1) /* here on error raised explicitly by an action */
1951  yyerrdefault) /* current state does not do anything special for the error token. */
1953  yyerrpop) /* pop the current state because it cannot handle the error token */
1954 YYDECLARELABEL(yyerrhandle)
1956 /* ALLOCA SIMULATION */
1957 /* __HAVE_NO_ALLOCA */
1958 #ifdef __HAVE_NO_ALLOCA
1959 int __alloca_free_ptr(char* ptr, char* ref) {
1960  if (ptr != ref)
1961  free(ptr);
1962  return 0;
1963 }
1964 
1965 #define __ALLOCA_alloca(size) malloc(size)
1966 #define __ALLOCA_free(ptr, ref) __alloca_free_ptr((char*)ptr, (char*)ref)
1967 
1968 #ifdef YY_Parser_LSP_NEEDED
1969 #define __ALLOCA_return(num) \
1970  return (__ALLOCA_free(yyss, yyssa) + __ALLOCA_free(yyvs, yyvsa) + \
1971  __ALLOCA_free(yyls, yylsa) + (num))
1972 #else
1973 #define __ALLOCA_return(num) \
1974  return (__ALLOCA_free(yyss, yyssa) + __ALLOCA_free(yyvs, yyvsa) + (num))
1975 #endif
1976 #else
1977 #define __ALLOCA_return(num) return (num)
1978 #define __ALLOCA_alloca(size) alloca(size)
1979 #define __ALLOCA_free(ptr, ref)
1980 #endif
1981 
1982 /* ENDALLOCA SIMULATION */
1983 
1984 #define yyerrok (yyerrstatus = 0)
1985 #define yyclearin (YY_Parser_CHAR = YYEMPTY)
1986 #define YYEMPTY -2
1987 #define YYEOF 0
1988 #define YYACCEPT __ALLOCA_return(0)
1989 #define YYABORT __ALLOCA_return(1)
1990 #define YYERROR YYGOTO(yyerrlab1)
1991 /* Like YYERROR except do call yyerror.
1992  This remains here temporarily to ease the
1993  transition to the new meaning of YYERROR, for GCC.
1994  Once GCC version 2 has supplanted version 1, this can go. */
1995 #define YYFAIL YYGOTO(yyerrlab)
1996 #define YYRECOVERING() (!!yyerrstatus)
1997 #define YYBACKUP(token, value) \
1998  do \
1999  if (YY_Parser_CHAR == YYEMPTY && yylen == 1) { \
2000  YY_Parser_CHAR = (token), YY_Parser_LVAL = (value); \
2001  yychar1 = YYTRANSLATE(YY_Parser_CHAR); \
2002  YYPOPSTACK; \
2003  YYGOTO(yybackup); \
2004  } else { \
2005  YY_Parser_ERROR("syntax error: cannot back up"); \
2006  YYERROR; \
2007  } \
2008  while (0)
2009 
2010 #define YYTERROR 1
2011 #define YYERRCODE 256
2012 
2013 #ifndef YY_Parser_PURE
2014 /* UNPURE */
2015 #define YYLEX YY_Parser_LEX()
2016 #ifndef YY_USE_CLASS
2017 /* If nonreentrant, and not class , generate the variables here */
2018 int YY_Parser_CHAR; /* the lookahead symbol */
2019 YY_Parser_STYPE YY_Parser_LVAL; /* the semantic value of the */
2020  /* lookahead symbol */
2021 int YY_Parser_NERRS; /* number of parse errors so far */
2022 #ifdef YY_Parser_LSP_NEEDED
2023 YY_Parser_LTYPE YY_Parser_LLOC; /* location data for the lookahead */
2024  /* symbol */
2025 #endif
2026 #endif
2027 
2028 #else
2029 /* PURE */
2030 #ifdef YY_Parser_LSP_NEEDED
2031 #define YYLEX YY_Parser_LEX(&YY_Parser_LVAL, &YY_Parser_LLOC)
2032 #else
2033 #define YYLEX YY_Parser_LEX(&YY_Parser_LVAL)
2034 #endif
2035 #endif
2036 #ifndef YY_USE_CLASS
2037 #if YY_Parser_DEBUG != 0
2038 int YY_Parser_DEBUG_FLAG; /* nonzero means print parse trace */
2039 /* Since this is uninitialized, it does not stop multiple parsers
2040  from coexisting. */
2041 #endif
2042 #endif
2043 
2044 /* YYINITDEPTH indicates the initial size of the parser's stacks */
2045 
2046 #ifndef YYINITDEPTH
2047 #define YYINITDEPTH 200
2048 #endif
2049 
2050 /* YYMAXDEPTH is the maximum size the stacks can grow to
2051  (effective only if the built-in stack extension method is used). */
2052 
2053 #if YYMAXDEPTH == 0
2054 #undef YYMAXDEPTH
2055 #endif
2056 
2057 #ifndef YYMAXDEPTH
2058 #define YYMAXDEPTH 10000
2059 #endif
2060 
2061 #if __GNUC__ > 1 /* GNU C and GNU C++ define this. */
2062 #define __yy_bcopy(FROM, TO, COUNT) __builtin_memcpy(TO, FROM, COUNT)
2063 #else /* not GNU C or C++ */
2064 
2065 /* This is the most reliable way to avoid incompatibilities
2066  in available built-in functions on various systems. */
2067 
2068 #ifdef __cplusplus
2069 static void __yy_bcopy(char* from, char* to, int count)
2070 #else
2071 #ifdef __STDC__
2072 static void __yy_bcopy(char* from, char* to, int count)
2073 #else
2074 static void __yy_bcopy(from, to, count) char* from;
2075 char* to;
2076 int count;
2077 #endif
2078 #endif
2079 {
2080  char* f = from;
2081  char* t = to;
2082  int i = count;
2083 
2084  while (i-- > 0)
2085  *t++ = *f++;
2086 }
2087 #endif
2088 
2089 int
2090 #ifdef YY_USE_CLASS
2091  YY_Parser_CLASS::
2092 #endif
2094 #ifndef __STDC__
2095 #ifndef __cplusplus
2096 #ifndef YY_USE_CLASS
2097 /* parameter definition without protypes */
2099 #endif
2100 #endif
2101 #endif
2103  int yystate;
2104  int yyn;
2105  short* yyssp;
2107  int yyerrstatus; /* number of tokens to shift before error messages enabled */
2108  int yychar1 = 0; /* lookahead token as an internal (translated) token number */
2109 
2110  short yyssa[YYINITDEPTH]; /* the state stack */
2111  YY_Parser_STYPE yyvsa[YYINITDEPTH]; /* the semantic value stack */
2112 
2113  short* yyss = yyssa; /* refer to the stacks thru separate pointers */
2114  YY_Parser_STYPE* yyvs = yyvsa; /* to allow yyoverflow to reallocate them elsewhere */
2115 
2116 #ifdef YY_Parser_LSP_NEEDED
2117  YY_Parser_LTYPE yylsa[YYINITDEPTH]; /* the location stack */
2118  YY_Parser_LTYPE* yyls = yylsa;
2119  YY_Parser_LTYPE* yylsp;
2120 
2121 #define YYPOPSTACK (yyvsp--, yyssp--, yylsp--)
2122 #else
2123 #define YYPOPSTACK (yyvsp--, yyssp--)
2124 #endif
2125 
2127 
2128 #ifdef YY_Parser_PURE
2129  int YY_Parser_CHAR;
2131  int YY_Parser_NERRS;
2132 #ifdef YY_Parser_LSP_NEEDED
2133  YY_Parser_LTYPE YY_Parser_LLOC;
2134 #endif
2135 #endif
2136 
2137  YY_Parser_STYPE yyval; /* the variable used to return */
2138  /* semantic values from the action */
2139  /* routines */
2140 
2141  int yylen;
2142  /* start loop, in which YYGOTO may be used. */
2143  YYBEGINGOTO
2144 
2145 #if YY_Parser_DEBUG != 0
2147  fprintf(stderr, "Starting parse\n");
2148 #endif
2149  yystate = 0;
2150  yyerrstatus = 0;
2151  YY_Parser_NERRS = 0;
2152  YY_Parser_CHAR = YYEMPTY; /* Cause a token to be read. */
2153 
2154  /* Initialize stack pointers.
2155  Waste one element of value and location stack
2156  so that they stay on the same level as the state stack.
2157  The wasted elements are never initialized. */
2158 
2159  yyssp = yyss - 1;
2160  yyvsp = yyvs;
2161 #ifdef YY_Parser_LSP_NEEDED
2162  yylsp = yyls;
2163 #endif
2164 
2165  /* Push a new state, which is found in yystate . */
2166  /* In all cases, when you get here, the value and location stacks
2167  have just been pushed. so pushing a state here evens the stacks. */
2168  YYLABEL(yynewstate)
2169 
2170  *++yyssp = yystate;
2171 
2172  if (yyssp >= yyss + yystacksize - 1) {
2173  /* Give user a chance to reallocate the stack */
2174  /* Use copies of these so that the &'s don't force the real ones into memory. */
2175  YY_Parser_STYPE* yyvs1 = yyvs;
2176  short* yyss1 = yyss;
2177 #ifdef YY_Parser_LSP_NEEDED
2178  YY_Parser_LTYPE* yyls1 = yyls;
2179 #endif
2180 
2181  /* Get the current used size of the three stacks, in elements. */
2182  int size = yyssp - yyss + 1;
2183 
2184 #ifdef yyoverflow
2185  /* Each stack pointer address is followed by the size of
2186  the data in use in that stack, in bytes. */
2187 #ifdef YY_Parser_LSP_NEEDED
2188  /* This used to be a conditional around just the two extra args,
2189  but that might be undefined if yyoverflow is a macro. */
2190  yyoverflow("parser stack overflow",
2191  &yyss1,
2192  size * sizeof(*yyssp),
2193  &yyvs1,
2194  size * sizeof(*yyvsp),
2195  &yyls1,
2196  size * sizeof(*yylsp),
2197  &yystacksize);
2198 #else
2199  yyoverflow("parser stack overflow",
2200  &yyss1,
2201  size * sizeof(*yyssp),
2202  &yyvs1,
2203  size * sizeof(*yyvsp),
2204  &yystacksize);
2205 #endif
2206 
2207  yyss = yyss1;
2208  yyvs = yyvs1;
2209 #ifdef YY_Parser_LSP_NEEDED
2210  yyls = yyls1;
2211 #endif
2212 #else /* no yyoverflow */
2213  /* Extend the stack our own way. */
2214  if (yystacksize >= YYMAXDEPTH) {
2215  YY_Parser_ERROR("parser stack overflow");
2216  __ALLOCA_return(2);
2217  }
2218  yystacksize *= 2;
2219  if (yystacksize > YYMAXDEPTH)
2220  yystacksize = YYMAXDEPTH;
2221  yyss = (short*)__ALLOCA_alloca(yystacksize * sizeof(*yyssp));
2222  __yy_bcopy((char*)yyss1, (char*)yyss, size * sizeof(*yyssp));
2223  __ALLOCA_free(yyss1, yyssa);
2224  yyvs = (YY_Parser_STYPE*)__ALLOCA_alloca(yystacksize * sizeof(*yyvsp));
2225  __yy_bcopy((char*)yyvs1, (char*)yyvs, size * sizeof(*yyvsp));
2226  __ALLOCA_free(yyvs1, yyvsa);
2227 #ifdef YY_Parser_LSP_NEEDED
2228  yyls = (YY_Parser_LTYPE*)__ALLOCA_alloca(yystacksize * sizeof(*yylsp));
2229  __yy_bcopy((char*)yyls1, (char*)yyls, size * sizeof(*yylsp));
2230  __ALLOCA_free(yyls1, yylsa);
2231 #endif
2232 #endif /* no yyoverflow */
2233 
2234  yyssp = yyss + size - 1;
2235  yyvsp = yyvs + size - 1;
2236 #ifdef YY_Parser_LSP_NEEDED
2237  yylsp = yyls + size - 1;
2238 #endif
2239 
2240 #if YY_Parser_DEBUG != 0
2242  fprintf(stderr, "Stack size increased to %d\n", yystacksize);
2243 #endif
2244 
2245  if (yyssp >= yyss + yystacksize - 1)
2246  YYABORT;
2247  }
2248 
2249 #if YY_Parser_DEBUG != 0
2251  fprintf(stderr, "Entering state %d\n", yystate);
2252 #endif
2253 
2254  YYGOTO(yybackup);
2255  YYLABEL(yybackup)
2256 
2257  /* Do appropriate processing given the current state. */
2258  /* Read a lookahead token if we need one and don't already have one. */
2259  /* YYLABEL(yyresume) */
2260 
2261  /* First try to decide what to do without reference to lookahead token. */
2262 
2263  yyn = yypact[yystate];
2264  if (yyn == YYFLAG)
2265  YYGOTO(yydefault);
2266 
2267  /* Not known => get a lookahead token if don't already have one. */
2268 
2269  /* yychar is either YYEMPTY or YYEOF
2270  or a valid token in external form. */
2271 
2272  if (YY_Parser_CHAR == YYEMPTY) {
2273 #if YY_Parser_DEBUG != 0
2275  fprintf(stderr, "Reading a token: ");
2276 #endif
2277  YY_Parser_CHAR = YYLEX;
2278  }
2279 
2280  /* Convert token to internal form (in yychar1) for indexing tables with */
2281 
2282  if (YY_Parser_CHAR <= 0) /* This means end of input. */
2283  {
2284  yychar1 = 0;
2285  YY_Parser_CHAR = YYEOF; /* Don't call YYLEX any more */
2286 
2287 #if YY_Parser_DEBUG != 0
2289  fprintf(stderr, "Now at end of input.\n");
2290 #endif
2291  } else {
2292  yychar1 = YYTRANSLATE(YY_Parser_CHAR);
2293 
2294 #if YY_Parser_DEBUG != 0
2295  if (YY_Parser_DEBUG_FLAG) {
2296  fprintf(stderr, "Next token is %d (%s", YY_Parser_CHAR, yytname[yychar1]);
2297  /* Give the individual parser a way to print the precise meaning
2298  of a token, for further debugging info. */
2299 #ifdef YYPRINT
2300  YYPRINT(stderr, YY_Parser_CHAR, YY_Parser_LVAL);
2301 #endif
2302  fprintf(stderr, ")\n");
2303  }
2304 #endif
2305  }
2306 
2307  yyn += yychar1;
2308  if (yyn < 0 || yyn > YYLAST || yycheck[yyn] != yychar1)
2309  YYGOTO(yydefault);
2310 
2311  yyn = yytable[yyn];
2312 
2313  /* yyn is what to do for this token type in this state.
2314  Negative => reduce, -yyn is rule number.
2315  Positive => shift, yyn is new state.
2316  New state is final state => don't bother to shift,
2317  just return success.
2318  0, or most negative number => error. */
2319 
2320  if (yyn < 0) {
2321  if (yyn == YYFLAG)
2322  YYGOTO(yyerrlab);
2323  yyn = -yyn;
2324  YYGOTO(yyreduce);
2325  } else if (yyn == 0)
2326  YYGOTO(yyerrlab);
2327 
2328  if (yyn == YYFINAL)
2330 
2331  /* Shift the lookahead token. */
2332 
2333 #if YY_Parser_DEBUG != 0
2335  fprintf(stderr, "Shifting token %d (%s), ", YY_Parser_CHAR, yytname[yychar1]);
2336 #endif
2337 
2338  /* Discard the token being shifted unless it is eof. */
2339  if (YY_Parser_CHAR != YYEOF)
2340  YY_Parser_CHAR = YYEMPTY;
2341 
2342  *++yyvsp = YY_Parser_LVAL;
2343 #ifdef YY_Parser_LSP_NEEDED
2344  *++yylsp = YY_Parser_LLOC;
2345 #endif
2346 
2347  /* count tokens shifted since error; after three, turn off error status. */
2348  if (yyerrstatus)
2349  yyerrstatus--;
2350 
2351  yystate = yyn;
2352  YYGOTO(yynewstate);
2353 
2354  /* Do the default action for the current state. */
2355  YYLABEL(yydefault)
2356 
2357  yyn = yydefact[yystate];
2358  if (yyn == 0)
2359  YYGOTO(yyerrlab);
2360 
2361  /* Do a reduction. yyn is the number of a rule to reduce with. */
2362  YYLABEL(yyreduce)
2363  yylen = yyr2[yyn];
2364  if (yylen > 0)
2365  yyval = yyvsp[1 - yylen]; /* implement default value of the action */
2366 
2367 #if YY_Parser_DEBUG != 0
2368  if (YY_Parser_DEBUG_FLAG) {
2369  int i;
2370 
2371  fprintf(stderr, "Reducing via rule %d (line %d), ", yyn, yyrline[yyn]);
2372 
2373  /* Print the symbols being reduced, and their result. */
2374  for (i = yyprhs[yyn]; yyrhs[i] > 0; i++)
2375  fprintf(stderr, "%s ", yytname[yyrhs[i]]);
2376  fprintf(stderr, " -> %s\n", yytname[yyr1[yyn]]);
2377  }
2378 #endif
2379 
2380  switch (yyn) {
2381  case 1:
2382 
2383  {
2384  parseTrees.emplace_front(dynamic_cast<Stmt*>((yyvsp[-1].nodeval)->release()));
2385  ;
2386  break;
2387  }
2388  case 2:
2389 
2390  {
2391  parseTrees.emplace_front(dynamic_cast<Stmt*>((yyvsp[-1].nodeval)->release()));
2392  ;
2393  break;
2394  }
2395  case 3:
2396 
2397  {
2398  yyval.nodeval = yyvsp[0].nodeval;
2399  ;
2400  break;
2401  }
2402  case 4:
2403 
2404  {
2405  yyval.nodeval = yyvsp[0].nodeval;
2406  ;
2407  break;
2408  }
2409  case 5:
2410 
2411  {
2412  yyval.nodeval = yyvsp[0].nodeval;
2413  ;
2414  break;
2415  }
2416  case 6:
2417 
2418  {
2419  yyval.nodeval = yyvsp[0].nodeval;
2420  ;
2421  break;
2422  }
2423  case 7:
2424 
2425  {
2426  yyval.nodeval = yyvsp[0].nodeval;
2427  ;
2428  break;
2429  }
2430  case 8:
2431 
2432  {
2433  yyval.nodeval = yyvsp[0].nodeval;
2434  ;
2435  break;
2436  }
2437  case 9:
2438 
2439  {
2440  yyval.nodeval = yyvsp[0].nodeval;
2441  ;
2442  break;
2443  }
2444  case 10:
2445 
2446  {
2447  yyval.nodeval = yyvsp[0].nodeval;
2448  ;
2449  break;
2450  }
2451  case 11:
2452 
2453  {
2454  yyval.nodeval = yyvsp[0].nodeval;
2455  ;
2456  break;
2457  }
2458  case 12:
2459 
2460  {
2461  yyval.nodeval = yyvsp[0].nodeval;
2462  ;
2463  break;
2464  }
2465  case 13:
2466 
2467  {
2468  yyval.nodeval = yyvsp[0].nodeval;
2469  ;
2470  break;
2471  }
2472  case 14:
2473 
2474  {
2475  yyval.nodeval = yyvsp[0].nodeval;
2476  ;
2477  break;
2478  }
2479  case 15:
2480 
2481  {
2482  yyval.nodeval = yyvsp[0].nodeval;
2483  ;
2484  break;
2485  }
2486  case 16:
2487 
2488  {
2489  yyval.nodeval = yyvsp[0].nodeval;
2490  ;
2491  break;
2492  }
2493  case 17:
2494 
2495  {
2496  yyval.nodeval = yyvsp[0].nodeval;
2497  ;
2498  break;
2499  }
2500  case 18:
2501 
2502  {
2503  yyval.nodeval = yyvsp[0].nodeval;
2504  ;
2505  break;
2506  }
2507  case 19:
2508 
2509  {
2510  yyval.nodeval = yyvsp[0].nodeval;
2511  ;
2512  break;
2513  }
2514  case 20:
2515 
2516  {
2517  yyval.nodeval = yyvsp[0].nodeval;
2518  ;
2519  break;
2520  }
2521  case 21:
2522 
2523  {
2524  yyval.nodeval = yyvsp[0].nodeval;
2525  ;
2526  break;
2527  }
2528  case 22:
2529 
2530  {
2531  yyval.nodeval = yyvsp[0].nodeval;
2532  ;
2533  break;
2534  }
2535  case 23:
2536 
2537  {
2538  yyval.nodeval = yyvsp[0].nodeval;
2539  ;
2540  break;
2541  }
2542  case 24:
2543 
2544  {
2545  yyval.nodeval = yyvsp[0].nodeval;
2546  ;
2547  break;
2548  }
2549  case 25:
2550 
2551  {
2552  yyval.nodeval = yyvsp[0].nodeval;
2553  ;
2554  break;
2555  }
2556  case 26:
2557 
2558  {
2559  yyval.nodeval = yyvsp[0].nodeval;
2560  ;
2561  break;
2562  }
2563  case 27:
2564 
2565  {
2566  yyval.nodeval = yyvsp[0].nodeval;
2567  ;
2568  break;
2569  }
2570  case 28:
2571 
2572  {
2573  yyval.nodeval = yyvsp[0].nodeval;
2574  ;
2575  break;
2576  }
2577  case 29:
2578 
2579  {
2580  yyval.nodeval = yyvsp[0].nodeval;
2581  ;
2582  break;
2583  }
2584  case 30:
2585 
2586  {
2587  yyval.nodeval = yyvsp[0].nodeval;
2588  ;
2589  break;
2590  }
2591  case 31:
2592 
2593  {
2594  yyval.nodeval = TrackedPtr<Node>::make(
2595  lexer.parsed_node_tokens_,
2596  new CreateDBStmt((yyvsp[0].stringval)->release(), nullptr, yyvsp[-1].boolval));
2597  ;
2598  break;
2599  }
2600  case 32:
2601 
2602  {
2603  yyval.nodeval = TrackedPtr<Node>::make(
2604  lexer.parsed_node_tokens_,
2605  new CreateDBStmt((yyvsp[-3].stringval)->release(),
2606  reinterpret_cast<std::list<NameValueAssign*>*>(
2607  (yyvsp[-1].listval)->release()),
2608  yyvsp[-4].boolval));
2609  ;
2610  break;
2611  }
2612  case 33:
2613 
2614  {
2615  yyval.nodeval = TrackedPtr<Node>::make(
2616  lexer.parsed_node_tokens_,
2617  new DropDBStmt((yyvsp[0].stringval)->release(), yyvsp[-1].boolval));
2618  ;
2619  break;
2620  }
2621  case 34:
2622 
2623  {
2624  yyval.nodeval =
2625  TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
2626  new RenameDatabaseStmt((yyvsp[-3].stringval)->release(),
2627  (yyvsp[0].stringval)->release()));
2628  ;
2629  break;
2630  }
2631  case 35:
2632 
2633  {
2634  yyval.nodeval = TrackedPtr<Node>::make(
2635  lexer.parsed_node_tokens_,
2636  new CreateUserStmt((yyvsp[-3].stringval)->release(),
2637  reinterpret_cast<std::list<NameValueAssign*>*>(
2638  (yyvsp[-1].listval)->release())));
2639  ;
2640  break;
2641  }
2642  case 36:
2643 
2644  {
2645  yyval.nodeval = TrackedPtr<Node>::make(
2646  lexer.parsed_node_tokens_, new DropUserStmt((yyvsp[0].stringval)->release()));
2647  ;
2648  break;
2649  }
2650  case 37:
2651 
2652  {
2653  yyval.nodeval = TrackedPtr<Node>::make(
2654  lexer.parsed_node_tokens_,
2655  new AlterUserStmt((yyvsp[-3].stringval)->release(),
2656  reinterpret_cast<std::list<NameValueAssign*>*>(
2657  (yyvsp[-1].listval)->release())));
2658  ;
2659  break;
2660  }
2661  case 38:
2662 
2663  {
2664  yyval.nodeval =
2665  TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
2666  new RenameUserStmt((yyvsp[-3].stringval)->release(),
2667  (yyvsp[0].stringval)->release()));
2668  ;
2669  break;
2670  }
2671  case 39:
2672 
2673  {
2674  yyval.listval =
2675  TrackedListPtr<Node>::make(lexer.parsed_node_list_tokens_, 1, yyvsp[0].nodeval);
2676  ;
2677  break;
2678  }
2679  case 40:
2680 
2681  {
2682  yyval.listval = yyvsp[-2].listval;
2683  yyval.listval->push_back(yyvsp[0].nodeval);
2684  ;
2685  break;
2686  }
2687  case 41:
2688 
2689  {
2690  yyval.nodeval = TrackedPtr<Node>::make(
2691  lexer.parsed_node_tokens_,
2692  new NameValueAssign((yyvsp[-2].stringval)->release(),
2693  dynamic_cast<Literal*>((yyvsp[0].nodeval)->release())));
2694  ;
2695  break;
2696  }
2697  case 42:
2698 
2699  {
2700  yyval.boolval = true;
2701  ;
2702  break;
2703  }
2704  case 43:
2705 
2706  {
2707  yyval.boolval = false;
2708  ;
2709  break;
2710  }
2711  case 44:
2712 
2713  {
2714  yyval.boolval = true;
2715  ;
2716  break;
2717  }
2718  case 45:
2719 
2720  {
2721  yyval.boolval = false;
2722  ;
2723  break;
2724  }
2725  case 46:
2726 
2727  {
2728  yyval.nodeval = TrackedPtr<Node>::make(
2729  lexer.parsed_node_tokens_,
2730  new CreateTableAsSelectStmt((yyvsp[-3].stringval)->release(),
2731  (yyvsp[-1].stringval)->release(),
2732  yyvsp[-6].boolval,
2733  yyvsp[-4].boolval,
2734  reinterpret_cast<std::list<NameValueAssign*>*>(
2735  (yyvsp[0].listval)->release())));
2736  ;
2737  break;
2738  }
2739  case 47:
2740 
2741  {
2742  yyval.nodeval = TrackedPtr<Node>::make(
2743  lexer.parsed_node_tokens_,
2744  new CreateTableStmt(
2745  (yyvsp[-4].stringval)->release(),
2746  nullptr,
2747  reinterpret_cast<std::list<TableElement*>*>((yyvsp[-2].listval)->release()),
2748  yyvsp[-7].boolval,
2749  yyvsp[-5].boolval,
2750  reinterpret_cast<std::list<NameValueAssign*>*>(
2751  (yyvsp[0].listval)->release())));
2752  ;
2753  break;
2754  }
2755  case 48:
2756 
2757  {
2758  yyval.nodeval = TrackedPtr<Node>::make(
2759  lexer.parsed_node_tokens_,
2760  new CreateTableStmt(
2761  (yyvsp[-4].stringval)->release(),
2762  (yyvsp[-7].stringval)->release(),
2763  reinterpret_cast<std::list<TableElement*>*>((yyvsp[-2].listval)->release()),
2764  false,
2765  yyvsp[-5].boolval,
2766  reinterpret_cast<std::list<NameValueAssign*>*>(
2767  (yyvsp[0].listval)->release())));
2768  ;
2769  break;
2770  }
2771  case 49:
2772 
2773  {
2774  yyval.nodeval = TrackedPtr<Node>::make(
2775  lexer.parsed_node_tokens_,
2776  new CreateDataframeStmt(
2777  (yyvsp[-6].stringval)->release(),
2778  reinterpret_cast<std::list<TableElement*>*>((yyvsp[-4].listval)->release()),
2779  (yyvsp[-1].stringval)->release(),
2780  reinterpret_cast<std::list<NameValueAssign*>*>(
2781  (yyvsp[0].listval)->release())));
2782  ;
2783  break;
2784  }
2785  case 50:
2786 
2787  {
2788  yyval.nodeval = TrackedPtr<Node>::make(
2789  lexer.parsed_node_tokens_,
2790  new ShowCreateTableStmt((yyvsp[0].stringval)->release()));
2791  ;
2792  break;
2793  }
2794  case 51:
2795 
2796  {
2797  yyval.boolval = true;
2798  ;
2799  break;
2800  }
2801  case 52:
2802 
2803  {
2804  yyval.boolval = false;
2805  ;
2806  break;
2807  }
2808  case 53:
2809 
2810  {
2811  yyval.nodeval = TrackedPtr<Node>::make(
2812  lexer.parsed_node_tokens_,
2813  new DropTableStmt((yyvsp[0].stringval)->release(), yyvsp[-1].boolval));
2814  ;
2815  break;
2816  }
2817  case 54:
2818 
2819  {
2820  yyval.nodeval =
2821  TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
2822  new TruncateTableStmt((yyvsp[0].stringval)->release()));
2823  ;
2824  break;
2825  }
2826  case 55:
2827 
2828  {
2829  yyval.nodeval =
2830  TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
2831  new RenameTableStmt((yyvsp[-3].stringval)->release(),
2832  (yyvsp[0].stringval)->release()));
2833  ;
2834  break;
2835  }
2836  case 56:
2837 
2838  {
2839  yyval.nodeval =
2840  TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
2841  new RenameColumnStmt((yyvsp[-5].stringval)->release(),
2842  (yyvsp[-2].stringval)->release(),
2843  (yyvsp[0].stringval)->release()));
2844  ;
2845  break;
2846  }
2847  case 59:
2848 
2849  {
2850  yyval.listval =
2851  TrackedListPtr<Node>::make(lexer.parsed_node_list_tokens_, 1, yyvsp[0].nodeval);
2852  ;
2853  break;
2854  }
2855  case 60:
2856 
2857  {
2858  yyval.listval = yyvsp[-2].listval;
2859  yyval.listval->push_back(yyvsp[0].nodeval);
2860  ;
2861  break;
2862  }
2863  case 61:
2864 
2865  {
2866  yyval.nodeval = TrackedPtr<Node>::make(
2867  lexer.parsed_node_tokens_,
2868  new AddColumnStmt((yyvsp[-3].stringval)->release(),
2869  dynamic_cast<ColumnDef*>((yyvsp[0].nodeval)->release())));
2870  ;
2871  break;
2872  }
2873  case 62:
2874 
2875  {
2876  yyval.nodeval = TrackedPtr<Node>::make(
2877  lexer.parsed_node_tokens_,
2878  new AddColumnStmt(
2879  (yyvsp[-4].stringval)->release(),
2880  reinterpret_cast<std::list<ColumnDef*>*>((yyvsp[-1].listval)->release())));
2881  ;
2882  break;
2883  }
2884  case 63:
2885 
2886  {
2887  yyval.nodeval =
2888  TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
2889  new DropColumnStmt((yyvsp[-1].stringval)->release(),
2890  (yyvsp[0].slistval)->release()));
2891  ;
2892  break;
2893  }
2894  case 64:
2895 
2896  {
2897  yyval.listval =
2898  TrackedListPtr<Node>::make(lexer.parsed_node_list_tokens_, 1, yyvsp[0].nodeval);
2899  ;
2900  break;
2901  }
2902  case 65:
2903 
2904  {
2905  (yyvsp[-2].listval)->push_back(yyvsp[0].nodeval);
2906  ;
2907  break;
2908  }
2909  case 66:
2910 
2911  {
2912  yyval.stringval = yyvsp[0].stringval;
2913  ;
2914  break;
2915  }
2916  case 67:
2917 
2918  {
2919  yyval.nodeval = TrackedPtr<Node>::make(
2920  lexer.parsed_node_tokens_,
2921  new CopyTableStmt((yyvsp[-3].stringval)->release(),
2922  (yyvsp[-1].stringval)->release(),
2923  reinterpret_cast<std::list<NameValueAssign*>*>(
2924  (yyvsp[0].listval)->release())));
2925  ;
2926  break;
2927  }
2928  case 68:
2929 
2930  {
2931  if (!boost::istarts_with(*(yyvsp[-4].stringval)->get(), "SELECT") &&
2932  !boost::istarts_with(*(yyvsp[-4].stringval)->get(), "WITH")) {
2933  throw std::runtime_error("SELECT or WITH statement expected");
2934  }
2935  *(yyvsp[-4].stringval)->get() += ";";
2936  yyval.nodeval = TrackedPtr<Node>::make(
2937  lexer.parsed_node_tokens_,
2938  new ExportQueryStmt((yyvsp[-4].stringval)->release(),
2939  (yyvsp[-1].stringval)->release(),
2940  reinterpret_cast<std::list<NameValueAssign*>*>(
2941  (yyvsp[0].listval)->release())));
2942  ;
2943  break;
2944  }
2945  case 71:
2946 
2947  {
2948  yyval.nodeval = TrackedPtr<Node>::make(
2949  lexer.parsed_node_tokens_,
2950  new DumpTableStmt((yyvsp[-3].stringval)->release(),
2951  (yyvsp[-1].stringval)->release(),
2952  reinterpret_cast<std::list<NameValueAssign*>*>(
2953  (yyvsp[0].listval)->release())));
2954  ;
2955  break;
2956  }
2957  case 72:
2958 
2959  {
2960  yyval.nodeval = TrackedPtr<Node>::make(
2961  lexer.parsed_node_tokens_,
2962  new RestoreTableStmt((yyvsp[-3].stringval)->release(),
2963  (yyvsp[-1].stringval)->release(),
2964  reinterpret_cast<std::list<NameValueAssign*>*>(
2965  (yyvsp[0].listval)->release())));
2966  ;
2967  break;
2968  }
2969  case 73:
2970 
2971  {
2972  yyval.nodeval = TrackedPtr<Node>::make(
2973  lexer.parsed_node_tokens_, new CreateRoleStmt((yyvsp[0].stringval)->release()));
2974  ;
2975  break;
2976  }
2977  case 74:
2978 
2979  {
2980  yyval.nodeval = TrackedPtr<Node>::make(
2981  lexer.parsed_node_tokens_, new DropRoleStmt((yyvsp[0].stringval)->release()));
2982  ;
2983  break;
2984  }
2985  case 75:
2986 
2987  {
2988  yyval.nodeval =
2989  TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
2990  new GrantPrivilegesStmt((yyvsp[-5].slistval)->release(),
2991  (yyvsp[-3].stringval)->release(),
2992  (yyvsp[-2].stringval)->release(),
2993  (yyvsp[0].slistval)->release()));
2994  ;
2995  break;
2996  }
2997  case 76:
2998 
2999  {
3000  yyval.nodeval = TrackedPtr<Node>::make(
3001  lexer.parsed_node_tokens_,
3002  new RevokePrivilegesStmt((yyvsp[-5].slistval)->release(),
3003  (yyvsp[-3].stringval)->release(),
3004  (yyvsp[-2].stringval)->release(),
3005  (yyvsp[0].slistval)->release()));
3006  ;
3007  break;
3008  }
3009  case 77:
3010 
3011  {
3012  yyval.nodeval =
3013  TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
3014  new GrantRoleStmt((yyvsp[-2].slistval)->release(),
3015  (yyvsp[0].slistval)->release()));
3016  ;
3017  break;
3018  }
3019  case 78:
3020 
3021  {
3022  yyval.nodeval =
3023  TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
3024  new RevokeRoleStmt((yyvsp[-2].slistval)->release(),
3025  (yyvsp[0].slistval)->release()));
3026  ;
3027  break;
3028  }
3029  case 79:
3030 
3031  {
3032  yyval.nodeval = TrackedPtr<Node>::make(
3033  lexer.parsed_node_tokens_,
3034  new OptimizeTableStmt((yyvsp[-1].stringval)->release(),
3035  reinterpret_cast<std::list<NameValueAssign*>*>(
3036  (yyvsp[0].listval)->release())));
3037  ;
3038  break;
3039  }
3040  case 80:
3041 
3042  {
3043  yyval.nodeval = TrackedPtr<Node>::make(
3044  lexer.parsed_node_tokens_,
3045  new ValidateStmt((yyvsp[-1].stringval)->release(),
3046  reinterpret_cast<std::list<NameValueAssign*>*>(
3047  (yyvsp[0].listval)->release())));
3048  ;
3049  break;
3050  }
3051  case 81:
3052 
3053  {
3054  yyval.listval =
3055  TrackedListPtr<Node>::make(lexer.parsed_node_list_tokens_, 1, yyvsp[0].nodeval);
3056  ;
3057  break;
3058  }
3059  case 82:
3060 
3061  {
3062  yyval.listval = yyvsp[-2].listval;
3063  yyval.listval->push_back(yyvsp[0].nodeval);
3064  ;
3065  break;
3066  }
3067  case 83:
3068 
3069  {
3070  yyval.nodeval = yyvsp[0].nodeval;
3071  ;
3072  break;
3073  }
3074  case 84:
3075 
3076  {
3077  yyval.nodeval = yyvsp[0].nodeval;
3078  ;
3079  break;
3080  }
3081  case 85:
3082 
3083  {
3084  yyval.nodeval = TrackedPtr<Node>::make(
3085  lexer.parsed_node_tokens_,
3086  new ColumnDef((yyvsp[-2].stringval)->release(),
3087  dynamic_cast<SQLType*>((yyvsp[-1].nodeval)->release()),
3088  dynamic_cast<CompressDef*>((yyvsp[0].nodeval)->release()),
3089  nullptr));
3090  ;
3091  break;
3092  }
3093  case 86:
3094 
3095  {
3096  yyval.nodeval = TrackedPtr<Node>::make(
3097  lexer.parsed_node_tokens_,
3098  new ColumnDef(
3099  (yyvsp[-3].stringval)->release(),
3100  dynamic_cast<SQLType*>((yyvsp[-2].nodeval)->release()),
3101  dynamic_cast<CompressDef*>((yyvsp[0].nodeval)->release()),
3102  dynamic_cast<ColumnConstraintDef*>((yyvsp[-1].nodeval)->release())));
3103  ;
3104  break;
3105  }
3106  case 87:
3107 
3108  {
3109  if (!boost::iequals(*(yyvsp[-1].stringval)->get(), "encoding"))
3110  throw std::runtime_error("Invalid identifier " + *(yyvsp[-1].stringval)->get() +
3111  " in column definition.");
3112  delete (yyvsp[-1].stringval)->release();
3113  yyval.nodeval = TrackedPtr<Node>::make(
3114  lexer.parsed_node_tokens_, new CompressDef((yyvsp[0].stringval)->release(), 0));
3115  ;
3116  break;
3117  }
3118  case 88:
3119 
3120  {
3121  if (!boost::iequals(*(yyvsp[-4].stringval)->get(), "encoding"))
3122  throw std::runtime_error("Invalid identifier " + *(yyvsp[-4].stringval)->get() +
3123  " in column definition.");
3124  delete (yyvsp[-4].stringval)->release();
3125  yyval.nodeval = TrackedPtr<Node>::make(
3126  lexer.parsed_node_tokens_,
3127  new CompressDef((yyvsp[-3].stringval)->release(), (int)yyvsp[-1].intval));
3128  ;
3129  break;
3130  }
3131  case 89:
3132 
3133  {
3134  yyval.nodeval = TrackedPtr<Node>::makeEmpty();
3135  ;
3136  break;
3137  }
3138  case 90:
3139 
3140  {
3141  yyval.nodeval =
3142  TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
3143  new ColumnConstraintDef(true, false, false, nullptr));
3144  ;
3145  break;
3146  }
3147  case 91:
3148 
3149  {
3150  yyval.nodeval = TrackedPtr<Node>::make(
3151  lexer.parsed_node_tokens_, new ColumnConstraintDef(true, true, false, nullptr));
3152  ;
3153  break;
3154  }
3155  case 92:
3156 
3157  {
3158  if (!boost::iequals(*(yyvsp[0].stringval)->get(), "key"))
3159  throw std::runtime_error("Syntax error at " + *(yyvsp[0].stringval)->get());
3160  yyval.nodeval = TrackedPtr<Node>::make(
3161  lexer.parsed_node_tokens_, new ColumnConstraintDef(true, true, true, nullptr));
3162  ;
3163  break;
3164  }
3165  case 93:
3166 
3167  {
3168  yyval.nodeval = TrackedPtr<Node>::make(
3169  lexer.parsed_node_tokens_,
3170  new ColumnConstraintDef(false,
3171  false,
3172  false,
3173  dynamic_cast<Literal*>((yyvsp[0].nodeval)->release())));
3174  ;
3175  break;
3176  }
3177  case 94:
3178 
3179  {
3180  yyval.nodeval = TrackedPtr<Node>::make(
3181  lexer.parsed_node_tokens_,
3182  new ColumnConstraintDef(false, false, false, new NullLiteral()));
3183  ;
3184  break;
3185  }
3186  case 95:
3187 
3188  {
3189  yyval.nodeval = TrackedPtr<Node>::make(
3190  lexer.parsed_node_tokens_,
3191  new ColumnConstraintDef(false, false, false, new UserLiteral()));
3192  ;
3193  break;
3194  }
3195  case 96:
3196 
3197  {
3198  yyval.nodeval = TrackedPtr<Node>::make(
3199  lexer.parsed_node_tokens_,
3200  new ColumnConstraintDef(dynamic_cast<Expr*>((yyvsp[-1].nodeval)->release())));
3201  ;
3202  break;
3203  }
3204  case 97:
3205 
3206  {
3207  yyval.nodeval = TrackedPtr<Node>::make(
3208  lexer.parsed_node_tokens_,
3209  new ColumnConstraintDef((yyvsp[0].stringval)->release(), nullptr));
3210  ;
3211  break;
3212  }
3213  case 98:
3214 
3215  {
3216  yyval.nodeval = TrackedPtr<Node>::make(
3217  lexer.parsed_node_tokens_,
3218  new ColumnConstraintDef((yyvsp[-3].stringval)->release(),
3219  (yyvsp[-1].stringval)->release()));
3220  ;
3221  break;
3222  }
3223  case 99:
3224 
3225  {
3226  yyval.nodeval =
3227  TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
3228  new UniqueDef(false, (yyvsp[-1].slistval)->release()));
3229  ;
3230  break;
3231  }
3232  case 100:
3233 
3234  {
3235  if (!boost::iequals(*(yyvsp[-3].stringval)->get(), "key"))
3236  throw std::runtime_error("Syntax error at " + *(yyvsp[-3].stringval)->get());
3237  yyval.nodeval =
3238  TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
3239  new UniqueDef(true, (yyvsp[-1].slistval)->release()));
3240  ;
3241  break;
3242  }
3243  case 101:
3244 
3245  {
3246  if (!boost::iequals(*(yyvsp[-5].stringval)->get(), "key"))
3247  throw std::runtime_error("Syntax error at " + *(yyvsp[-5].stringval)->get());
3248  yyval.nodeval = TrackedPtr<Node>::make(
3249  lexer.parsed_node_tokens_,
3250  new ForeignKeyDef(
3251  (yyvsp[-3].slistval)->release(), (yyvsp[0].stringval)->release(), nullptr));
3252  ;
3253  break;
3254  }
3255  case 102:
3256 
3257  {
3258  if (!boost::iequals(*(yyvsp[-8].stringval)->get(), "key"))
3259  throw std::runtime_error("Syntax error at " + *(yyvsp[-8].stringval)->get());
3260  yyval.nodeval =
3261  TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
3262  new ForeignKeyDef((yyvsp[-6].slistval)->release(),
3263  (yyvsp[-3].stringval)->release(),
3264  (yyvsp[-1].slistval)->release()));
3265  ;
3266  break;
3267  }
3268  case 103:
3269 
3270  {
3271  if (!boost::iequals(*(yyvsp[-3].stringval)->get(), "key"))
3272  throw std::runtime_error("Syntax error at " + *(yyvsp[-3].stringval)->get());
3273  yyval.nodeval = TrackedPtr<Node>::make(
3274  lexer.parsed_node_tokens_, new ShardKeyDef(*(yyvsp[-1].stringval)->get()));
3275  delete (yyvsp[-3].stringval)->release();
3276  delete (yyvsp[-1].stringval)->release();
3277  ;
3278  break;
3279  }
3280  case 104:
3281 
3282  {
3283  yyval.nodeval =
3284  TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
3285  new SharedDictionaryDef(*(yyvsp[-6].stringval)->get(),
3286  *(yyvsp[-3].stringval)->get(),
3287  *(yyvsp[-1].stringval)->get()));
3288  delete (yyvsp[-6].stringval)->release();
3289  delete (yyvsp[-3].stringval)->release();
3290  delete (yyvsp[-1].stringval)->release();
3291  ;
3292  break;
3293  }
3294  case 105:
3295 
3296  {
3297  yyval.nodeval = TrackedPtr<Node>::make(
3298  lexer.parsed_node_tokens_,
3299  new CheckDef(dynamic_cast<Expr*>((yyvsp[-1].nodeval)->release())));
3300  ;
3301  break;
3302  }
3303  case 106:
3304 
3305  {
3306  yyval.slistval = TrackedListPtr<std::string>::make(
3307  lexer.parsed_str_list_tokens_, 1, yyvsp[0].stringval);
3308  ;
3309  break;
3310  }
3311  case 107:
3312 
3313  {
3314  yyval.slistval = yyvsp[-2].slistval;
3315  yyval.slistval->push_back(yyvsp[0].stringval);
3316  ;
3317  break;
3318  }
3319  case 108:
3320 
3321  {
3322  yyval.listval = yyvsp[-1].listval;
3323  ;
3324  break;
3325  }
3326  case 109:
3327 
3328  {
3329  yyval.listval = TrackedListPtr<Node>::makeEmpty();
3330  ;
3331  break;
3332  }
3333  case 110:
3334 
3335  {
3336  yyval.nodeval = TrackedPtr<Node>::make(
3337  lexer.parsed_node_tokens_,
3338  new DropViewStmt((yyvsp[0].stringval)->release(), yyvsp[-1].boolval));
3339  ;
3340  break;
3341  }
3342  case 111:
3343 
3344  {
3345  yyval.slistval = TrackedListPtr<std::string>::makeEmpty();
3346  ;
3347  break;
3348  }
3349  case 112:
3350 
3351  {
3352  yyval.slistval = yyvsp[-1].slistval;
3353  ;
3354  break;
3355  }
3356  case 113:
3357 
3358  {
3359  yyval.listval = TrackedListPtr<Node>::makeEmpty();
3360  ;
3361  break;
3362  }
3363  case 114:
3364 
3365  {
3366  yyval.listval = yyvsp[0].listval;
3367  ;
3368  break;
3369  }
3370  case 115:
3371 
3372  {
3373  yyval.listval =
3374  TrackedListPtr<Node>::make(lexer.parsed_node_list_tokens_, 1, yyvsp[0].nodeval);
3375  ;
3376  break;
3377  }
3378  case 116:
3379 
3380  {
3381  yyval.listval = yyvsp[-2].listval;
3382  yyval.listval->push_back(yyvsp[0].nodeval);
3383  ;
3384  break;
3385  }
3386  case 117:
3387 
3388  {
3389  yyval.nodeval = TrackedPtr<Node>::make(
3390  lexer.parsed_node_tokens_,
3391  new OrderSpec(yyvsp[-2].intval, nullptr, yyvsp[-1].boolval, yyvsp[0].boolval));
3392  ;
3393  break;
3394  }
3395  case 118:
3396 
3397  {
3398  yyval.nodeval = TrackedPtr<Node>::make(
3399  lexer.parsed_node_tokens_,
3400  new OrderSpec(0,
3401  dynamic_cast<ColumnRef*>((yyvsp[-2].nodeval)->release()),
3402  yyvsp[-1].boolval,
3403  yyvsp[0].boolval));
3404  ;
3405  break;
3406  }
3407  case 119:
3408 
3409  {
3410  yyval.boolval = false; /* default is ASC */
3411  ;
3412  break;
3413  }
3414  case 120:
3415 
3416  {
3417  yyval.boolval = false;
3418  ;
3419  break;
3420  }
3421  case 121:
3422 
3423  {
3424  yyval.boolval = true;
3425  ;
3426  break;
3427  }
3428  case 122:
3429 
3430  {
3431  yyval.boolval = false; /* default is NULL LAST */
3432  ;
3433  break;
3434  }
3435  case 123:
3436 
3437  {
3438  yyval.boolval = true;
3439  ;
3440  break;
3441  }
3442  case 124:
3443 
3444  {
3445  yyval.boolval = false;
3446  ;
3447  break;
3448  }
3449  case 130:
3450 
3451  {
3452  yyval.nodeval = TrackedPtr<Node>::make(
3453  lexer.parsed_node_tokens_,
3454  new DeleteStmt((yyvsp[-1].stringval)->release(),
3455  dynamic_cast<Expr*>((yyvsp[0].nodeval)->release())));
3456  ;
3457  break;
3458  }
3459  case 131:
3460 
3461  {
3462  yyval.nodeval = TrackedPtr<Node>::make(
3463  lexer.parsed_node_tokens_,
3464  new InsertValuesStmt(
3465  (yyvsp[-5].stringval)->release(),
3466  (yyvsp[-4].slistval)->release(),
3467  reinterpret_cast<std::list<Expr*>*>((yyvsp[-1].listval)->release())));
3468  ;
3469  break;
3470  }
3471  case 132:
3472 
3473  {
3474  yyval.nodeval = TrackedPtr<Node>::make(
3475  lexer.parsed_node_tokens_,
3476  new InsertIntoTableAsSelectStmt((yyvsp[-2].stringval)->release(),
3477  (yyvsp[0].stringval)->release(),
3478  (yyvsp[-1].slistval)->release()));
3479  ;
3480  break;
3481  }
3482  case 133:
3483 
3484  {
3485  yyval.boolval = false;
3486  ;
3487  break;
3488  }
3489  case 134:
3490 
3491  {
3492  yyval.boolval = false;
3493  ;
3494  break;
3495  }
3496  case 135:
3497 
3498  {
3499  yyval.boolval = true;
3500  ;
3501  break;
3502  }
3503  case 136:
3504 
3505  {
3506  yyval.listval =
3507  TrackedListPtr<Node>::make(lexer.parsed_node_list_tokens_, 1, yyvsp[0].nodeval);
3508  ;
3509  break;
3510  }
3511  case 137:
3512 
3513  {
3514  yyval.listval = yyvsp[-2].listval;
3515  yyval.listval->push_back(yyvsp[0].nodeval);
3516  ;
3517  break;
3518  }
3519  case 138:
3520 
3521  {
3522  yyval.nodeval = TrackedPtr<Node>::make(
3523  lexer.parsed_node_tokens_,
3524  new Assignment((yyvsp[-2].stringval)->release(),
3525  dynamic_cast<Expr*>((yyvsp[0].nodeval)->release())));
3526  ;
3527  break;
3528  }
3529  case 139:
3530 
3531  {
3532  yyval.nodeval = TrackedPtr<Node>::make(
3533  lexer.parsed_node_tokens_,
3534  new UpdateStmt(
3535  (yyvsp[-3].stringval)->release(),
3536  reinterpret_cast<std::list<Assignment*>*>((yyvsp[-1].listval)->release()),
3537  dynamic_cast<Expr*>((yyvsp[0].nodeval)->release())));
3538  ;
3539  break;
3540  }
3541  case 140:
3542 
3543  {
3544  yyval.nodeval = TrackedPtr<Node>::makeEmpty();
3545  ;
3546  break;
3547  }
3548  case 141:
3549 
3550  {
3551  yyval.nodeval = yyvsp[0].nodeval;
3552  ;
3553  break;
3554  }
3555  case 142:
3556 
3557  {
3558  yyval.intval = yyvsp[0].intval;
3559  if (yyval.intval <= 0)
3560  throw std::runtime_error("LIMIT must be positive.");
3561  ;
3562  break;
3563  }
3564  case 143:
3565 
3566  {
3567  yyval.intval = 0; /* 0 means ALL */
3568  ;
3569  break;
3570  }
3571  case 144:
3572 
3573  {
3574  yyval.intval = 0; /* 0 means ALL */
3575  ;
3576  break;
3577  }
3578  case 145:
3579 
3580  {
3581  yyval.intval = yyvsp[0].intval;
3582  ;
3583  break;
3584  }
3585  case 146:
3586 
3587  {
3588  if (!boost::iequals(*(yyvsp[0].stringval)->get(), "row") &&
3589  !boost::iequals(*(yyvsp[0].stringval)->get(), "rows"))
3590  throw std::runtime_error("Invalid word in OFFSET clause " +
3591  *(yyvsp[0].stringval)->get());
3592  delete (yyvsp[0].stringval)->release();
3593  yyval.intval = yyvsp[-1].intval;
3594  ;
3595  break;
3596  }
3597  case 147:
3598 
3599  {
3600  yyval.intval = 0;
3601  ;
3602  break;
3603  }
3604  case 148:
3605 
3606  {
3607  yyval.nodeval = TrackedPtr<Node>::make(
3608  lexer.parsed_node_tokens_,
3609  new SelectStmt(
3610  dynamic_cast<QueryExpr*>((yyvsp[-3].nodeval)->release()),
3611  reinterpret_cast<std::list<OrderSpec*>*>((yyvsp[-2].listval)->release()),
3612  yyvsp[-1].intval,
3613  yyvsp[0].intval));
3614  ;
3615  break;
3616  }
3617  case 149:
3618 
3619  {
3620  yyval.nodeval = yyvsp[0].nodeval;
3621  ;
3622  break;
3623  }
3624  case 150:
3625 
3626  {
3627  yyval.nodeval = TrackedPtr<Node>::make(
3628  lexer.parsed_node_tokens_,
3629  new UnionQuery(false,
3630  dynamic_cast<QueryExpr*>((yyvsp[-2].nodeval)->release()),
3631  dynamic_cast<QueryExpr*>((yyvsp[0].nodeval)->release())));
3632  ;
3633  break;
3634  }
3635  case 151:
3636 
3637  {
3638  yyval.nodeval = TrackedPtr<Node>::make(
3639  lexer.parsed_node_tokens_,
3640  new UnionQuery(true,
3641  dynamic_cast<QueryExpr*>((yyvsp[-3].nodeval)->release()),
3642  dynamic_cast<QueryExpr*>((yyvsp[0].nodeval)->release())));
3643  ;
3644  break;
3645  }
3646  case 152:
3647 
3648  {
3649  yyval.nodeval = yyvsp[0].nodeval;
3650  ;
3651  break;
3652  }
3653  case 153:
3654 
3655  {
3656  yyval.nodeval = yyvsp[-1].nodeval;
3657  ;
3658  break;
3659  }
3660  case 154:
3661 
3662  {
3663  yyval.nodeval = TrackedPtr<Node>::make(
3664  lexer.parsed_node_tokens_,
3665  new QuerySpec(
3666  yyvsp[-5].boolval,
3667  reinterpret_cast<std::list<SelectEntry*>*>((yyvsp[-4].listval)->release()),
3668  reinterpret_cast<std::list<TableRef*>*>((yyvsp[-3].listval)->release()),
3669  dynamic_cast<Expr*>((yyvsp[-2].nodeval)->release()),
3670  reinterpret_cast<std::list<Expr*>*>((yyvsp[-1].listval)->release()),
3671  dynamic_cast<Expr*>((yyvsp[0].nodeval)->release())));
3672  ;
3673  break;
3674  }
3675  case 155:
3676 
3677  {
3678  yyval.listval = yyvsp[0].listval;
3679  ;
3680  break;
3681  }
3682  case 156:
3683 
3684  {
3685  yyval.listval = TrackedListPtr<Node>::makeEmpty(); /* nullptr means SELECT * */
3686  ;
3687  break;
3688  }
3689  case 157:
3690 
3691  {
3692  yyval.listval = yyvsp[0].listval;
3693  ;
3694  break;
3695  }
3696  case 158:
3697 
3698  {
3699  yyval.listval =
3700  TrackedListPtr<Node>::make(lexer.parsed_node_list_tokens_, 1, yyvsp[0].nodeval);
3701  ;
3702  break;
3703  }
3704  case 159:
3705 
3706  {
3707  yyval.listval = yyvsp[-2].listval;
3708  yyval.listval->push_back(yyvsp[0].nodeval);
3709  ;
3710  break;
3711  }
3712  case 160:
3713 
3714  {
3715  yyval.nodeval = TrackedPtr<Node>::make(
3716  lexer.parsed_node_tokens_, new TableRef((yyvsp[0].stringval)->release()));
3717  ;
3718  break;
3719  }
3720  case 161:
3721 
3722  {
3723  yyval.nodeval =
3724  TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
3725  new TableRef((yyvsp[-1].stringval)->release(),
3726  (yyvsp[0].stringval)->release()));
3727  ;
3728  break;
3729  }
3730  case 162:
3731 
3732  {
3733  yyval.nodeval = yyvsp[0].nodeval;
3734  ;
3735  break;
3736  }
3737  case 163:
3738 
3739  {
3740  yyval.listval = TrackedListPtr<Node>::makeEmpty();
3741  ;
3742  break;
3743  }
3744  case 164:
3745 
3746  {
3747  yyval.listval = yyvsp[0].listval;
3748  ;
3749  break;
3750  }
3751  case 165:
3752 
3753  {
3754  yyval.listval =
3755  TrackedListPtr<Node>::make(lexer.parsed_node_list_tokens_, 1, yyvsp[0].nodeval);
3756  ;
3757  break;
3758  }
3759  case 166:
3760 
3761  {
3762  yyval.listval = yyvsp[-2].listval;
3763  yyval.listval->push_back(yyvsp[0].nodeval);
3764  ;
3765  break;
3766  }
3767  case 167:
3768 
3769  {
3770  yyval.nodeval = TrackedPtr<Node>::makeEmpty();
3771  ;
3772  break;
3773  }
3774  case 168:
3775 
3776  {
3777  yyval.nodeval = yyvsp[0].nodeval;
3778  ;
3779  break;
3780  }
3781  case 169:
3782 
3783  {
3784  yyval.nodeval = TrackedPtr<Node>::make(
3785  lexer.parsed_node_tokens_,
3786  new OperExpr(kOR,
3787  dynamic_cast<Expr*>((yyvsp[-2].nodeval)->release()),
3788  dynamic_cast<Expr*>((yyvsp[0].nodeval)->release())));
3789  ;
3790  break;
3791  }
3792  case 170:
3793 
3794  {
3795  yyval.nodeval = TrackedPtr<Node>::make(
3796  lexer.parsed_node_tokens_,
3797  new OperExpr(kAND,
3798  dynamic_cast<Expr*>((yyvsp[-2].nodeval)->release()),
3799  dynamic_cast<Expr*>((yyvsp[0].nodeval)->release())));
3800  ;
3801  break;
3802  }
3803  case 171:
3804 
3805  {
3806  yyval.nodeval = TrackedPtr<Node>::make(
3807  lexer.parsed_node_tokens_,
3808  new OperExpr(
3809  kNOT, dynamic_cast<Expr*>((yyvsp[0].nodeval)->release()), nullptr));
3810  ;
3811  break;
3812  }
3813  case 172:
3814 
3815  {
3816  yyval.nodeval = yyvsp[-1].nodeval;
3817  ;
3818  break;
3819  }
3820  case 173:
3821 
3822  {
3823  yyval.nodeval = yyvsp[0].nodeval;
3824  ;
3825  break;
3826  }
3827  case 174:
3828 
3829  {
3830  yyval.nodeval = yyvsp[0].nodeval;
3831  ;
3832  break;
3833  }
3834  case 175:
3835 
3836  {
3837  yyval.nodeval = yyvsp[0].nodeval;
3838  ;
3839  break;
3840  }
3841  case 176:
3842 
3843  {
3844  yyval.nodeval = yyvsp[0].nodeval;
3845  ;
3846  break;
3847  }
3848  case 177:
3849 
3850  {
3851  yyval.nodeval = yyvsp[0].nodeval;
3852  ;
3853  break;
3854  }
3855  case 178:
3856 
3857  {
3858  yyval.nodeval = yyvsp[0].nodeval;
3859  ;
3860  break;
3861  }
3862  case 179:
3863 
3864  {
3865  yyval.nodeval = yyvsp[0].nodeval;
3866  ;
3867  break;
3868  }
3869  case 180:
3870 
3871  {
3872  yyval.nodeval = yyvsp[0].nodeval;
3873  ;
3874  break;
3875  }
3876  case 181:
3877 
3878  {
3879  yyval.nodeval = yyvsp[0].nodeval;
3880  ;
3881  break;
3882  }
3883  case 182:
3884 
3885  {
3886  yyval.nodeval = TrackedPtr<Node>::make(
3887  lexer.parsed_node_tokens_,
3888  new OperExpr(yyvsp[-1].opval,
3889  dynamic_cast<Expr*>((yyvsp[-2].nodeval)->release()),
3890  dynamic_cast<Expr*>((yyvsp[0].nodeval)->release())));
3891  ;
3892  break;
3893  }
3894  case 183:
3895 
3896  {
3897  yyval.nodeval = TrackedPtr<Node>::make(
3898  lexer.parsed_node_tokens_,
3899  new OperExpr(yyvsp[-1].opval,
3900  kONE,
3901  dynamic_cast<Expr*>((yyvsp[-2].nodeval)->release()),
3902  dynamic_cast<Expr*>((yyvsp[0].nodeval)->release())));
3903  /* subquery can only return a single result */
3904  ;
3905  break;
3906  }
3907  case 184:
3908 
3909  {
3910  yyval.nodeval = TrackedPtr<Node>::make(
3911  lexer.parsed_node_tokens_,
3912  new BetweenExpr(true,
3913  dynamic_cast<Expr*>((yyvsp[-5].nodeval)->release()),
3914  dynamic_cast<Expr*>((yyvsp[-2].nodeval)->release()),
3915  dynamic_cast<Expr*>((yyvsp[0].nodeval)->release())));
3916  ;
3917  break;
3918  }
3919  case 185:
3920 
3921  {
3922  yyval.nodeval = TrackedPtr<Node>::make(
3923  lexer.parsed_node_tokens_,
3924  new BetweenExpr(false,
3925  dynamic_cast<Expr*>((yyvsp[-4].nodeval)->release()),
3926  dynamic_cast<Expr*>((yyvsp[-2].nodeval)->release()),
3927  dynamic_cast<Expr*>((yyvsp[0].nodeval)->release())));
3928  ;
3929  break;
3930  }
3931  case 186:
3932 
3933  {
3934  yyval.nodeval = TrackedPtr<Node>::make(
3935  lexer.parsed_node_tokens_,
3936  new LikeExpr(true,
3937  false,
3938  dynamic_cast<Expr*>((yyvsp[-4].nodeval)->release()),
3939  dynamic_cast<Expr*>((yyvsp[-1].nodeval)->release()),
3940  dynamic_cast<Expr*>((yyvsp[0].nodeval)->release())));
3941  ;
3942  break;
3943  }
3944  case 187:
3945 
3946  {
3947  yyval.nodeval = TrackedPtr<Node>::make(
3948  lexer.parsed_node_tokens_,
3949  new LikeExpr(false,
3950  false,
3951  dynamic_cast<Expr*>((yyvsp[-3].nodeval)->release()),
3952  dynamic_cast<Expr*>((yyvsp[-1].nodeval)->release()),
3953  dynamic_cast<Expr*>((yyvsp[0].nodeval)->release())));
3954  ;
3955  break;
3956  }
3957  case 188:
3958 
3959  {
3960  yyval.nodeval = TrackedPtr<Node>::make(
3961  lexer.parsed_node_tokens_,
3962  new LikeExpr(true,
3963  true,
3964  dynamic_cast<Expr*>((yyvsp[-4].nodeval)->release()),
3965  dynamic_cast<Expr*>((yyvsp[-1].nodeval)->release()),
3966  dynamic_cast<Expr*>((yyvsp[0].nodeval)->release())));
3967  ;
3968  break;
3969  }
3970  case 189:
3971 
3972  {
3973  yyval.nodeval = TrackedPtr<Node>::make(
3974  lexer.parsed_node_tokens_,
3975  new LikeExpr(false,
3976  true,
3977  dynamic_cast<Expr*>((yyvsp[-3].nodeval)->release()),
3978  dynamic_cast<Expr*>((yyvsp[-1].nodeval)->release()),
3979  dynamic_cast<Expr*>((yyvsp[0].nodeval)->release())));
3980  ;
3981  break;
3982  }
3983  case 190:
3984 
3985  {
3986  yyval.nodeval = TrackedPtr<Node>::makeEmpty();
3987  ;
3988  break;
3989  }
3990  case 191:
3991 
3992  {
3993  std::string escape_tok = *(yyvsp[-1].stringval)->get();
3994  std::transform(escape_tok.begin(), escape_tok.end(), escape_tok.begin(), ::tolower);
3995  if (escape_tok != "escape") {
3996  throw std::runtime_error("Syntax error: wrong escape specifier");
3997  }
3998  delete (yyvsp[-1].stringval)->release();
3999  yyval.nodeval = yyvsp[0].nodeval;
4000  ;
4001  break;
4002  }
4003  case 192:
4004 
4005  {
4006  yyval.nodeval = TrackedPtr<Node>::make(
4007  lexer.parsed_node_tokens_,
4008  new IsNullExpr(true, dynamic_cast<Expr*>((yyvsp[-3].nodeval)->release())));
4009  ;
4010  break;
4011  }
4012  case 193:
4013 
4014  {
4015  yyval.nodeval = TrackedPtr<Node>::make(
4016  lexer.parsed_node_tokens_,
4017  new IsNullExpr(false, dynamic_cast<Expr*>((yyvsp[-2].nodeval)->release())));
4018  ;
4019  break;
4020  }
4021  case 194:
4022 
4023  {
4024  yyval.nodeval = TrackedPtr<Node>::make(
4025  lexer.parsed_node_tokens_,
4026  new InSubquery(true,
4027  dynamic_cast<Expr*>((yyvsp[-3].nodeval)->release()),
4028  dynamic_cast<SubqueryExpr*>((yyvsp[0].nodeval)->release())));
4029  ;
4030  break;
4031  }
4032  case 195:
4033 
4034  {
4035  yyval.nodeval = TrackedPtr<Node>::make(
4036  lexer.parsed_node_tokens_,
4037  new InSubquery(false,
4038  dynamic_cast<Expr*>((yyvsp[-2].nodeval)->release()),
4039  dynamic_cast<SubqueryExpr*>((yyvsp[0].nodeval)->release())));
4040  ;
4041  break;
4042  }
4043  case 196:
4044 
4045  {
4046  yyval.nodeval = TrackedPtr<Node>::make(
4047  lexer.parsed_node_tokens_,
4048  new InValues(
4049  true,
4050  dynamic_cast<Expr*>((yyvsp[-5].nodeval)->release()),
4051  reinterpret_cast<std::list<Expr*>*>((yyvsp[-1].listval)->release())));
4052  ;
4053  break;
4054  }
4055  case 197:
4056 
4057  {
4058  yyval.nodeval = TrackedPtr<Node>::make(
4059  lexer.parsed_node_tokens_,
4060  new InValues(
4061  false,
4062  dynamic_cast<Expr*>((yyvsp[-4].nodeval)->release()),
4063  reinterpret_cast<std::list<Expr*>*>((yyvsp[-1].listval)->release())));
4064  ;
4065  break;
4066  }
4067  case 198:
4068 
4069  {
4070  yyval.listval =
4071  TrackedListPtr<Node>::make(lexer.parsed_node_list_tokens_, 1, yyvsp[0].nodeval);
4072  ;
4073  break;
4074  }
4075  case 199:
4076 
4077  {
4078  yyval.listval = yyvsp[-2].listval;
4079  yyval.listval->push_back(yyvsp[0].nodeval);
4080  ;
4081  break;
4082  }
4083  case 200:
4084 
4085  {
4086  yyval.nodeval = TrackedPtr<Node>::make(
4087  lexer.parsed_node_tokens_,
4088  new OperExpr(yyvsp[-2].opval,
4089  yyvsp[-1].qualval,
4090  dynamic_cast<Expr*>((yyvsp[-3].nodeval)->release()),
4091  dynamic_cast<Expr*>((yyvsp[0].nodeval)->release())));
4092  ;
4093  break;
4094  }
4095  case 201:
4096 
4097  {
4098  yyval.nodeval = TrackedPtr<Node>::make(
4099  lexer.parsed_node_tokens_,
4100  new OperExpr(yyvsp[-2].opval,
4101  yyvsp[-1].qualval,
4102  dynamic_cast<Expr*>((yyvsp[-3].nodeval)->release()),
4103  dynamic_cast<Expr*>((yyvsp[0].nodeval)->release())));
4104  ;
4105  break;
4106  }
4107  case 202:
4108 
4109  {
4110  yyval.opval = yyvsp[0].opval;
4111  ;
4112  break;
4113  }
4114  case 203:
4115 
4116  {
4117  yyval.opval = yyvsp[0].opval;
4118  ;
4119  break;
4120  }
4121  case 207:
4122 
4123  {
4124  yyval.nodeval = TrackedPtr<Node>::make(
4125  lexer.parsed_node_tokens_,
4126  new ExistsExpr(dynamic_cast<QuerySpec*>((yyvsp[0].nodeval)->release())));
4127  ;
4128  break;
4129  }
4130  case 208:
4131 
4132  {
4133  yyval.nodeval = TrackedPtr<Node>::make(
4134  lexer.parsed_node_tokens_,
4135  new SubqueryExpr(dynamic_cast<QuerySpec*>((yyvsp[-1].nodeval)->release())));
4136  ;
4137  break;
4138  }
4139  case 209:
4140 
4141  {
4142  yyval.listval = TrackedListPtr<Node>::make(
4143  lexer.parsed_node_list_tokens_,
4144  1,
4145  new ExprPair(dynamic_cast<Expr*>((yyvsp[-2].nodeval)->release()),
4146  dynamic_cast<Expr*>((yyvsp[0].nodeval)->release())));
4147  ;
4148  break;
4149  }
4150  case 210:
4151 
4152  {
4153  yyval.listval = yyvsp[-4].listval;
4154  yyval.listval->push_back(
4155  new ExprPair(dynamic_cast<Expr*>((yyvsp[-2].nodeval)->release()),
4156  dynamic_cast<Expr*>((yyvsp[0].nodeval)->release())));
4157  ;
4158  break;
4159  }
4160  case 211:
4161 
4162  {
4163  yyval.nodeval = yyvsp[0].nodeval;
4164  ;
4165  break;
4166  }
4167  case 212:
4168 
4169  {
4170  yyval.nodeval = TrackedPtr<Node>::makeEmpty();
4171  ;
4172  break;
4173  }
4174  case 213:
4175 
4176  {
4177  yyval.nodeval = TrackedPtr<Node>::make(
4178  lexer.parsed_node_tokens_,
4179  new CaseExpr(
4180  reinterpret_cast<std::list<ExprPair*>*>((yyvsp[-2].listval)->release()),
4181  dynamic_cast<Expr*>((yyvsp[-1].nodeval)->release())));
4182  ;
4183  break;
4184  }
4185  case 214:
4186 
4187  {
4188  std::list<ExprPair*>* when_then_list = new std::list<ExprPair*>(
4189  1,
4190  new ExprPair(dynamic_cast<Expr*>((yyvsp[-5].nodeval)->release()),
4191  dynamic_cast<Expr*>((yyvsp[-3].nodeval)->release())));
4192  yyval.nodeval = TrackedPtr<Node>::make(
4193  lexer.parsed_node_tokens_,
4194  new CaseExpr(when_then_list,
4195  dynamic_cast<Expr*>((yyvsp[-1].nodeval)->release())));
4196  ;
4197  break;
4198  }
4199  case 215:
4200 
4201  {
4202  std::list<ExprPair*>* when_then_list = new std::list<ExprPair*>(
4203  1,
4204  new ExprPair(dynamic_cast<Expr*>((yyvsp[-3].nodeval)->release()),
4205  dynamic_cast<Expr*>((yyvsp[-1].nodeval)->release())));
4206  yyval.nodeval = TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
4207  new CaseExpr(when_then_list, nullptr));
4208  ;
4209  break;
4210  }
4211  case 216:
4212 
4213  {
4214  yyval.nodeval = TrackedPtr<Node>::make(
4215  lexer.parsed_node_tokens_,
4216  new CharLengthExpr(dynamic_cast<Expr*>((yyvsp[-1].nodeval)->release()), true));
4217  ;
4218  break;
4219  }
4220  case 217:
4221 
4222  {
4223  yyval.nodeval = TrackedPtr<Node>::make(
4224  lexer.parsed_node_tokens_,
4225  new CharLengthExpr(dynamic_cast<Expr*>((yyvsp[-1].nodeval)->release()), false));
4226  ;
4227  break;
4228  }
4229  case 218:
4230 
4231  {
4232  yyval.nodeval = TrackedPtr<Node>::make(
4233  lexer.parsed_node_tokens_,
4234  new OperExpr(kARRAY_AT,
4235  dynamic_cast<Expr*>((yyvsp[-3].nodeval)->release()),
4236  dynamic_cast<Expr*>((yyvsp[-1].nodeval)->release())));
4237  ;
4238  break;
4239  }
4240  case 219:
4241 
4242  {
4243  yyval.nodeval = TrackedPtr<Node>::make(
4244  lexer.parsed_node_tokens_,
4245  new OperExpr(kPLUS,
4246  dynamic_cast<Expr*>((yyvsp[-2].nodeval)->release()),
4247  dynamic_cast<Expr*>((yyvsp[0].nodeval)->release())));
4248  ;
4249  break;
4250  }
4251  case 220:
4252 
4253  {
4254  yyval.nodeval = TrackedPtr<Node>::make(
4255  lexer.parsed_node_tokens_,
4256  new OperExpr(kMINUS,
4257  dynamic_cast<Expr*>((yyvsp[-2].nodeval)->release()),
4258  dynamic_cast<Expr*>((yyvsp[0].nodeval)->release())));
4259  ;
4260  break;
4261  }
4262  case 221:
4263 
4264  {
4265  yyval.nodeval = TrackedPtr<Node>::make(
4266  lexer.parsed_node_tokens_,
4267  new OperExpr(kMULTIPLY,
4268  dynamic_cast<Expr*>((yyvsp[-2].nodeval)->release()),
4269  dynamic_cast<Expr*>((yyvsp[0].nodeval)->release())));
4270  ;
4271  break;
4272  }
4273  case 222:
4274 
4275  {
4276  yyval.nodeval = TrackedPtr<Node>::make(
4277  lexer.parsed_node_tokens_,
4278  new OperExpr(kDIVIDE,
4279  dynamic_cast<Expr*>((yyvsp[-2].nodeval)->release()),
4280  dynamic_cast<Expr*>((yyvsp[0].nodeval)->release())));
4281  ;
4282  break;
4283  }
4284  case 223:
4285 
4286  {
4287  yyval.nodeval = TrackedPtr<Node>::make(
4288  lexer.parsed_node_tokens_,
4289  new OperExpr(kMODULO,
4290  dynamic_cast<Expr*>((yyvsp[-2].nodeval)->release()),
4291  dynamic_cast<Expr*>((yyvsp[0].nodeval)->release())));
4292  ;
4293  break;
4294  }
4295  case 224:
4296 
4297  {
4298  yyval.nodeval = TrackedPtr<Node>::make(
4299  lexer.parsed_node_tokens_,
4300  new OperExpr(kMODULO,
4301  dynamic_cast<Expr*>((yyvsp[-3].nodeval)->release()),
4302  dynamic_cast<Expr*>((yyvsp[-1].nodeval)->release())));
4303  ;
4304  break;
4305  }
4306  case 225:
4307 
4308  {
4309  yyval.nodeval = yyvsp[0].nodeval;
4310  ;
4311  break;
4312  }
4313  case 226:
4314 
4315  {
4316  yyval.nodeval = TrackedPtr<Node>::make(
4317  lexer.parsed_node_tokens_,
4318  new OperExpr(
4319  kUMINUS, dynamic_cast<Expr*>((yyvsp[0].nodeval)->release()), nullptr));
4320  ;
4321  break;
4322  }
4323  case 227:
4324 
4325  {
4326  yyval.nodeval = yyvsp[0].nodeval;
4327  ;
4328  break;
4329  }
4330  case 228:
4331 
4332  {
4333  yyval.nodeval = yyvsp[0].nodeval;
4334  ;
4335  break;
4336  }
4337  case 229:
4338 
4339  {
4340  yyval.nodeval = yyvsp[0].nodeval;
4341  ;
4342  break;
4343  }
4344  case 230:
4345 
4346  {
4347  yyval.nodeval = yyvsp[-1].nodeval;
4348  ;
4349  break;
4350  }
4351  case 231:
4352 
4353  {
4354  yyval.nodeval = TrackedPtr<Node>::make(
4355  lexer.parsed_node_tokens_,
4356  new CastExpr(dynamic_cast<Expr*>((yyvsp[-3].nodeval)->release()),
4357  dynamic_cast<SQLType*>((yyvsp[-1].nodeval)->release())));
4358  ;
4359  break;
4360  }
4361  case 232:
4362 
4363  {
4364  yyval.nodeval = yyvsp[0].nodeval;
4365  ;
4366  break;
4367  }
4368  case 233:
4369 
4370  {
4371  yyval.nodeval = yyvsp[0].nodeval;
4372  ;
4373  break;
4374  }
4375  case 234:
4376 
4377  {
4378  yyval.nodeval = yyvsp[0].nodeval;
4379  ;
4380  break;
4381  }
4382  case 235:
4383 
4384  {
4385  throw std::runtime_error("Empty select entry");
4386  ;
4387  break;
4388  }
4389  case 236:
4390 
4391  {
4392  yyval.nodeval = TrackedPtr<Node>::make(
4393  lexer.parsed_node_tokens_,
4394  new SelectEntry(dynamic_cast<Expr*>((yyvsp[0].nodeval)->release()), nullptr));
4395  ;
4396  break;
4397  }
4398  case 237:
4399 
4400  {
4401  yyval.nodeval = TrackedPtr<Node>::make(
4402  lexer.parsed_node_tokens_,
4403  new SelectEntry(dynamic_cast<Expr*>((yyvsp[-1].nodeval)->release()),
4404  (yyvsp[0].stringval)->release()));
4405  ;
4406  break;
4407  }
4408  case 238:
4409 
4410  {
4411  yyval.nodeval = TrackedPtr<Node>::make(
4412  lexer.parsed_node_tokens_,
4413  new SelectEntry(dynamic_cast<Expr*>((yyvsp[-2].nodeval)->release()),
4414  (yyvsp[0].stringval)->release()));
4415  ;
4416  break;
4417  }
4418  case 239:
4419 
4420  {
4421  throw std::runtime_error("Empty select entry list");
4422  ;
4423  break;
4424  }
4425  case 240:
4426 
4427  {
4428  yyval.listval =
4429  TrackedListPtr<Node>::make(lexer.parsed_node_list_tokens_, 1, yyvsp[0].nodeval);
4430  ;
4431  break;
4432  }
4433  case 241:
4434 
4435  {
4436  yyval.listval = yyvsp[-2].listval;
4437  yyval.listval->push_back(yyvsp[0].nodeval);
4438  ;
4439  break;
4440  }
4441  case 242:
4442 
4443  {
4444  yyval.nodeval = yyvsp[0].nodeval;
4445  ;
4446  break;
4447  }
4448  case 243:
4449 
4450  {
4451  yyval.nodeval =
4452  TrackedPtr<Node>::make(lexer.parsed_node_tokens_, new UserLiteral());
4453  ;
4454  break;
4455  }
4456  case 244:
4457 
4458  {
4459  yyval.nodeval = TrackedPtr<Node>::make(
4460  lexer.parsed_node_tokens_, new FunctionRef((yyvsp[-3].stringval)->release()));
4461  ;
4462  break;
4463  }
4464  case 245:
4465 
4466  {
4467  yyval.nodeval = TrackedPtr<Node>::make(
4468  lexer.parsed_node_tokens_,
4469  new FunctionRef((yyvsp[-4].stringval)->release(),
4470  true,
4471  dynamic_cast<Expr*>((yyvsp[-1].nodeval)->release())));
4472  ;
4473  break;
4474  }
4475  case 246:
4476 
4477  {
4478  yyval.nodeval = TrackedPtr<Node>::make(
4479  lexer.parsed_node_tokens_,
4480  new FunctionRef((yyvsp[-4].stringval)->release(),
4481  dynamic_cast<Expr*>((yyvsp[-1].nodeval)->release())));
4482  ;
4483  break;
4484  }
4485  case 247:
4486 
4487  {
4488  yyval.nodeval = TrackedPtr<Node>::make(
4489  lexer.parsed_node_tokens_,
4490  new FunctionRef((yyvsp[-3].stringval)->release(),
4491  dynamic_cast<Expr*>((yyvsp[-1].nodeval)->release())));
4492  ;
4493  break;
4494  }
4495  case 248:
4496 
4497  {
4498  yyval.nodeval = TrackedPtr<Node>::make(
4499  lexer.parsed_node_tokens_, new StringLiteral((yyvsp[0].stringval)->release()));
4500  ;
4501  break;
4502  }
4503  case 249:
4504 
4505  {
4506  yyval.nodeval = TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
4507  new IntLiteral(yyvsp[0].intval));
4508  ;
4509  break;
4510  }
4511  case 250:
4512 
4513  {
4514  yyval.nodeval =
4515  TrackedPtr<Node>::make(lexer.parsed_node_tokens_, new TimestampLiteral());
4516  ;
4517  break;
4518  }
4519  case 251:
4520 
4521  {
4522  delete dynamic_cast<Expr*>((yyvsp[-1].nodeval)->release());
4523  yyval.nodeval =
4524  TrackedPtr<Node>::make(lexer.parsed_node_tokens_, new TimestampLiteral());
4525  ;
4526  break;
4527  }
4528  case 252:
4529 
4530  {
4531  yyval.nodeval = TrackedPtr<Node>::make(
4532  lexer.parsed_node_tokens_, new FixedPtLiteral((yyvsp[0].stringval)->release()));
4533  ;
4534  break;
4535  }
4536  case 253:
4537 
4538  {
4539  yyval.nodeval = TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
4540  new FloatLiteral(yyvsp[0].floatval));
4541  ;
4542  break;
4543  }
4544  case 254:
4545 
4546  {
4547  yyval.nodeval = TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
4548  new DoubleLiteral(yyvsp[0].doubleval));
4549  ;
4550  break;
4551  }
4552  case 255:
4553 
4554  {
4555  yyval.nodeval = TrackedPtr<Node>::make(
4556  lexer.parsed_node_tokens_,
4557  new CastExpr(new StringLiteral((yyvsp[0].stringval)->release()),
4558  dynamic_cast<SQLType*>((yyvsp[-1].nodeval)->release())));
4559  ;
4560  break;
4561  }
4562  case 256:
4563 
4564  {
4565  yyval.nodeval = TrackedPtr<Node>::make(
4566  lexer.parsed_node_tokens_,
4567  new ArrayLiteral(
4568  reinterpret_cast<std::list<Expr*>*>((yyvsp[-1].listval)->release())));
4569  ;
4570  break;
4571  }
4572  case 257:
4573 
4574  {
4575  yyval.nodeval = TrackedPtr<Node>::make(
4576  lexer.parsed_node_tokens_,
4577  new ArrayLiteral(
4578  reinterpret_cast<std::list<Expr*>*>((yyvsp[-1].listval)->release())));
4579  ;
4580  break;
4581  }
4582  case 258:
4583 
4584  {
4585  yyval.nodeval =
4586  TrackedPtr<Node>::make(lexer.parsed_node_tokens_, new NullLiteral());
4587  ;
4588  break;
4589  }
4590  case 259:
4591 
4592  {
4593  yyval.listval =
4594  TrackedListPtr<Node>::make(lexer.parsed_node_list_tokens_, 1, yyvsp[0].nodeval);
4595  ;
4596  break;
4597  }
4598  case 260:
4599 
4600  {
4601  yyval.listval = yyvsp[-2].listval;
4602  yyval.listval->push_back(yyvsp[0].nodeval);
4603  ;
4604  break;
4605  }
4606  case 261:
4607 
4608  {
4609  yyval.listval = TrackedListPtr<Node>::make(lexer.parsed_node_list_tokens_, 0);
4610  ;
4611  break;
4612  }
4613  case 263:
4614 
4615  {
4616  const auto uc_col_name =
4617  boost::to_upper_copy<std::string>(*(yyvsp[0].stringval)->get());
4618  if (reserved_keywords.find(uc_col_name) != reserved_keywords.end()) {
4619  errors_.push_back("Cannot use a reserved keyword as table name: " +
4620  *(yyvsp[0].stringval)->get());
4621  }
4622  yyval.stringval = yyvsp[0].stringval;
4623  ;
4624  break;
4625  }
4626  case 264:
4627 
4628  {
4629  yyval.stringval = yyvsp[0].stringval;
4630  ;
4631  break;
4632  }
4633  case 265:
4634 
4635  {
4636  yyval.nodeval = TrackedPtr<Node>::makeEmpty();
4637  ;
4638  break;
4639  }
4640  case 271:
4641 
4642  {
4643  yyval.slistval = TrackedListPtr<std::string>::make(
4644  lexer.parsed_str_list_tokens_, 1, yyvsp[0].stringval);
4645  ;
4646  break;
4647  }
4648  case 272:
4649 
4650  {
4651  yyval.slistval = yyvsp[-2].slistval;
4652  yyval.slistval->push_back(yyvsp[0].stringval);
4653  ;
4654  break;
4655  }
4656  case 275:
4657 
4658  {
4659  yyval.slistval = TrackedListPtr<std::string>::make(
4660  lexer.parsed_str_list_tokens_, 1, yyvsp[0].stringval);
4661  ;
4662  break;
4663  }
4664  case 276:
4665 
4666  {
4667  yyval.slistval = yyvsp[-2].slistval;
4668  yyval.slistval->push_back(yyvsp[0].stringval);
4669  ;
4670  break;
4671  }
4672  case 279:
4673 
4674  {
4675  yyval.slistval = TrackedListPtr<std::string>::make(
4676  lexer.parsed_str_list_tokens_, 1, yyvsp[0].stringval);
4677  ;
4678  break;
4679  }
4680  case 280:
4681 
4682  {
4683  yyval.slistval = yyvsp[-2].slistval;
4684  yyval.slistval->push_back(yyvsp[0].stringval);
4685  ;
4686  break;
4687  }
4688  case 281:
4689 
4690  {
4691  yyval.stringval = TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "ALL");
4692  ;
4693  break;
4694  }
4695  case 282:
4696 
4697  {
4698  yyval.stringval = TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "ALL");
4699  ;
4700  break;
4701  }
4702  case 283:
4703 
4704  {
4705  yyval.stringval = TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "CREATE");
4706  ;
4707  break;
4708  }
4709  case 284:
4710 
4711  {
4712  yyval.stringval = TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "SELECT");
4713  ;
4714  break;
4715  }
4716  case 285:
4717 
4718  {
4719  yyval.stringval = TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "INSERT");
4720  ;
4721  break;
4722  }
4723  case 286:
4724 
4725  {
4726  yyval.stringval =
4727  TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "TRUNCATE");
4728  ;
4729  break;
4730  }
4731  case 287:
4732 
4733  {
4734  yyval.stringval = TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "UPDATE");
4735  ;
4736  break;
4737  }
4738  case 288:
4739 
4740  {
4741  yyval.stringval = TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "DELETE");
4742  ;
4743  break;
4744  }
4745  case 289:
4746 
4747  {
4748  yyval.stringval = TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "ALTER");
4749  ;
4750  break;
4751  }
4752  case 290:
4753 
4754  {
4755  yyval.stringval = TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "DROP");
4756  ;
4757  break;
4758  }
4759  case 291:
4760 
4761  {
4762  yyval.stringval = TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "VIEW");
4763  ;
4764  break;
4765  }
4766  case 292:
4767 
4768  {
4769  yyval.stringval = TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "EDIT");
4770  ;
4771  break;
4772  }
4773  case 293:
4774 
4775  {
4776  yyval.stringval = TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "ACCESS");
4777  ;
4778  break;
4779  }
4780  case 294:
4781 
4782  {
4783  yyval.stringval =
4784  TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "ALTER SERVER");
4785  ;
4786  break;
4787  }
4788  case 295:
4789 
4790  {
4791  yyval.stringval =
4792  TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "CREATE SERVER");
4793  ;
4794  break;
4795  }
4796  case 296:
4797 
4798  {
4799  yyval.stringval =
4800  TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "CREATE TABLE");
4801  ;
4802  break;
4803  }
4804  case 297:
4805 
4806  {
4807  yyval.stringval =
4808  TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "CREATE VIEW");
4809  ;
4810  break;
4811  }
4812  case 298:
4813 
4814  {
4815  yyval.stringval =
4816  TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "SELECT VIEW");
4817  ;
4818  break;
4819  }
4820  case 299:
4821 
4822  {
4823  yyval.stringval =
4824  TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "DROP VIEW");
4825  ;
4826  break;
4827  }
4828  case 300:
4829 
4830  {
4831  yyval.stringval =
4832  TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "DROP SERVER");
4833  ;
4834  break;
4835  }
4836  case 301:
4837 
4838  {
4839  yyval.stringval =
4840  TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "CREATE DASHBOARD");
4841  ;
4842  break;
4843  }
4844  case 302:
4845 
4846  {
4847  yyval.stringval =
4848  TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "EDIT DASHBOARD");
4849  ;
4850  break;
4851  }
4852  case 303:
4853 
4854  {
4855  yyval.stringval =
4856  TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "VIEW DASHBOARD");
4857  ;
4858  break;
4859  }
4860  case 304:
4861 
4862  {
4863  yyval.stringval =
4864  TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "DELETE DASHBOARD");
4865  ;
4866  break;
4867  }
4868  case 305:
4869 
4870  {
4871  yyval.stringval =
4872  TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "VIEW SQL EDITOR");
4873  ;
4874  break;
4875  }
4876  case 306:
4877 
4878  {
4879  yyval.stringval =
4880  TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "DATABASE");
4881  ;
4882  break;
4883  }
4884  case 307:
4885 
4886  {
4887  yyval.stringval = TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "TABLE");
4888  ;
4889  break;
4890  }
4891  case 308:
4892 
4893  {
4894  yyval.stringval =
4895  TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "DASHBOARD");
4896  ;
4897  break;
4898  }
4899  case 309:
4900 
4901  {
4902  yyval.stringval = TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "VIEW");
4903  ;
4904  break;
4905  }
4906  case 310:
4907 
4908  {
4909  yyval.stringval = TrackedPtr<std::string>::make(lexer.parsed_str_tokens_, "SERVER");
4910  ;
4911  break;
4912  }
4913  case 312:
4914 
4915  {
4916  yyval.stringval = TrackedPtr<std::string>::make(lexer.parsed_str_tokens_,
4917  std::to_string(yyvsp[0].intval));
4918  ;
4919  break;
4920  }
4921  case 313:
4922 
4923  {
4924  yyval.nodeval = TrackedPtr<Node>::make(
4925  lexer.parsed_node_tokens_, new ColumnRef((yyvsp[0].stringval)->release()));
4926  ;
4927  break;
4928  }
4929  case 314:
4930 
4931  {
4932  yyval.nodeval =
4933  TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
4934  new ColumnRef((yyvsp[-2].stringval)->release(),
4935  (yyvsp[0].stringval)->release()));
4936  ;
4937  break;
4938  }
4939  case 315:
4940 
4941  {
4942  yyval.nodeval = TrackedPtr<Node>::make(
4943  lexer.parsed_node_tokens_,
4944  new ColumnRef((yyvsp[-2].stringval)->release(), nullptr));
4945  ;
4946  break;
4947  }
4948  case 316:
4949 
4950  {
4951  if (yyvsp[0].intval < 0)
4952  throw std::runtime_error("No negative number in type definition.");
4953  yyval.intval = yyvsp[0].intval;
4954  ;
4955  break;
4956  }
4957  case 317:
4958 
4959  {
4960  yyval.nodeval =
4961  TrackedPtr<Node>::make(lexer.parsed_node_tokens_, new SQLType(kBIGINT));
4962  ;
4963  break;
4964  }
4965  case 318:
4966 
4967  {
4968  yyval.nodeval =
4969  TrackedPtr<Node>::make(lexer.parsed_node_tokens_, new SQLType(kTEXT));
4970  ;
4971  break;
4972  }
4973  case 319:
4974 
4975  {
4976  yyval.nodeval =
4977  TrackedPtr<Node>::make(lexer.parsed_node_tokens_, new SQLType(kBOOLEAN));
4978  ;
4979  break;
4980  }
4981  case 320:
4982 
4983  {
4984  yyval.nodeval =
4985  TrackedPtr<Node>::make(lexer.parsed_node_tokens_, new SQLType(kCHAR));
4986  ;
4987  break;
4988  }
4989  case 321:
4990 
4991  {
4992  yyval.nodeval = TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
4993  new SQLType(kCHAR, yyvsp[-1].intval));
4994  ;
4995  break;
4996  }
4997  case 322:
4998 
4999  {
5000  yyval.nodeval =
5001  TrackedPtr<Node>::make(lexer.parsed_node_tokens_, new SQLType(kNUMERIC));
5002  ;
5003  break;
5004  }
5005  case 323:
5006 
5007  {
5008  yyval.nodeval = TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
5009  new SQLType(kNUMERIC, yyvsp[-1].intval));
5010  ;
5011  break;
5012  }
5013  case 324:
5014 
5015  {
5016  yyval.nodeval = TrackedPtr<Node>::make(
5017  lexer.parsed_node_tokens_,
5018  new SQLType(kNUMERIC, yyvsp[-3].intval, yyvsp[-1].intval, false));
5019  ;
5020  break;
5021  }
5022  case 325:
5023 
5024  {
5025  yyval.nodeval =
5026  TrackedPtr<Node>::make(lexer.parsed_node_tokens_, new SQLType(kDECIMAL));
5027  ;
5028  break;
5029  }
5030  case 326:
5031 
5032  {
5033  yyval.nodeval = TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
5034  new SQLType(kDECIMAL, yyvsp[-1].intval));
5035  ;
5036  break;
5037  }
5038  case 327:
5039 
5040  {
5041  yyval.nodeval = TrackedPtr<Node>::make(
5042  lexer.parsed_node_tokens_,
5043  new SQLType(kDECIMAL, yyvsp[-3].intval, yyvsp[-1].intval, false));
5044  ;
5045  break;
5046  }
5047  case 328:
5048 
5049  {
5050  yyval.nodeval =
5051  TrackedPtr<Node>::make(lexer.parsed_node_tokens_, new SQLType(kINT));
5052  ;
5053  break;
5054  }
5055  case 329:
5056 
5057  {
5058  yyval.nodeval =
5059  TrackedPtr<Node>::make(lexer.parsed_node_tokens_, new SQLType(kTINYINT));
5060  ;
5061  break;
5062  }
5063  case 330:
5064 
5065  {
5066  yyval.nodeval =
5067  TrackedPtr<Node>::make(lexer.parsed_node_tokens_, new SQLType(kSMALLINT));
5068  ;
5069  break;
5070  }
5071  case 331:
5072 
5073  {
5074  yyval.nodeval =
5075  TrackedPtr<Node>::make(lexer.parsed_node_tokens_, new SQLType(kFLOAT));
5076  ;
5077  break;
5078  }
5079  case 332:
5080 
5081  {
5082  yyval.nodeval =
5083  TrackedPtr<Node>::make(lexer.parsed_node_tokens_, new SQLType(kFLOAT));
5084  ;
5085  break;
5086  }
5087  case 333:
5088 
5089  {
5090  yyval.nodeval =
5091  TrackedPtr<Node>::make(lexer.parsed_node_tokens_, new SQLType(kDOUBLE));
5092  ;
5093  break;
5094  }
5095  case 334:
5096 
5097  {
5098  yyval.nodeval =
5099  TrackedPtr<Node>::make(lexer.parsed_node_tokens_, new SQLType(kDOUBLE));
5100  ;
5101  break;
5102  }
5103  case 335:
5104 
5105  {
5106  yyval.nodeval =
5107  TrackedPtr<Node>::make(lexer.parsed_node_tokens_, new SQLType(kDATE));
5108  ;
5109  break;
5110  }
5111  case 336:
5112 
5113  {
5114  yyval.nodeval =
5115  TrackedPtr<Node>::make(lexer.parsed_node_tokens_, new SQLType(kTIME));
5116  ;
5117  break;
5118  }
5119  case 337:
5120 
5121  {
5122  yyval.nodeval = TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
5123  new SQLType(kTIME, yyvsp[-1].intval));
5124  ;
5125  break;
5126  }
5127  case 338:
5128 
5129  {
5130  yyval.nodeval =
5131  TrackedPtr<Node>::make(lexer.parsed_node_tokens_, new SQLType(kTIMESTAMP));
5132  ;
5133  break;
5134  }
5135  case 339:
5136 
5137  {
5138  yyval.nodeval = TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
5139  new SQLType(kTIMESTAMP, yyvsp[-1].intval));
5140  ;
5141  break;
5142  }
5143  case 340:
5144 
5145  {
5146  yyval.nodeval =
5147  TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
5148  new SQLType(static_cast<SQLTypes>(yyvsp[0].intval),
5149  static_cast<int>(kGEOMETRY),
5150  0,
5151  false));
5152  ;
5153  break;
5154  }
5155  case 341:
5156 
5157  {
5158  yyval.nodeval = yyvsp[0].nodeval;
5159  ;
5160  break;
5161  }
5162  case 342:
5163 
5164  {
5165  yyval.nodeval = yyvsp[-2].nodeval;
5166  if (dynamic_cast<SQLType*>((yyval.nodeval)->get())->get_is_array())
5167  throw std::runtime_error("array of array not supported.");
5168  dynamic_cast<SQLType*>((yyval.nodeval)->get())->set_is_array(true);
5169  ;
5170  break;
5171  }
5172  case 343:
5173 
5174  {
5175  yyval.nodeval = yyvsp[-3].nodeval;
5176  if (dynamic_cast<SQLType*>((yyval.nodeval)->get())->get_is_array())
5177  throw std::runtime_error("array of array not supported.");
5178  dynamic_cast<SQLType*>((yyval.nodeval)->get())->set_is_array(true);
5179  dynamic_cast<SQLType*>((yyval.nodeval)->get())->set_array_size(yyvsp[-1].intval);
5180  ;
5181  break;
5182  }
5183  case 344:
5184 
5185  {
5186  yyval.intval = kPOINT;
5187  ;
5188  break;
5189  }
5190  case 345:
5191 
5192  {
5193  yyval.intval = kLINESTRING;
5194  ;
5195  break;
5196  }
5197  case 346:
5198 
5199  {
5200  yyval.intval = kPOLYGON;
5201  ;
5202  break;
5203  }
5204  case 347:
5205 
5206  {
5207  yyval.intval = kMULTIPOLYGON;
5208  ;
5209  break;
5210  }
5211  case 348:
5212 
5213  {
5214  yyval.nodeval =
5215  TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
5216  new SQLType(static_cast<SQLTypes>(yyvsp[-1].intval),
5217  static_cast<int>(kGEOGRAPHY),
5218  4326,
5219  false));
5220  ;
5221  break;
5222  }
5223  case 349:
5224 
5225  {
5226  yyval.nodeval =
5227  TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
5228  new SQLType(static_cast<SQLTypes>(yyvsp[-3].intval),
5229  static_cast<int>(kGEOGRAPHY),
5230  yyvsp[-1].intval,
5231  false));
5232  ;
5233  break;
5234  }
5235  case 350:
5236 
5237  {
5238  yyval.nodeval =
5239  TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
5240  new SQLType(static_cast<SQLTypes>(yyvsp[-1].intval),
5241  static_cast<int>(kGEOMETRY),
5242  0,
5243  false));
5244  ;
5245  break;
5246  }
5247  case 351:
5248 
5249  {
5250  yyval.nodeval =
5251  TrackedPtr<Node>::make(lexer.parsed_node_tokens_,
5252  new SQLType(static_cast<SQLTypes>(yyvsp[-3].intval),
5253  static_cast<int>(kGEOMETRY),
5254  yyvsp[-1].intval,
5255  false));
5256  ;
5257  break;
5258  }
5259  case 352:
5260 
5261  {
5262  const auto uc_col_name =
5263  boost::to_upper_copy<std::string>(*(yyvsp[0].stringval)->get());
5264  if (reserved_keywords.find(uc_col_name) != reserved_keywords.end()) {
5265  errors_.push_back("Cannot use a reserved keyword as column name: " +
5266  *(yyvsp[0].stringval)->get());
5267  }
5268  yyval.stringval = yyvsp[0].stringval;
5269  ;
5270  break;
5271  }
5272  case 353:
5273 
5274  {
5275  yyval.stringval = yyvsp[0].stringval;
5276  ;
5277  break;
5278  }
5279  case 354:
5280 
5281  {
5282  yyval.stringval = yyvsp[0].stringval;
5283  ;
5284  break;
5285  }
5286  }
5287 
5288  /* the action file gets copied in in place of this dollarsign */
5289  yyvsp -= yylen;
5290  yyssp -= yylen;
5291 #ifdef YY_Parser_LSP_NEEDED
5292  yylsp -= yylen;
5293 #endif
5294 
5295 #if YY_Parser_DEBUG != 0
5296  if (YY_Parser_DEBUG_FLAG) {
5297  short* ssp1 = yyss - 1;
5298  fprintf(stderr, "state stack now");
5299  while (ssp1 != yyssp)
5300  fprintf(stderr, " %d", *++ssp1);
5301  fprintf(stderr, "\n");
5302  }
5303 #endif
5304 
5305  *++yyvsp = yyval;
5306 
5307 #ifdef YY_Parser_LSP_NEEDED
5308  yylsp++;
5309  if (yylen == 0) {
5310  yylsp->first_line = YY_Parser_LLOC.first_line;
5311  yylsp->first_column = YY_Parser_LLOC.first_column;
5312  yylsp->last_line = (yylsp - 1)->last_line;
5313  yylsp->last_column = (yylsp - 1)->last_column;
5314  yylsp->text = 0;
5315  } else {
5316  yylsp->last_line = (yylsp + yylen - 1)->last_line;
5317  yylsp->last_column = (yylsp + yylen - 1)->last_column;
5318  }
5319 #endif
5320 
5321  /* Now "shift" the result of the reduction.
5322  Determine what state that goes to,
5323  based on the state we popped back to
5324  and the rule number reduced by. */
5325 
5326  yyn = yyr1[yyn];
5327 
5328  yystate = yypgoto[yyn - YYNTBASE] + *yyssp;
5329  if (yystate >= 0 && yystate <= YYLAST && yycheck[yystate] == *yyssp)
5330  yystate = yytable[yystate];
5331  else
5332  yystate = yydefgoto[yyn - YYNTBASE];
5333 
5334  YYGOTO(yynewstate);
5335 
5336  YYLABEL(yyerrlab) /* here on detecting error */
5337 
5338  if (!yyerrstatus)
5339  /* If not already recovering from an error, report this error. */
5340  {
5341  ++YY_Parser_NERRS;
5342 
5343 #ifdef YY_Parser_ERROR_VERBOSE
5344  yyn = yypact[yystate];
5345 
5346  if (yyn > YYFLAG && yyn < YYLAST) {
5347  int size = 0;
5348  char* msg;
5349  int x, count;
5350 
5351  count = 0;
5352  /* Start X at -yyn if nec to avoid negative indexes in yycheck. */
5353  for (x = (yyn < 0 ? -yyn : 0); x < (sizeof(yytname) / sizeof(char*)); x++)
5354  if (yycheck[x + yyn] == x)
5355  size += strlen(yytname[x]) + 15, count++;
5356  msg = (char*)malloc(size + 15);
5357  if (msg != 0) {
5358  strcpy(msg, "parse error");
5359 
5360  if (count < 5) {
5361  count = 0;
5362  for (x = (yyn < 0 ? -yyn : 0); x < (sizeof(yytname) / sizeof(char*)); x++)
5363  if (yycheck[x + yyn] == x) {
5364  strcat(msg, count == 0 ? ", expecting `" : " or `");
5365  strcat(msg, yytname[x]);
5366  strcat(msg, "'");
5367  count++;
5368  }
5369  }
5370  YY_Parser_ERROR(msg);
5371  free(msg);
5372  } else
5373  YY_Parser_ERROR("parse error; also virtual memory exceeded");
5374  } else
5375 #endif /* YY_Parser_ERROR_VERBOSE */
5376  YY_Parser_ERROR("parse error");
5377  }
5378 
5379  YYGOTO(yyerrlab1);
5380  YYLABEL(yyerrlab1) /* here on error raised explicitly by an action */
5381 
5382  if (yyerrstatus == 3) {
5383  /* if just tried and failed to reuse lookahead token after an error, discard it. */
5384 
5385  /* return failure if at end of input */
5386  if (YY_Parser_CHAR == YYEOF)
5387  YYABORT;
5388 
5389 #if YY_Parser_DEBUG != 0
5391  fprintf(stderr, "Discarding token %d (%s).\n", YY_Parser_CHAR, yytname[yychar1]);
5392 #endif
5393 
5394  YY_Parser_CHAR = YYEMPTY;
5395  }
5396 
5397  /* Else will try to reuse lookahead token
5398  after shifting the error token. */
5399 
5400  yyerrstatus = 3; /* Each real token shifted decrements this */
5401 
5402  YYGOTO(yyerrhandle);
5403 
5404  YYLABEL(
5405  yyerrdefault) /* current state does not do anything special for the error token. */
5406 
5407 #if 0
5408  /* This is wrong; only states that explicitly want error tokens
5409  should shift them. */
5410  yyn = yydefact[yystate]; /* If its default is to accept any token, ok. Otherwise pop it.*/
5411  if (yyn) YYGOTO(yydefault);
5412 #endif
5413 
5414  YYLABEL(yyerrpop) /* pop the current state because it cannot handle the error token */
5415 
5416  if (yyssp == yyss)
5417  YYABORT;
5418  yyvsp--;
5419  yystate = *--yyssp;
5420 #ifdef YY_Parser_LSP_NEEDED
5421  yylsp--;
5422 #endif
5423 
5424 #if YY_Parser_DEBUG != 0
5425  if (YY_Parser_DEBUG_FLAG) {
5426  short* ssp1 = yyss - 1;
5427  fprintf(stderr, "Error: state stack now");
5428  while (ssp1 != yyssp)
5429  fprintf(stderr, " %d", *++ssp1);
5430  fprintf(stderr, "\n");
5431  }
5432 #endif
5433 
5434  YYLABEL(yyerrhandle)
5435 
5436  yyn = yypact[yystate];
5437  if (yyn == YYFLAG)
5438  YYGOTO(yyerrdefault);
5439 
5440  yyn += YYTERROR;
5441  if (yyn < 0 || yyn > YYLAST || yycheck[yyn] != YYTERROR)
5442  YYGOTO(yyerrdefault);
5443 
5444  yyn = yytable[yyn];
5445  if (yyn < 0) {
5446  if (yyn == YYFLAG)
5447  YYGOTO(yyerrpop);
5448  yyn = -yyn;
5449  YYGOTO(yyreduce);
5450  } else if (yyn == 0)
5451  YYGOTO(yyerrpop);
5452 
5453  if (yyn == YYFINAL)
5454  YYACCEPT;
5455 
5456 #if YY_Parser_DEBUG != 0
5458  fprintf(stderr, "Shifting error token, ");
5459 #endif
5460 
5461  *++yyvsp = YY_Parser_LVAL;
5462 #ifdef YY_Parser_LSP_NEEDED
5463  *++yylsp = YY_Parser_LLOC;
5464 #endif
5465 
5466  yystate = yyn;
5467  YYGOTO(yynewstate);
5468  /* end loop, in which YYGOTO may be used. */
5469  YYENDGOTO
5470 }
5471 
5472 /* END */
#define YY_Parser_STYPE
#define YY_Parser_LEX
#define COMMIT
static std::set< std::string > reserved_keywords
#define BETWEEN
#define DELETE
#define FOREIGN
#define PRECISION
#define PRIMARY
#define VALUES
#define YYENDGOTO
#define NOT
#define LINESTRING
#define YYACCEPT
#define INSERT
int yystacksize
#define QUOTED_IDENTIFIER
int yychar1
#define REVOKE
#define YY_Parser_MEMBERS
#define THEN
#define REFERENCES
YY_Parser_STYPE * yyvsp
#define YY_Parser_CONSTRUCTOR_INIT
#define BY
#define NOW
Definition: sqltypes.h:48
#define EMAIL
YY_Parser_STYPE yyvsa[YYINITDEPTH]
#define TEMPORARY
#define REAL
#define GEOMETRY
#define parsed_str_tokens_
#define ELSE
short * yyssp
#define DUMP
SQLQualifier
Definition: sqldefs.h:69
#define HAVING
#define CURSOR
#define DATABASE
#define SMALLINT
SQLOps
Definition: sqldefs.h:29
#define OPTIMIZE
#define EXISTS
#define END
#define ALTER
#define DROP
#define OPTION
#define DOUBLE
#define yylval
#define FOUND
#define CONTINUE
#define YY_Parser_PARSE_PARAM
#define BIGINT
YY_Parser_STYPE * yyvs
Definition: sqldefs.h:38
#define TO
#define YY_Parser_LVAL
#define VALIDATE
#define TRUNCATE
#define YYDECLARELABEL(lb)
#define DICTIONARY
#define DASHBOARD
#define CURRENT
Definition: sqldefs.h:41
int YY_Parser_PARSE_PARAM_DEF
#define YYTERROR
#define OPEN
#define IN
#define DATE
#define EDIT
#define PARAMETER
#define OFFSET
#define INTNUM
#define WHENEVER
#define VIEW
short * yyss
int yylen
#define GRANT
#define SHARED
#define ROLLBACK
#define YY_Parser_ERROR_BODY
#define FWDSTR
std::string to_string(char const *&&v)
#define CHARACTER
#define PUBLIC
#define MOD
#define NULLX
#define AMMSC
#define YYABORT
#define RESTORE
#define TEXT
#define ROLE
#define SELECTSTRING
#define DASHEDNAME
#define YYFINAL
#define EDITOR
#define ADD
#define FOR
#define MULTIPOLYGON
#define POINT
#define IF
#define YY_Parser_LLOC
static const short yypact[]
#define SHOW
static TrackedPtr< T > * make(std::vector< std::unique_ptr< TrackedPtr< T >>> &tracked_ptrs, Args &&...args)
Definition: TrackedPtr.h:70
#define FIRST
#define UNION
static TrackedListPtr< T > * make(std::vector< std::unique_ptr< TrackedListPtr< T >>> &tracked_ptrs, Args &&...args)
Definition: TrackedPtr.h:170
Classes representing a parse tree.
Definition: ParserNode.h:1713
#define ASC
#define GROUP
#define YY_Parser_CHAR
int count
#define LIMIT
YY_Parser_STYPE yyval
#define SHARD
static const short yypgoto[]
static void __yy_bcopy(from, to, count) char *from
#define YYNTBASE
#define NAME
#define YYEMPTY
#define WITH
#define TIME
#define FROM
Definition: sqldefs.h:37
#define CLUSTER
#define SQL
#define YYLABEL(lb)
#define TINYINT
static const short yyr2[]
static const short yytable[]
#define AUTHORIZATION
#define __ALLOCA_return(num)
short yyssa[YYINITDEPTH]
#define CREATE
#define YYBEGINDECLARELABEL
#define COMPARISON
#define RENAME
#define ON
#define YY_Parser_DEBUG_FLAG
static TrackedListPtr< T > * makeEmpty()
Definition: TrackedPtr.h:183
char * to
#define YYFLAG
#define DATAFRAME
#define ANY
#define DESC
#define COLUMN
#define LAST
TrackedPtr< Node > * nodeval
#define YY_Parser_ERROR
#define CASE
static TrackedPtr< T > * makeEmpty()
Definition: TrackedPtr.h:81
#define YYMAXDEPTH
#define WHERE
Definition: sqltypes.h:51
Definition: sqltypes.h:52
Definition: sqldefs.h:40
#define ARRAY
#define WHEN
Definition: sqldefs.h:69
#define YYBEGINGOTO
#define IS
#define SOME
#define SCHEMA
#define CHAR_LENGTH
#define PRIVILEGES
int yyerrstatus
#define YY_Parser_LEX_BODY
#define SERVER
TrackedPtr< std::string > * stringval
static const short yytranslate[]
#define CLOSE
#define LENGTH
#define YY_Parser_CLASS
#define YYLAST
#define SET
#define CHECK
#define __ALLOCA_alloca(size)
#define TIMESTAMP
#define ORDER
Definition: sqltypes.h:40
static const short yydefgoto[]
#define DISTINCT
#define FETCH
static const short yyr1[]
#define YYTRANSLATE(x)
#define YYGOTO(lb)
#define EQUAL
#define LIKE
#define WORK
#define PROCEDURE
#define UPDATE
#define USER
#define STRING
#define OR
#define EXTRACT
#define NUMERIC
char * t
#define ARCHIVE
#define ILIKE
#define YYLEX
#define DECIMAL
#define DATE_TRUNC
#define FIXEDNUM
#define DEFAULT
#define UNIQUE
char * f
#define GEOGRAPHY
#define YYINITDEPTH
#define DATETIME
#define POLYGON
#define CAST
Definition: sqltypes.h:44
#define COPY
static const short yycheck[]
static const short yydefact[]
#define YY_Parser_PARSE
#define AND
#define TABLE
#define FLOAT
#define OF
#define DECLARE
#define OPTIMIZED
Definition: sqldefs.h:39
YYBEGINGOTO yystate
if(yyssp >=yyss+yystacksize-1)
#define UMINUS
#define __ALLOCA_free(ptr, ref)
#define INTO
#define ALL
#define AS
#define LANGUAGE
#define SELECT
#define YYENDDECLARELABEL
TrackedListPtr< std::string > * slistval
#define YYEOF
#define BOOLEAN
#define YY_Parser_NERRS
TrackedListPtr< Node > * listval
#define INTEGER
#define ACCESS