# Generated from SqlBase.g4 by ANTLR 4.7.1
# encoding: utf-8
from __future__ import print_function
from antlr4 import *
from io import StringIO
import sys

def serializedATN():
    with StringIO() as buf:
        buf.write(u"\3\u608b\ua72a\u8133\ub9ed\u417c\u3be7\u7786\u5964\3")
        buf.write(u"\u00de\u05e1\4\2\t\2\4\3\t\3\4\4\t\4\4\5\t\5\4\6\t\6")
        buf.write(u"\4\7\t\7\4\b\t\b\4\t\t\t\4\n\t\n\4\13\t\13\4\f\t\f\4")
        buf.write(u"\r\t\r\4\16\t\16\4\17\t\17\4\20\t\20\4\21\t\21\4\22\t")
        buf.write(u"\22\4\23\t\23\4\24\t\24\4\25\t\25\4\26\t\26\4\27\t\27")
        buf.write(u"\4\30\t\30\4\31\t\31\4\32\t\32\4\33\t\33\4\34\t\34\4")
        buf.write(u"\35\t\35\4\36\t\36\4\37\t\37\4 \t \4!\t!\4\"\t\"\4#\t")
        buf.write(u"#\4$\t$\4%\t%\4&\t&\4\'\t\'\4(\t(\4)\t)\4*\t*\4+\t+\4")
        buf.write(u",\t,\4-\t-\4.\t.\4/\t/\4\60\t\60\4\61\t\61\4\62\t\62")
        buf.write(u"\4\63\t\63\4\64\t\64\4\65\t\65\4\66\t\66\4\67\t\67\4")
        buf.write(u"8\t8\49\t9\4:\t:\4;\t;\4<\t<\4=\t=\4>\t>\3\2\3\2\3\2")
        buf.write(u"\3\3\3\3\3\3\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4")
        buf.write(u"\3\4\3\4\3\4\5\4\u0090\n\4\3\4\3\4\3\4\5\4\u0095\n\4")
        buf.write(u"\3\4\3\4\3\4\3\4\5\4\u009b\n\4\3\4\3\4\5\4\u009f\n\4")
        buf.write(u"\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\5\4")
        buf.write(u"\u00ad\n\4\3\4\3\4\5\4\u00b1\n\4\3\4\3\4\5\4\u00b5\n")
        buf.write(u"\4\3\4\3\4\5\4\u00b9\n\4\3\4\3\4\3\4\3\4\3\4\3\4\5\4")
        buf.write(u"\u00c1\n\4\3\4\3\4\5\4\u00c5\n\4\3\4\5\4\u00c8\n\4\3")
        buf.write(u"\4\3\4\3\4\3\4\3\4\5\4\u00cf\n\4\3\4\3\4\3\4\3\4\3\4")
        buf.write(u"\7\4\u00d6\n\4\f\4\16\4\u00d9\13\4\3\4\3\4\3\4\5\4\u00de")
        buf.write(u"\n\4\3\4\3\4\5\4\u00e2\n\4\3\4\3\4\3\4\3\4\5\4\u00e8")
        buf.write(u"\n\4\3\4\3\4\3\4\3\4\3\4\5\4\u00ef\n\4\3\4\3\4\3\4\3")
        buf.write(u"\4\3\4\3\4\3\4\5\4\u00f8\n\4\3\4\3\4\3\4\3\4\3\4\3\4")
        buf.write(u"\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4")
        buf.write(u"\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4")
        buf.write(u"\3\4\5\4\u011b\n\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3")
        buf.write(u"\4\5\4\u0126\n\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\7\4\u012f")
        buf.write(u"\n\4\f\4\16\4\u0132\13\4\5\4\u0134\n\4\3\4\3\4\3\4\3")
        buf.write(u"\4\3\4\3\4\7\4\u013c\n\4\f\4\16\4\u013f\13\4\3\4\3\4")
        buf.write(u"\5\4\u0143\n\4\3\4\3\4\5\4\u0147\n\4\3\4\3\4\3\4\3\4")
        buf.write(u"\3\4\3\4\5\4\u014f\n\4\3\4\3\4\3\4\3\4\5\4\u0155\n\4")
        buf.write(u"\3\4\3\4\3\4\7\4\u015a\n\4\f\4\16\4\u015d\13\4\3\4\3")
        buf.write(u"\4\5\4\u0161\n\4\3\4\3\4\5\4\u0165\n\4\3\4\3\4\3\4\3")
        buf.write(u"\4\3\4\3\4\3\4\3\4\5\4\u016f\n\4\3\4\5\4\u0172\n\4\3")
        buf.write(u"\4\3\4\5\4\u0176\n\4\3\4\5\4\u0179\n\4\3\4\3\4\3\4\3")
        buf.write(u"\4\7\4\u017f\n\4\f\4\16\4\u0182\13\4\3\4\3\4\5\4\u0186")
        buf.write(u"\n\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4")
        buf.write(u"\3\4\5\4\u0195\n\4\3\4\3\4\3\4\3\4\5\4\u019b\n\4\5\4")
        buf.write(u"\u019d\n\4\3\4\3\4\3\4\3\4\5\4\u01a3\n\4\3\4\3\4\3\4")
        buf.write(u"\3\4\5\4\u01a9\n\4\5\4\u01ab\n\4\3\4\3\4\3\4\3\4\5\4")
        buf.write(u"\u01b1\n\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3")
        buf.write(u"\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3")
        buf.write(u"\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3")
        buf.write(u"\4\7\4\u01d8\n\4\f\4\16\4\u01db\13\4\5\4\u01dd\n\4\3")
        buf.write(u"\4\3\4\5\4\u01e1\n\4\3\4\3\4\5\4\u01e5\n\4\3\4\3\4\3")
        buf.write(u"\4\3\4\3\4\3\4\5\4\u01ed\n\4\3\4\3\4\3\4\3\4\3\4\7\4")
        buf.write(u"\u01f4\n\4\f\4\16\4\u01f7\13\4\5\4\u01f9\n\4\3\4\3\4")
        buf.write(u"\5\4\u01fd\n\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3\4\3")
        buf.write(u"\4\3\4\3\4\3\4\3\4\7\4\u020d\n\4\f\4\16\4\u0210\13\4")
        buf.write(u"\5\4\u0212\n\4\3\4\3\4\3\4\3\4\3\4\3\4\5\4\u021a\n\4")
        buf.write(u"\3\5\5\5\u021d\n\5\3\5\3\5\3\6\3\6\5\6\u0223\n\6\3\6")
        buf.write(u"\3\6\3\6\7\6\u0228\n\6\f\6\16\6\u022b\13\6\3\7\3\7\5")
        buf.write(u"\7\u022f\n\7\3\b\3\b\3\b\3\b\5\b\u0235\n\b\3\t\3\t\3")
        buf.write(u"\t\3\t\5\t\u023b\n\t\3\n\3\n\3\n\3\n\7\n\u0241\n\n\f")
        buf.write(u"\n\16\n\u0244\13\n\3\n\3\n\3\13\3\13\3\13\3\13\3\f\3")
        buf.write(u"\f\3\f\3\f\3\f\3\f\7\f\u0252\n\f\f\f\16\f\u0255\13\f")
        buf.write(u"\5\f\u0257\n\f\3\f\3\f\5\f\u025b\n\f\3\r\3\r\3\r\3\r")
        buf.write(u"\3\r\3\r\5\r\u0263\n\r\3\r\3\r\3\r\3\r\5\r\u0269\n\r")
        buf.write(u"\3\r\7\r\u026c\n\r\f\r\16\r\u026f\13\r\3\16\3\16\3\16")
        buf.write(u"\3\16\3\16\3\16\3\16\7\16\u0278\n\16\f\16\16\16\u027b")
        buf.write(u"\13\16\3\16\3\16\3\16\3\16\5\16\u0281\n\16\3\17\3\17")
        buf.write(u"\5\17\u0285\n\17\3\17\3\17\5\17\u0289\n\17\3\20\3\20")
        buf.write(u"\5\20\u028d\n\20\3\20\3\20\3\20\7\20\u0292\n\20\f\20")
        buf.write(u"\16\20\u0295\13\20\3\20\3\20\3\20\3\20\7\20\u029b\n\20")
        buf.write(u"\f\20\16\20\u029e\13\20\5\20\u02a0\n\20\3\20\3\20\5\20")
        buf.write(u"\u02a4\n\20\3\20\3\20\3\20\5\20\u02a9\n\20\3\20\3\20")
        buf.write(u"\5\20\u02ad\n\20\3\21\5\21\u02b0\n\21\3\21\3\21\3\21")
        buf.write(u"\7\21\u02b5\n\21\f\21\16\21\u02b8\13\21\3\22\3\22\3\22")
        buf.write(u"\3\22\3\22\3\22\7\22\u02c0\n\22\f\22\16\22\u02c3\13\22")
        buf.write(u"\5\22\u02c5\n\22\3\22\3\22\3\22\3\22\3\22\3\22\7\22\u02cd")
        buf.write(u"\n\22\f\22\16\22\u02d0\13\22\5\22\u02d2\n\22\3\22\3\22")
        buf.write(u"\3\22\3\22\3\22\3\22\3\22\7\22\u02db\n\22\f\22\16\22")
        buf.write(u"\u02de\13\22\3\22\3\22\5\22\u02e2\n\22\3\23\3\23\3\23")
        buf.write(u"\3\23\7\23\u02e8\n\23\f\23\16\23\u02eb\13\23\5\23\u02ed")
        buf.write(u"\n\23\3\23\3\23\5\23\u02f1\n\23\3\24\3\24\3\24\3\24\7")
        buf.write(u"\24\u02f7\n\24\f\24\16\24\u02fa\13\24\5\24\u02fc\n\24")
        buf.write(u"\3\24\3\24\5\24\u0300\n\24\3\25\3\25\5\25\u0304\n\25")
        buf.write(u"\3\25\3\25\3\25\3\25\3\25\3\26\3\26\3\27\3\27\5\27\u030f")
        buf.write(u"\n\27\3\27\5\27\u0312\n\27\3\27\3\27\3\27\3\27\3\27\5")
        buf.write(u"\27\u0319\n\27\3\30\3\30\3\30\3\30\3\30\3\30\3\30\3\30")
        buf.write(u"\3\30\3\30\3\30\3\30\3\30\3\30\3\30\3\30\3\30\5\30\u032c")
        buf.write(u"\n\30\7\30\u032e\n\30\f\30\16\30\u0331\13\30\3\31\5\31")
        buf.write(u"\u0334\n\31\3\31\3\31\5\31\u0338\n\31\3\31\3\31\5\31")
        buf.write(u"\u033c\n\31\3\31\3\31\5\31\u0340\n\31\5\31\u0342\n\31")
        buf.write(u"\3\32\3\32\3\32\3\32\3\32\3\32\3\32\7\32\u034b\n\32\f")
        buf.write(u"\32\16\32\u034e\13\32\3\32\3\32\5\32\u0352\n\32\3\33")
        buf.write(u"\3\33\3\33\3\33\3\33\3\33\3\33\5\33\u035b\n\33\3\34\3")
        buf.write(u"\34\3\35\3\35\5\35\u0361\n\35\3\35\3\35\5\35\u0365\n")
        buf.write(u"\35\5\35\u0367\n\35\3\36\3\36\3\36\3\36\7\36\u036d\n")
        buf.write(u"\36\f\36\16\36\u0370\13\36\3\36\3\36\3\37\3\37\3\37\3")
        buf.write(u"\37\3\37\3\37\3\37\3\37\3\37\3\37\7\37\u037e\n\37\f\37")
        buf.write(u"\16\37\u0381\13\37\3\37\3\37\3\37\5\37\u0386\n\37\3\37")
        buf.write(u"\3\37\3\37\3\37\3\37\3\37\3\37\3\37\3\37\5\37\u0391\n")
        buf.write(u"\37\3 \3 \3!\3!\3!\3!\5!\u0399\n!\3!\3!\3!\3!\3!\3!\7")
        buf.write(u"!\u03a1\n!\f!\16!\u03a4\13!\3\"\3\"\5\"\u03a8\n\"\3#")
        buf.write(u"\3#\3#\3#\3#\3#\3#\3#\3#\3#\5#\u03b4\n#\3#\3#\3#\3#\3")
        buf.write(u"#\3#\5#\u03bc\n#\3#\3#\3#\3#\3#\7#\u03c3\n#\f#\16#\u03c6")
        buf.write(u"\13#\3#\3#\3#\5#\u03cb\n#\3#\3#\3#\3#\3#\3#\5#\u03d3")
        buf.write(u"\n#\3#\3#\3#\3#\5#\u03d9\n#\3#\3#\5#\u03dd\n#\3#\3#\3")
        buf.write(u"#\5#\u03e2\n#\3#\3#\3#\5#\u03e7\n#\3$\3$\3$\3$\5$\u03ed")
        buf.write(u"\n$\3$\3$\3$\3$\3$\3$\3$\3$\3$\3$\3$\3$\7$\u03fb\n$\f")
        buf.write(u"$\16$\u03fe\13$\3%\3%\3%\3%\3%\3%\3%\3%\3%\3%\3%\3%\3")
        buf.write(u"%\3%\3%\3%\3%\3%\3%\3%\3%\3%\3%\3%\6%\u0418\n%\r%\16")
        buf.write(u"%\u0419\3%\3%\3%\3%\3%\3%\3%\7%\u0423\n%\f%\16%\u0426")
        buf.write(u"\13%\3%\3%\3%\3%\3%\3%\3%\5%\u042f\n%\3%\5%\u0432\n%")
        buf.write(u"\3%\3%\3%\5%\u0437\n%\3%\3%\3%\7%\u043c\n%\f%\16%\u043f")
        buf.write(u"\13%\5%\u0441\n%\3%\3%\3%\3%\3%\7%\u0448\n%\f%\16%\u044b")
        buf.write(u"\13%\5%\u044d\n%\3%\3%\5%\u0451\n%\3%\5%\u0454\n%\3%")
        buf.write(u"\3%\3%\3%\3%\3%\3%\3%\7%\u045e\n%\f%\16%\u0461\13%\5")
        buf.write(u"%\u0463\n%\3%\3%\3%\3%\3%\3%\3%\3%\3%\3%\3%\3%\3%\3%")
        buf.write(u"\3%\6%\u0474\n%\r%\16%\u0475\3%\3%\5%\u047a\n%\3%\3%")
        buf.write(u"\3%\3%\6%\u0480\n%\r%\16%\u0481\3%\3%\5%\u0486\n%\3%")
        buf.write(u"\3%\3%\3%\3%\3%\3%\3%\3%\3%\3%\3%\3%\3%\3%\3%\3%\3%\3")
        buf.write(u"%\3%\3%\7%\u049d\n%\f%\16%\u04a0\13%\5%\u04a2\n%\3%\3")
        buf.write(u"%\3%\3%\3%\3%\3%\5%\u04ab\n%\3%\3%\3%\3%\5%\u04b1\n%")
        buf.write(u"\3%\3%\3%\3%\5%\u04b7\n%\3%\3%\3%\3%\5%\u04bd\n%\3%\3")
        buf.write(u"%\3%\3%\3%\3%\3%\3%\5%\u04c7\n%\3%\3%\3%\3%\3%\3%\3%")
        buf.write(u"\5%\u04d0\n%\3%\3%\3%\3%\3%\3%\3%\3%\3%\3%\3%\3%\3%\3")
        buf.write(u"%\3%\3%\3%\3%\7%\u04e4\n%\f%\16%\u04e7\13%\5%\u04e9\n")
        buf.write(u"%\3%\5%\u04ec\n%\3%\3%\3%\3%\3%\3%\3%\3%\7%\u04f6\n%")
        buf.write(u"\f%\16%\u04f9\13%\3&\3&\3&\3&\5&\u04ff\n&\5&\u0501\n")
        buf.write(u"&\3\'\3\'\3\'\3\'\3\'\3\'\5\'\u0509\n\'\3(\3(\3)\3)\3")
        buf.write(u"*\3*\3+\3+\5+\u0513\n+\3+\3+\3+\3+\5+\u0519\n+\3,\3,")
        buf.write(u"\3-\3-\3.\3.\3.\3.\3.\3.\3.\3.\3.\3.\3.\3.\3.\3.\3.\3")
        buf.write(u".\3.\3.\3.\3.\3.\7.\u0534\n.\f.\16.\u0537\13.\3.\3.\3")
        buf.write(u".\3.\3.\3.\3.\7.\u0540\n.\f.\16.\u0543\13.\3.\3.\5.\u0547")
        buf.write(u"\n.\3.\3.\3.\3.\3.\5.\u054e\n.\3.\3.\7.\u0552\n.\f.\16")
        buf.write(u".\u0555\13.\3/\3/\5/\u0559\n/\3\60\3\60\3\60\3\60\5\60")
        buf.write(u"\u055f\n\60\3\61\3\61\3\61\3\61\3\61\3\62\3\62\3\62\3")
        buf.write(u"\62\3\62\3\62\3\63\3\63\3\63\3\63\3\63\3\63\3\63\7\63")
        buf.write(u"\u0573\n\63\f\63\16\63\u0576\13\63\5\63\u0578\n\63\3")
        buf.write(u"\63\3\63\3\63\3\63\3\63\7\63\u057f\n\63\f\63\16\63\u0582")
        buf.write(u"\13\63\5\63\u0584\n\63\3\63\5\63\u0587\n\63\3\63\3\63")
        buf.write(u"\3\64\3\64\3\64\3\64\3\64\3\64\3\64\3\64\3\64\3\64\3")
        buf.write(u"\64\3\64\3\64\3\64\3\64\3\64\5\64\u059b\n\64\3\65\3\65")
        buf.write(u"\3\65\3\65\3\65\3\65\3\65\3\65\3\65\5\65\u05a6\n\65\3")
        buf.write(u"\66\3\66\3\66\3\66\5\66\u05ac\n\66\3\67\3\67\3\67\3\67")
        buf.write(u"\3\67\5\67\u05b3\n\67\38\38\38\38\38\38\38\58\u05bc\n")
        buf.write(u"8\39\39\39\39\39\59\u05c3\n9\3:\3:\3:\3:\5:\u05c9\n:")
        buf.write(u"\3;\3;\3;\7;\u05ce\n;\f;\16;\u05d1\13;\3<\3<\3<\3<\3")
        buf.write(u"<\5<\u05d8\n<\3=\3=\3=\5=\u05dd\n=\3>\3>\3>\2\b\30.@")
        buf.write(u"FHZ?\2\4\6\b\n\f\16\20\22\24\26\30\32\34\36 \"$&(*,.")
        buf.write(u"\60\62\64\668:<>@BDFHJLNPRTVXZ\\^`bdfhjlnprtvxz\2\30")
        buf.write(u"\4\2\32\32\u008c\u008c\4\2FFQQ\4\2DDtt\4\2\r\r\u00d0")
        buf.write(u"\u00d0\4\2;;RR\4\2::\u00b2\u00b2\4\2\24\24\62\62\4\2")
        buf.write(u"BB]]\4\2\r\r\64\64\4\2\26\26\u00a1\u00a1\3\2\u00c7\u00c8")
        buf.write(u"\3\2\u00c9\u00cb\3\2\u00c1\u00c6\5\2\r\r\21\21\u009d")
        buf.write(u"\u009d\4\2@@\u00ac\u00ac\7\2//OOgh\u0095\u0095\u00bf")
        buf.write(u"\u00bf\3\2jm\4\2CC\u0080\u0080\4\2KK\u00a5\u00a5\5\2")
        buf.write(u"\65\65ee\u00b6\u00b6\4\2uu\u00be\u00be-\2\f\r\17\17\21")
        buf.write(u"\22\24\26\31\32\35#((-/\62\62\65\65;;>>ACEEHKOPRRTTV")
        buf.write(u"VXX[[]^``bbehjnrsuvyy{\u0080\u0082\u0086\u0088\u008d")
        buf.write(u"\u008f\u008f\u0091\u0095\u0097\u00a1\u00a3\u00a5\u00a7")
        buf.write(u"\u00ab\u00ad\u00ae\u00b0\u00b1\u00b4\u00b4\u00b6\u00b6")
        buf.write(u"\u00b8\u00b9\u00bd\u00c0\2\u06ce\2|\3\2\2\2\4\177\3\2")
        buf.write(u"\2\2\6\u0219\3\2\2\2\b\u021c\3\2\2\2\n\u0220\3\2\2\2")
        buf.write(u"\f\u022e\3\2\2\2\16\u0230\3\2\2\2\20\u0236\3\2\2\2\22")
        buf.write(u"\u023c\3\2\2\2\24\u0247\3\2\2\2\26\u024b\3\2\2\2\30\u025c")
        buf.write(u"\3\2\2\2\32\u0280\3\2\2\2\34\u0282\3\2\2\2\36\u028a\3")
        buf.write(u"\2\2\2 \u02af\3\2\2\2\"\u02e1\3\2\2\2$\u02f0\3\2\2\2")
        buf.write(u"&\u02ff\3\2\2\2(\u0301\3\2\2\2*\u030a\3\2\2\2,\u0318")
        buf.write(u"\3\2\2\2.\u031a\3\2\2\2\60\u0341\3\2\2\2\62\u0351\3\2")
        buf.write(u"\2\2\64\u0353\3\2\2\2\66\u035c\3\2\2\28\u035e\3\2\2\2")
        buf.write(u":\u0368\3\2\2\2<\u0390\3\2\2\2>\u0392\3\2\2\2@\u0398")
        buf.write(u"\3\2\2\2B\u03a5\3\2\2\2D\u03e6\3\2\2\2F\u03ec\3\2\2\2")
        buf.write(u"H\u04eb\3\2\2\2J\u0500\3\2\2\2L\u0508\3\2\2\2N\u050a")
        buf.write(u"\3\2\2\2P\u050c\3\2\2\2R\u050e\3\2\2\2T\u0510\3\2\2\2")
        buf.write(u"V\u051a\3\2\2\2X\u051c\3\2\2\2Z\u054d\3\2\2\2\\\u0558")
        buf.write(u"\3\2\2\2^\u055e\3\2\2\2`\u0560\3\2\2\2b\u0565\3\2\2\2")
        buf.write(u"d\u056b\3\2\2\2f\u059a\3\2\2\2h\u05a5\3\2\2\2j\u05ab")
        buf.write(u"\3\2\2\2l\u05b2\3\2\2\2n\u05bb\3\2\2\2p\u05c2\3\2\2\2")
        buf.write(u"r\u05c8\3\2\2\2t\u05ca\3\2\2\2v\u05d7\3\2\2\2x\u05dc")
        buf.write(u"\3\2\2\2z\u05de\3\2\2\2|}\5\6\4\2}~\7\2\2\3~\3\3\2\2")
        buf.write(u"\2\177\u0080\5> \2\u0080\u0081\7\2\2\3\u0081\5\3\2\2")
        buf.write(u"\2\u0082\u021a\5\b\5\2\u0083\u0084\7\u00b4\2\2\u0084")
        buf.write(u"\u021a\5v<\2\u0085\u0086\7\u00b4\2\2\u0086\u0087\5v<")
        buf.write(u"\2\u0087\u0088\7\3\2\2\u0088\u0089\5v<\2\u0089\u021a")
        buf.write(u"\3\2\2\2\u008a\u008b\7%\2\2\u008b\u008f\7\u0093\2\2\u008c")
        buf.write(u"\u008d\7P\2\2\u008d\u008e\7p\2\2\u008e\u0090\7=\2\2\u008f")
        buf.write(u"\u008c\3\2\2\2\u008f\u0090\3\2\2\2\u0090\u0091\3\2\2")
        buf.write(u"\2\u0091\u0094\5t;\2\u0092\u0093\7\u00bc\2\2\u0093\u0095")
        buf.write(u"\5\22\n\2\u0094\u0092\3\2\2\2\u0094\u0095\3\2\2\2\u0095")
        buf.write(u"\u021a\3\2\2\2\u0096\u0097\7\66\2\2\u0097\u009a\7\u0093")
        buf.write(u"\2\2\u0098\u0099\7P\2\2\u0099\u009b\7=\2\2\u009a\u0098")
        buf.write(u"\3\2\2\2\u009a\u009b\3\2\2\2\u009b\u009c\3\2\2\2\u009c")
        buf.write(u"\u009e\5t;\2\u009d\u009f\t\2\2\2\u009e\u009d\3\2\2\2")
        buf.write(u"\u009e\u009f\3\2\2\2\u009f\u021a\3\2\2\2\u00a0\u00a1")
        buf.write(u"\7\16\2\2\u00a1\u00a2\7\u0093\2\2\u00a2\u00a3\5t;\2\u00a3")
        buf.write(u"\u00a4\7\u0088\2\2\u00a4\u00a5\7\u00aa\2\2\u00a5\u00a6")
        buf.write(u"\5v<\2\u00a6\u021a\3\2\2\2\u00a7\u00a8\7%\2\2\u00a8\u00ac")
        buf.write(u"\7\u00a2\2\2\u00a9\u00aa\7P\2\2\u00aa\u00ab\7p\2\2\u00ab")
        buf.write(u"\u00ad\7=\2\2\u00ac\u00a9\3\2\2\2\u00ac\u00ad\3\2\2\2")
        buf.write(u"\u00ad\u00ae\3\2\2\2\u00ae\u00b0\5t;\2\u00af\u00b1\5")
        buf.write(u":\36\2\u00b0\u00af\3\2\2\2\u00b0\u00b1\3\2\2\2\u00b1")
        buf.write(u"\u00b4\3\2\2\2\u00b2\u00b3\7!\2\2\u00b3\u00b5\5J&\2\u00b4")
        buf.write(u"\u00b2\3\2\2\2\u00b4\u00b5\3\2\2\2\u00b5\u00b8\3\2\2")
        buf.write(u"\2\u00b6\u00b7\7\u00bc\2\2\u00b7\u00b9\5\22\n\2\u00b8")
        buf.write(u"\u00b6\3\2\2\2\u00b8\u00b9\3\2\2\2\u00b9\u00ba\3\2\2")
        buf.write(u"\2\u00ba\u00c0\7\23\2\2\u00bb\u00c1\5\b\5\2\u00bc\u00bd")
        buf.write(u"\7\4\2\2\u00bd\u00be\5\b\5\2\u00be\u00bf\7\5\2\2\u00bf")
        buf.write(u"\u00c1\3\2\2\2\u00c0\u00bb\3\2\2\2\u00c0\u00bc\3\2\2")
        buf.write(u"\2\u00c1\u00c7\3\2\2\2\u00c2\u00c4\7\u00bc\2\2\u00c3")
        buf.write(u"\u00c5\7n\2\2\u00c4\u00c3\3\2\2\2\u00c4\u00c5\3\2\2\2")
        buf.write(u"\u00c5\u00c6\3\2\2\2\u00c6\u00c8\7-\2\2\u00c7\u00c2\3")
        buf.write(u"\2\2\2\u00c7\u00c8\3\2\2\2\u00c8\u021a\3\2\2\2\u00c9")
        buf.write(u"\u00ca\7%\2\2\u00ca\u00ce\7\u00a2\2\2\u00cb\u00cc\7P")
        buf.write(u"\2\2\u00cc\u00cd\7p\2\2\u00cd\u00cf\7=\2\2\u00ce\u00cb")
        buf.write(u"\3\2\2\2\u00ce\u00cf\3\2\2\2\u00cf\u00d0\3\2\2\2\u00d0")
        buf.write(u"\u00d1\5t;\2\u00d1\u00d2\7\4\2\2\u00d2\u00d7\5\f\7\2")
        buf.write(u"\u00d3\u00d4\7\6\2\2\u00d4\u00d6\5\f\7\2\u00d5\u00d3")
        buf.write(u"\3\2\2\2\u00d6\u00d9\3\2\2\2\u00d7\u00d5\3\2\2\2\u00d7")
        buf.write(u"\u00d8\3\2\2\2\u00d8\u00da\3\2\2\2\u00d9\u00d7\3\2\2")
        buf.write(u"\2\u00da\u00dd\7\5\2\2\u00db\u00dc\7!\2\2\u00dc\u00de")
        buf.write(u"\5J&\2\u00dd\u00db\3\2\2\2\u00dd\u00de\3\2\2\2\u00de")
        buf.write(u"\u00e1\3\2\2\2\u00df\u00e0\7\u00bc\2\2\u00e0\u00e2\5")
        buf.write(u"\22\n\2\u00e1\u00df\3\2\2\2\u00e1\u00e2\3\2\2\2\u00e2")
        buf.write(u"\u021a\3\2\2\2\u00e3\u00e4\7\66\2\2\u00e4\u00e7\7\u00a2")
        buf.write(u"\2\2\u00e5\u00e6\7P\2\2\u00e6\u00e8\7=\2\2\u00e7\u00e5")
        buf.write(u"\3\2\2\2\u00e7\u00e8\3\2\2\2\u00e8\u00e9\3\2\2\2\u00e9")
        buf.write(u"\u021a\5t;\2\u00ea\u00eb\7U\2\2\u00eb\u00ec\7Y\2\2\u00ec")
        buf.write(u"\u00ee\5t;\2\u00ed\u00ef\5:\36\2\u00ee\u00ed\3\2\2\2")
        buf.write(u"\u00ee\u00ef\3\2\2\2\u00ef\u00f0\3\2\2\2\u00f0\u00f1")
        buf.write(u"\5\b\5\2\u00f1\u021a\3\2\2\2\u00f2\u00f3\7\61\2\2\u00f3")
        buf.write(u"\u00f4\7F\2\2\u00f4\u00f7\5t;\2\u00f5\u00f6\7\u00bb\2")
        buf.write(u"\2\u00f6\u00f8\5@!\2\u00f7\u00f5\3\2\2\2\u00f7\u00f8")
        buf.write(u"\3\2\2\2\u00f8\u021a\3\2\2\2\u00f9\u00fa\7\16\2\2\u00fa")
        buf.write(u"\u00fb\7\u00a2\2\2\u00fb\u00fc\5t;\2\u00fc\u00fd\7\u0088")
        buf.write(u"\2\2\u00fd\u00fe\7\u00aa\2\2\u00fe\u00ff\5t;\2\u00ff")
        buf.write(u"\u021a\3\2\2\2\u0100\u0101\7\16\2\2\u0101\u0102\7\u00a2")
        buf.write(u"\2\2\u0102\u0103\5t;\2\u0103\u0104\7\u0088\2\2\u0104")
        buf.write(u"\u0105\7\37\2\2\u0105\u0106\5v<\2\u0106\u0107\7\u00aa")
        buf.write(u"\2\2\u0107\u0108\5v<\2\u0108\u021a\3\2\2\2\u0109\u010a")
        buf.write(u"\7\16\2\2\u010a\u010b\7\u00a2\2\2\u010b\u010c\5t;\2\u010c")
        buf.write(u"\u010d\7\66\2\2\u010d\u010e\7\37\2\2\u010e\u010f\5t;")
        buf.write(u"\2\u010f\u021a\3\2\2\2\u0110\u0111\7\16\2\2\u0111\u0112")
        buf.write(u"\7\u00a2\2\2\u0112\u0113\5t;\2\u0113\u0114\7\f\2\2\u0114")
        buf.write(u"\u0115\7\37\2\2\u0115\u0116\5\16\b\2\u0116\u021a\3\2")
        buf.write(u"\2\2\u0117\u011a\7%\2\2\u0118\u0119\7w\2\2\u0119\u011b")
        buf.write(u"\7\u008a\2\2\u011a\u0118\3\2\2\2\u011a\u011b\3\2\2\2")
        buf.write(u"\u011b\u011c\3\2\2\2\u011c\u011d\7\u00b9\2\2\u011d\u011e")
        buf.write(u"\5t;\2\u011e\u011f\7\23\2\2\u011f\u0120\5\b\5\2\u0120")
        buf.write(u"\u021a\3\2\2\2\u0121\u0122\7\66\2\2\u0122\u0125\7\u00b9")
        buf.write(u"\2\2\u0123\u0124\7P\2\2\u0124\u0126\7=\2\2\u0125\u0123")
        buf.write(u"\3\2\2\2\u0125\u0126\3\2\2\2\u0126\u0127\3\2\2\2\u0127")
        buf.write(u"\u021a\5t;\2\u0128\u0129\7\31\2\2\u0129\u012a\5t;\2\u012a")
        buf.write(u"\u0133\7\4\2\2\u012b\u0130\5p9\2\u012c\u012d\7\6\2\2")
        buf.write(u"\u012d\u012f\5p9\2\u012e\u012c\3\2\2\2\u012f\u0132\3")
        buf.write(u"\2\2\2\u0130\u012e\3\2\2\2\u0130\u0131\3\2\2\2\u0131")
        buf.write(u"\u0134\3\2\2\2\u0132\u0130\3\2\2\2\u0133\u012b\3\2\2")
        buf.write(u"\2\u0133\u0134\3\2\2\2\u0134\u0135\3\2\2\2\u0135\u0136")
        buf.write(u"\7\5\2\2\u0136\u021a\3\2\2\2\u0137\u0142\7I\2\2\u0138")
        buf.write(u"\u013d\5r:\2\u0139\u013a\7\6\2\2\u013a\u013c\5r:\2\u013b")
        buf.write(u"\u0139\3\2\2\2\u013c\u013f\3\2\2\2\u013d\u013b\3\2\2")
        buf.write(u"\2\u013d\u013e\3\2\2\2\u013e\u0143\3\2\2\2\u013f\u013d")
        buf.write(u"\3\2\2\2\u0140\u0141\7\r\2\2\u0141\u0143\7\u0082\2\2")
        buf.write(u"\u0142\u0138\3\2\2\2\u0142\u0140\3\2\2\2\u0143\u0144")
        buf.write(u"\3\2\2\2\u0144\u0146\7t\2\2\u0145\u0147\7\u00a2\2\2\u0146")
        buf.write(u"\u0145\3\2\2\2\u0146\u0147\3\2\2\2\u0147\u0148\3\2\2")
        buf.write(u"\2\u0148\u0149\5t;\2\u0149\u014a\7\u00aa\2\2\u014a\u014e")
        buf.write(u"\5v<\2\u014b\u014c\7\u00bc\2\2\u014c\u014d\7I\2\2\u014d")
        buf.write(u"\u014f\7v\2\2\u014e\u014b\3\2\2\2\u014e\u014f\3\2\2\2")
        buf.write(u"\u014f\u021a\3\2\2\2\u0150\u0154\7\u008d\2\2\u0151\u0152")
        buf.write(u"\7I\2\2\u0152\u0153\7v\2\2\u0153\u0155\7D\2\2\u0154\u0151")
        buf.write(u"\3\2\2\2\u0154\u0155\3\2\2\2\u0155\u0160\3\2\2\2\u0156")
        buf.write(u"\u015b\5r:\2\u0157\u0158\7\6\2\2\u0158\u015a\5r:\2\u0159")
        buf.write(u"\u0157\3\2\2\2\u015a\u015d\3\2\2\2\u015b\u0159\3\2\2")
        buf.write(u"\2\u015b\u015c\3\2\2\2\u015c\u0161\3\2\2\2\u015d\u015b")
        buf.write(u"\3\2\2\2\u015e\u015f\7\r\2\2\u015f\u0161\7\u0082\2\2")
        buf.write(u"\u0160\u0156\3\2\2\2\u0160\u015e\3\2\2\2\u0161\u0162")
        buf.write(u"\3\2\2\2\u0162\u0164\7t\2\2\u0163\u0165\7\u00a2\2\2\u0164")
        buf.write(u"\u0163\3\2\2\2\u0164\u0165\3\2\2\2\u0165\u0166\3\2\2")
        buf.write(u"\2\u0166\u0167\5t;\2\u0167\u0168\7F\2\2\u0168\u0169\5")
        buf.write(u"v<\2\u0169\u021a\3\2\2\2\u016a\u016b\7\u009b\2\2\u016b")
        buf.write(u"\u0171\7J\2\2\u016c\u016e\7t\2\2\u016d\u016f\7\u00a2")
        buf.write(u"\2\2\u016e\u016d\3\2\2\2\u016e\u016f\3\2\2\2\u016f\u0170")
        buf.write(u"\3\2\2\2\u0170\u0172\5t;\2\u0171\u016c\3\2\2\2\u0171")
        buf.write(u"\u0172\3\2\2\2\u0172\u021a\3\2\2\2\u0173\u0175\7>\2\2")
        buf.write(u"\u0174\u0176\7\17\2\2\u0175\u0174\3\2\2\2\u0175\u0176")
        buf.write(u"\3\2\2\2\u0176\u0178\3\2\2\2\u0177\u0179\7\u00b8\2\2")
        buf.write(u"\u0178\u0177\3\2\2\2\u0178\u0179\3\2\2\2\u0179\u0185")
        buf.write(u"\3\2\2\2\u017a\u017b\7\4\2\2\u017b\u0180\5j\66\2\u017c")
        buf.write(u"\u017d\7\6\2\2\u017d\u017f\5j\66\2\u017e\u017c\3\2\2")
        buf.write(u"\2\u017f\u0182\3\2\2\2\u0180\u017e\3\2\2\2\u0180\u0181")
        buf.write(u"\3\2\2\2\u0181\u0183\3\2\2\2\u0182\u0180\3\2\2\2\u0183")
        buf.write(u"\u0184\7\5\2\2\u0184\u0186\3\2\2\2\u0185\u017a\3\2\2")
        buf.write(u"\2\u0185\u0186\3\2\2\2\u0186\u0187\3\2\2\2\u0187\u021a")
        buf.write(u"\5\6\4\2\u0188\u0189\7\u009b\2\2\u0189\u018a\7%\2\2\u018a")
        buf.write(u"\u018b\7\u00a2\2\2\u018b\u021a\5t;\2\u018c\u018d\7\u009b")
        buf.write(u"\2\2\u018d\u018e\7%\2\2\u018e\u018f\7\u00b9\2\2\u018f")
        buf.write(u"\u021a\5t;\2\u0190\u0191\7\u009b\2\2\u0191\u0194\7\u00a3")
        buf.write(u"\2\2\u0192\u0193\t\3\2\2\u0193\u0195\5t;\2\u0194\u0192")
        buf.write(u"\3\2\2\2\u0194\u0195\3\2\2\2\u0195\u019c\3\2\2\2\u0196")
        buf.write(u"\u0197\7a\2\2\u0197\u019a\5J&\2\u0198\u0199\79\2\2\u0199")
        buf.write(u"\u019b\5J&\2\u019a\u0198\3\2\2\2\u019a\u019b\3\2\2\2")
        buf.write(u"\u019b\u019d\3\2\2\2\u019c\u0196\3\2\2\2\u019c\u019d")
        buf.write(u"\3\2\2\2\u019d\u021a\3\2\2\2\u019e\u019f\7\u009b\2\2")
        buf.write(u"\u019f\u01a2\7\u0094\2\2\u01a0\u01a1\t\3\2\2\u01a1\u01a3")
        buf.write(u"\5v<\2\u01a2\u01a0\3\2\2\2\u01a2\u01a3\3\2\2\2\u01a3")
        buf.write(u"\u01aa\3\2\2\2\u01a4\u01a5\7a\2\2\u01a5\u01a8\5J&\2\u01a6")
        buf.write(u"\u01a7\79\2\2\u01a7\u01a9\5J&\2\u01a8\u01a6\3\2\2\2\u01a8")
        buf.write(u"\u01a9\3\2\2\2\u01a9\u01ab\3\2\2\2\u01aa\u01a4\3\2\2")
        buf.write(u"\2\u01aa\u01ab\3\2\2\2\u01ab\u021a\3\2\2\2\u01ac\u01ad")
        buf.write(u"\7\u009b\2\2\u01ad\u01b0\7\35\2\2\u01ae\u01af\7a\2\2")
        buf.write(u"\u01af\u01b1\5J&\2\u01b0\u01ae\3\2\2\2\u01b0\u01b1\3")
        buf.write(u"\2\2\2\u01b1\u021a\3\2\2\2\u01b2\u01b3\7\u009b\2\2\u01b3")
        buf.write(u"\u01b4\7 \2\2\u01b4\u01b5\t\3\2\2\u01b5\u021a\5t;\2\u01b6")
        buf.write(u"\u01b7\7\u009b\2\2\u01b7\u01b8\7\u009f\2\2\u01b8\u01b9")
        buf.write(u"\t\4\2\2\u01b9\u021a\5t;\2\u01ba\u01bb\7\u009b\2\2\u01bb")
        buf.write(u"\u01bc\7\u009f\2\2\u01bc\u01bd\7D\2\2\u01bd\u01be\7\4")
        buf.write(u"\2\2\u01be\u01bf\5\36\20\2\u01bf\u01c0\7\5\2\2\u01c0")
        buf.write(u"\u021a\3\2\2\2\u01c1\u01c2\7\63\2\2\u01c2\u021a\5t;\2")
        buf.write(u"\u01c3\u01c4\7\62\2\2\u01c4\u021a\5t;\2\u01c5\u01c6\7")
        buf.write(u"\u009b\2\2\u01c6\u021a\7H\2\2\u01c7\u01c8\7\u009b\2\2")
        buf.write(u"\u01c8\u021a\7\u0098\2\2\u01c9\u01ca\7\u0099\2\2\u01ca")
        buf.write(u"\u01cb\7\u0098\2\2\u01cb\u01cc\5t;\2\u01cc\u01cd\7\u00c1")
        buf.write(u"\2\2\u01cd\u01ce\5> \2\u01ce\u021a\3\2\2\2\u01cf\u01d0")
        buf.write(u"\7\u008b\2\2\u01d0\u01d1\7\u0098\2\2\u01d1\u021a\5t;")
        buf.write(u"\2\u01d2\u01d3\7\u009e\2\2\u01d3\u01dc\7\u00ab\2\2\u01d4")
        buf.write(u"\u01d9\5l\67\2\u01d5\u01d6\7\6\2\2\u01d6\u01d8\5l\67")
        buf.write(u"\2\u01d7\u01d5\3\2\2\2\u01d8\u01db\3\2\2\2\u01d9\u01d7")
        buf.write(u"\3\2\2\2\u01d9\u01da\3\2\2\2\u01da\u01dd\3\2\2\2\u01db")
        buf.write(u"\u01d9\3\2\2\2\u01dc\u01d4\3\2\2\2\u01dc\u01dd\3\2\2")
        buf.write(u"\2\u01dd\u021a\3\2\2\2\u01de\u01e0\7\"\2\2\u01df\u01e1")
        buf.write(u"\7\u00bd\2\2\u01e0\u01df\3\2\2\2\u01e0\u01e1\3\2\2\2")
        buf.write(u"\u01e1\u021a\3\2\2\2\u01e2\u01e4\7\u008f\2\2\u01e3\u01e5")
        buf.write(u"\7\u00bd\2\2\u01e4\u01e3\3\2\2\2\u01e4\u01e5\3\2\2\2")
        buf.write(u"\u01e5\u021a\3\2\2\2\u01e6\u01e7\7\u009b\2\2\u01e7\u01e8")
        buf.write(u"\7~\2\2\u01e8\u01e9\t\3\2\2\u01e9\u01ec\5t;\2\u01ea\u01eb")
        buf.write(u"\7\u00bb\2\2\u01eb\u01ed\5@!\2\u01ec\u01ea\3\2\2\2\u01ec")
        buf.write(u"\u01ed\3\2\2\2\u01ed\u01f8\3\2\2\2\u01ee\u01ef\7x\2\2")
        buf.write(u"\u01ef\u01f0\7\30\2\2\u01f0\u01f5\5\34\17\2\u01f1\u01f2")
        buf.write(u"\7\6\2\2\u01f2\u01f4\5\34\17\2\u01f3\u01f1\3\2\2\2\u01f4")
        buf.write(u"\u01f7\3\2\2\2\u01f5\u01f3\3\2\2\2\u01f5\u01f6\3\2\2")
        buf.write(u"\2\u01f6\u01f9\3\2\2\2\u01f7\u01f5\3\2\2\2\u01f8\u01ee")
        buf.write(u"\3\2\2\2\u01f8\u01f9\3\2\2\2\u01f9\u01fc\3\2\2\2\u01fa")
        buf.write(u"\u01fb\7b\2\2\u01fb\u01fd\t\5\2\2\u01fc\u01fa\3\2\2\2")
        buf.write(u"\u01fc\u01fd\3\2\2\2\u01fd\u021a\3\2\2\2\u01fe\u01ff")
        buf.write(u"\7\u0081\2\2\u01ff\u0200\5v<\2\u0200\u0201\7F\2\2\u0201")
        buf.write(u"\u0202\5\6\4\2\u0202\u021a\3\2\2\2\u0203\u0204\7\60\2")
        buf.write(u"\2\u0204\u0205\7\u0081\2\2\u0205\u021a\5v<\2\u0206\u0207")
        buf.write(u"\7<\2\2\u0207\u0211\5v<\2\u0208\u0209\7\u00b5\2\2\u0209")
        buf.write(u"\u020e\5> \2\u020a\u020b\7\6\2\2\u020b\u020d\5> \2\u020c")
        buf.write(u"\u020a\3\2\2\2\u020d\u0210\3\2\2\2\u020e\u020c\3\2\2")
        buf.write(u"\2\u020e\u020f\3\2\2\2\u020f\u0212\3\2\2\2\u0210\u020e")
        buf.write(u"\3\2\2\2\u0211\u0208\3\2\2\2\u0211\u0212\3\2\2\2\u0212")
        buf.write(u"\u021a\3\2\2\2\u0213\u0214\7\63\2\2\u0214\u0215\7T\2")
        buf.write(u"\2\u0215\u021a\5v<\2\u0216\u0217\7\63\2\2\u0217\u0218")
        buf.write(u"\7{\2\2\u0218\u021a\5v<\2\u0219\u0082\3\2\2\2\u0219\u0083")
        buf.write(u"\3\2\2\2\u0219\u0085\3\2\2\2\u0219\u008a\3\2\2\2\u0219")
        buf.write(u"\u0096\3\2\2\2\u0219\u00a0\3\2\2\2\u0219\u00a7\3\2\2")
        buf.write(u"\2\u0219\u00c9\3\2\2\2\u0219\u00e3\3\2\2\2\u0219\u00ea")
        buf.write(u"\3\2\2\2\u0219\u00f2\3\2\2\2\u0219\u00f9\3\2\2\2\u0219")
        buf.write(u"\u0100\3\2\2\2\u0219\u0109\3\2\2\2\u0219\u0110\3\2\2")
        buf.write(u"\2\u0219\u0117\3\2\2\2\u0219\u0121\3\2\2\2\u0219\u0128")
        buf.write(u"\3\2\2\2\u0219\u0137\3\2\2\2\u0219\u0150\3\2\2\2\u0219")
        buf.write(u"\u016a\3\2\2\2\u0219\u0173\3\2\2\2\u0219\u0188\3\2\2")
        buf.write(u"\2\u0219\u018c\3\2\2\2\u0219\u0190\3\2\2\2\u0219\u019e")
        buf.write(u"\3\2\2\2\u0219\u01ac\3\2\2\2\u0219\u01b2\3\2\2\2\u0219")
        buf.write(u"\u01b6\3\2\2\2\u0219\u01ba\3\2\2\2\u0219\u01c1\3\2\2")
        buf.write(u"\2\u0219\u01c3\3\2\2\2\u0219\u01c5\3\2\2\2\u0219\u01c7")
        buf.write(u"\3\2\2\2\u0219\u01c9\3\2\2\2\u0219\u01cf\3\2\2\2\u0219")
        buf.write(u"\u01d2\3\2\2\2\u0219\u01de\3\2\2\2\u0219\u01e2\3\2\2")
        buf.write(u"\2\u0219\u01e6\3\2\2\2\u0219\u01fe\3\2\2\2\u0219\u0203")
        buf.write(u"\3\2\2\2\u0219\u0206\3\2\2\2\u0219\u0213\3\2\2\2\u0219")
        buf.write(u"\u0216\3\2\2\2\u021a\7\3\2\2\2\u021b\u021d\5\n\6\2\u021c")
        buf.write(u"\u021b\3\2\2\2\u021c\u021d\3\2\2\2\u021d\u021e\3\2\2")
        buf.write(u"\2\u021e\u021f\5\26\f\2\u021f\t\3\2\2\2\u0220\u0222\7")
        buf.write(u"\u00bc\2\2\u0221\u0223\7\u0087\2\2\u0222\u0221\3\2\2")
        buf.write(u"\2\u0222\u0223\3\2\2\2\u0223\u0224\3\2\2\2\u0224\u0229")
        buf.write(u"\5(\25\2\u0225\u0226\7\6\2\2\u0226\u0228\5(\25\2\u0227")
        buf.write(u"\u0225\3\2\2\2\u0228\u022b\3\2\2\2\u0229\u0227\3\2\2")
        buf.write(u"\2\u0229\u022a\3\2\2\2\u022a\13\3\2\2\2\u022b\u0229\3")
        buf.write(u"\2\2\2\u022c\u022f\5\16\b\2\u022d\u022f\5\20\t\2\u022e")
        buf.write(u"\u022c\3\2\2\2\u022e\u022d\3\2\2\2\u022f\r\3\2\2\2\u0230")
        buf.write(u"\u0231\5v<\2\u0231\u0234\5Z.\2\u0232\u0233\7!\2\2\u0233")
        buf.write(u"\u0235\5J&\2\u0234\u0232\3\2\2\2\u0234\u0235\3\2\2\2")
        buf.write(u"\u0235\17\3\2\2\2\u0236\u0237\7a\2\2\u0237\u023a\5t;")
        buf.write(u"\2\u0238\u0239\t\6\2\2\u0239\u023b\7\u0083\2\2\u023a")
        buf.write(u"\u0238\3\2\2\2\u023a\u023b\3\2\2\2\u023b\21\3\2\2\2\u023c")
        buf.write(u"\u023d\7\4\2\2\u023d\u0242\5\24\13\2\u023e\u023f\7\6")
        buf.write(u"\2\2\u023f\u0241\5\24\13\2\u0240\u023e\3\2\2\2\u0241")
        buf.write(u"\u0244\3\2\2\2\u0242\u0240\3\2\2\2\u0242\u0243\3\2\2")
        buf.write(u"\2\u0243\u0245\3\2\2\2\u0244\u0242\3\2\2\2\u0245\u0246")
        buf.write(u"\7\5\2\2\u0246\23\3\2\2\2\u0247\u0248\5v<\2\u0248\u0249")
        buf.write(u"\7\u00c1\2\2\u0249\u024a\5> \2\u024a\25\3\2\2\2\u024b")
        buf.write(u"\u0256\5\30\r\2\u024c\u024d\7x\2\2\u024d\u024e\7\30\2")
        buf.write(u"\2\u024e\u0253\5\34\17\2\u024f\u0250\7\6\2\2\u0250\u0252")
        buf.write(u"\5\34\17\2\u0251\u024f\3\2\2\2\u0252\u0255\3\2\2\2\u0253")
        buf.write(u"\u0251\3\2\2\2\u0253\u0254\3\2\2\2\u0254\u0257\3\2\2")
        buf.write(u"\2\u0255\u0253\3\2\2\2\u0256\u024c\3\2\2\2\u0256\u0257")
        buf.write(u"\3\2\2\2\u0257\u025a\3\2\2\2\u0258\u0259\7b\2\2\u0259")
        buf.write(u"\u025b\t\5\2\2\u025a\u0258\3\2\2\2\u025a\u025b\3\2\2")
        buf.write(u"\2\u025b\27\3\2\2\2\u025c\u025d\b\r\1\2\u025d\u025e\5")
        buf.write(u"\32\16\2\u025e\u026d\3\2\2\2\u025f\u0260\f\4\2\2\u0260")
        buf.write(u"\u0262\7W\2\2\u0261\u0263\5*\26\2\u0262\u0261\3\2\2\2")
        buf.write(u"\u0262\u0263\3\2\2\2\u0263\u0264\3\2\2\2\u0264\u026c")
        buf.write(u"\5\30\r\5\u0265\u0266\f\3\2\2\u0266\u0268\t\7\2\2\u0267")
        buf.write(u"\u0269\5*\26\2\u0268\u0267\3\2\2\2\u0268\u0269\3\2\2")
        buf.write(u"\2\u0269\u026a\3\2\2\2\u026a\u026c\5\30\r\4\u026b\u025f")
        buf.write(u"\3\2\2\2\u026b\u0265\3\2\2\2\u026c\u026f\3\2\2\2\u026d")
        buf.write(u"\u026b\3\2\2\2\u026d\u026e\3\2\2\2\u026e\31\3\2\2\2\u026f")
        buf.write(u"\u026d\3\2\2\2\u0270\u0281\5\36\20\2\u0271\u0272\7\u00a2")
        buf.write(u"\2\2\u0272\u0281\5t;\2\u0273\u0274\7\u00b7\2\2\u0274")
        buf.write(u"\u0279\5> \2\u0275\u0276\7\6\2\2\u0276\u0278\5> \2\u0277")
        buf.write(u"\u0275\3\2\2\2\u0278\u027b\3\2\2\2\u0279\u0277\3\2\2")
        buf.write(u"\2\u0279\u027a\3\2\2\2\u027a\u0281\3\2\2\2\u027b\u0279")
        buf.write(u"\3\2\2\2\u027c\u027d\7\4\2\2\u027d\u027e\5\26\f\2\u027e")
        buf.write(u"\u027f\7\5\2\2\u027f\u0281\3\2\2\2\u0280\u0270\3\2\2")
        buf.write(u"\2\u0280\u0271\3\2\2\2\u0280\u0273\3\2\2\2\u0280\u027c")
        buf.write(u"\3\2\2\2\u0281\33\3\2\2\2\u0282\u0284\5> \2\u0283\u0285")
        buf.write(u"\t\b\2\2\u0284\u0283\3\2\2\2\u0284\u0285\3\2\2\2\u0285")
        buf.write(u"\u0288\3\2\2\2\u0286\u0287\7s\2\2\u0287\u0289\t\t\2\2")
        buf.write(u"\u0288\u0286\3\2\2\2\u0288\u0289\3\2\2\2\u0289\35\3\2")
        buf.write(u"\2\2\u028a\u028c\7\u0096\2\2\u028b\u028d\5*\26\2\u028c")
        buf.write(u"\u028b\3\2\2\2\u028c\u028d\3\2\2\2\u028d\u028e\3\2\2")
        buf.write(u"\2\u028e\u0293\5,\27\2\u028f\u0290\7\6\2\2\u0290\u0292")
        buf.write(u"\5,\27\2\u0291\u028f\3\2\2\2\u0292\u0295\3\2\2\2\u0293")
        buf.write(u"\u0291\3\2\2\2\u0293\u0294\3\2\2\2\u0294\u029f\3\2\2")
        buf.write(u"\2\u0295\u0293\3\2\2\2\u0296\u0297\7F\2\2\u0297\u029c")
        buf.write(u"\5.\30\2\u0298\u0299\7\6\2\2\u0299\u029b\5.\30\2\u029a")
        buf.write(u"\u0298\3\2\2\2\u029b\u029e\3\2\2\2\u029c\u029a\3\2\2")
        buf.write(u"\2\u029c\u029d\3\2\2\2\u029d\u02a0\3\2\2\2\u029e\u029c")
        buf.write(u"\3\2\2\2\u029f\u0296\3\2\2\2\u029f\u02a0\3\2\2\2\u02a0")
        buf.write(u"\u02a3\3\2\2\2\u02a1\u02a2\7\u00bb\2\2\u02a2\u02a4\5")
        buf.write(u"@!\2\u02a3\u02a1\3\2\2\2\u02a3\u02a4\3\2\2\2\u02a4\u02a8")
        buf.write(u"\3\2\2\2\u02a5\u02a6\7L\2\2\u02a6\u02a7\7\30\2\2\u02a7")
        buf.write(u"\u02a9\5 \21\2\u02a8\u02a5\3\2\2\2\u02a8\u02a9\3\2\2")
        buf.write(u"\2\u02a9\u02ac\3\2\2\2\u02aa\u02ab\7N\2\2\u02ab\u02ad")
        buf.write(u"\5@!\2\u02ac\u02aa\3\2\2\2\u02ac\u02ad\3\2\2\2\u02ad")
        buf.write(u"\37\3\2\2\2\u02ae\u02b0\5*\26\2\u02af\u02ae\3\2\2\2\u02af")
        buf.write(u"\u02b0\3\2\2\2\u02b0\u02b1\3\2\2\2\u02b1\u02b6\5\"\22")
        buf.write(u"\2\u02b2\u02b3\7\6\2\2\u02b3\u02b5\5\"\22\2\u02b4\u02b2")
        buf.write(u"\3\2\2\2\u02b5\u02b8\3\2\2\2\u02b6\u02b4\3\2\2\2\u02b6")
        buf.write(u"\u02b7\3\2\2\2\u02b7!\3\2\2\2\u02b8\u02b6\3\2\2\2\u02b9")
        buf.write(u"\u02e2\5$\23\2\u02ba\u02bb\7\u0090\2\2\u02bb\u02c4\7")
        buf.write(u"\4\2\2\u02bc\u02c1\5t;\2\u02bd\u02be\7\6\2\2\u02be\u02c0")
        buf.write(u"\5t;\2\u02bf\u02bd\3\2\2\2\u02c0\u02c3\3\2\2\2\u02c1")
        buf.write(u"\u02bf\3\2\2\2\u02c1\u02c2\3\2\2\2\u02c2\u02c5\3\2\2")
        buf.write(u"\2\u02c3\u02c1\3\2\2\2\u02c4\u02bc\3\2\2\2\u02c4\u02c5")
        buf.write(u"\3\2\2\2\u02c5\u02c6\3\2\2\2\u02c6\u02e2\7\5\2\2\u02c7")
        buf.write(u"\u02c8\7\'\2\2\u02c8\u02d1\7\4\2\2\u02c9\u02ce\5t;\2")
        buf.write(u"\u02ca\u02cb\7\6\2\2\u02cb\u02cd\5t;\2\u02cc\u02ca\3")
        buf.write(u"\2\2\2\u02cd\u02d0\3\2\2\2\u02ce\u02cc\3\2\2\2\u02ce")
        buf.write(u"\u02cf\3\2\2\2\u02cf\u02d2\3\2\2\2\u02d0\u02ce\3\2\2")
        buf.write(u"\2\u02d1\u02c9\3\2\2\2\u02d1\u02d2\3\2\2\2\u02d2\u02d3")
        buf.write(u"\3\2\2\2\u02d3\u02e2\7\5\2\2\u02d4\u02d5\7M\2\2\u02d5")
        buf.write(u"\u02d6\7\u009a\2\2\u02d6\u02d7\7\4\2\2\u02d7\u02dc\5")
        buf.write(u"&\24\2\u02d8\u02d9\7\6\2\2\u02d9\u02db\5&\24\2\u02da")
        buf.write(u"\u02d8\3\2\2\2\u02db\u02de\3\2\2\2\u02dc\u02da\3\2\2")
        buf.write(u"\2\u02dc\u02dd\3\2\2\2\u02dd\u02df\3\2\2\2\u02de\u02dc")
        buf.write(u"\3\2\2\2\u02df\u02e0\7\5\2\2\u02e0\u02e2\3\2\2\2\u02e1")
        buf.write(u"\u02b9\3\2\2\2\u02e1\u02ba\3\2\2\2\u02e1\u02c7\3\2\2")
        buf.write(u"\2\u02e1\u02d4\3\2\2\2\u02e2#\3\2\2\2\u02e3\u02ec\7\4")
        buf.write(u"\2\2\u02e4\u02e9\5> \2\u02e5\u02e6\7\6\2\2\u02e6\u02e8")
        buf.write(u"\5> \2\u02e7\u02e5\3\2\2\2\u02e8\u02eb\3\2\2\2\u02e9")
        buf.write(u"\u02e7\3\2\2\2\u02e9\u02ea\3\2\2\2\u02ea\u02ed\3\2\2")
        buf.write(u"\2\u02eb\u02e9\3\2\2\2\u02ec\u02e4\3\2\2\2\u02ec\u02ed")
        buf.write(u"\3\2\2\2\u02ed\u02ee\3\2\2\2\u02ee\u02f1\7\5\2\2\u02ef")
        buf.write(u"\u02f1\5> \2\u02f0\u02e3\3\2\2\2\u02f0\u02ef\3\2\2\2")
        buf.write(u"\u02f1%\3\2\2\2\u02f2\u02fb\7\4\2\2\u02f3\u02f8\5t;\2")
        buf.write(u"\u02f4\u02f5\7\6\2\2\u02f5\u02f7\5t;\2\u02f6\u02f4\3")
        buf.write(u"\2\2\2\u02f7\u02fa\3\2\2\2\u02f8\u02f6\3\2\2\2\u02f8")
        buf.write(u"\u02f9\3\2\2\2\u02f9\u02fc\3\2\2\2\u02fa\u02f8\3\2\2")
        buf.write(u"\2\u02fb\u02f3\3\2\2\2\u02fb\u02fc\3\2\2\2\u02fc\u02fd")
        buf.write(u"\3\2\2\2\u02fd\u0300\7\5\2\2\u02fe\u0300\5t;\2\u02ff")
        buf.write(u"\u02f2\3\2\2\2\u02ff\u02fe\3\2\2\2\u0300\'\3\2\2\2\u0301")
        buf.write(u"\u0303\5v<\2\u0302\u0304\5:\36\2\u0303\u0302\3\2\2\2")
        buf.write(u"\u0303\u0304\3\2\2\2\u0304\u0305\3\2\2\2\u0305\u0306")
        buf.write(u"\7\23\2\2\u0306\u0307\7\4\2\2\u0307\u0308\5\b\5\2\u0308")
        buf.write(u"\u0309\7\5\2\2\u0309)\3\2\2\2\u030a\u030b\t\n\2\2\u030b")
        buf.write(u"+\3\2\2\2\u030c\u0311\5> \2\u030d\u030f\7\23\2\2\u030e")
        buf.write(u"\u030d\3\2\2\2\u030e\u030f\3\2\2\2\u030f\u0310\3\2\2")
        buf.write(u"\2\u0310\u0312\5v<\2\u0311\u030e\3\2\2\2\u0311\u0312")
        buf.write(u"\3\2\2\2\u0312\u0319\3\2\2\2\u0313\u0314\5t;\2\u0314")
        buf.write(u"\u0315\7\3\2\2\u0315\u0316\7\u00c9\2\2\u0316\u0319\3")
        buf.write(u"\2\2\2\u0317\u0319\7\u00c9\2\2\u0318\u030c\3\2\2\2\u0318")
        buf.write(u"\u0313\3\2\2\2\u0318\u0317\3\2\2\2\u0319-\3\2\2\2\u031a")
        buf.write(u"\u031b\b\30\1\2\u031b\u031c\5\64\33\2\u031c\u032f\3\2")
        buf.write(u"\2\2\u031d\u032b\f\4\2\2\u031e\u031f\7&\2\2\u031f\u0320")
        buf.write(u"\7\\\2\2\u0320\u032c\5\64\33\2\u0321\u0322\5\60\31\2")
        buf.write(u"\u0322\u0323\7\\\2\2\u0323\u0324\5.\30\2\u0324\u0325")
        buf.write(u"\5\62\32\2\u0325\u032c\3\2\2\2\u0326\u0327\7i\2\2\u0327")
        buf.write(u"\u0328\5\60\31\2\u0328\u0329\7\\\2\2\u0329\u032a\5\64")
        buf.write(u"\33\2\u032a\u032c\3\2\2\2\u032b\u031e\3\2\2\2\u032b\u0321")
        buf.write(u"\3\2\2\2\u032b\u0326\3\2\2\2\u032c\u032e\3\2\2\2\u032d")
        buf.write(u"\u031d\3\2\2\2\u032e\u0331\3\2\2\2\u032f\u032d\3\2\2")
        buf.write(u"\2\u032f\u0330\3\2\2\2\u0330/\3\2\2\2\u0331\u032f\3\2")
        buf.write(u"\2\2\u0332\u0334\7S\2\2\u0333\u0332\3\2\2\2\u0333\u0334")
        buf.write(u"\3\2\2\2\u0334\u0342\3\2\2\2\u0335\u0337\7_\2\2\u0336")
        buf.write(u"\u0338\7z\2\2\u0337\u0336\3\2\2\2\u0337\u0338\3\2\2\2")
        buf.write(u"\u0338\u0342\3\2\2\2\u0339\u033b\7\u008e\2\2\u033a\u033c")
        buf.write(u"\7z\2\2\u033b\u033a\3\2\2\2\u033b\u033c\3\2\2\2\u033c")
        buf.write(u"\u0342\3\2\2\2\u033d\u033f\7G\2\2\u033e\u0340\7z\2\2")
        buf.write(u"\u033f\u033e\3\2\2\2\u033f\u0340\3\2\2\2\u0340\u0342")
        buf.write(u"\3\2\2\2\u0341\u0333\3\2\2\2\u0341\u0335\3\2\2\2\u0341")
        buf.write(u"\u0339\3\2\2\2\u0341\u033d\3\2\2\2\u0342\61\3\2\2\2\u0343")
        buf.write(u"\u0344\7t\2\2\u0344\u0352\5@!\2\u0345\u0346\7\u00b5\2")
        buf.write(u"\2\u0346\u0347\7\4\2\2\u0347\u034c\5v<\2\u0348\u0349")
        buf.write(u"\7\6\2\2\u0349\u034b\5v<\2\u034a\u0348\3\2\2\2\u034b")
        buf.write(u"\u034e\3\2\2\2\u034c\u034a\3\2\2\2\u034c\u034d\3\2\2")
        buf.write(u"\2\u034d\u034f\3\2\2\2\u034e\u034c\3\2\2\2\u034f\u0350")
        buf.write(u"\7\5\2\2\u0350\u0352\3\2\2\2\u0351\u0343\3\2\2\2\u0351")
        buf.write(u"\u0345\3\2\2\2\u0352\63\3\2\2\2\u0353\u035a\58\35\2\u0354")
        buf.write(u"\u0355\7\u00a4\2\2\u0355\u0356\5\66\34\2\u0356\u0357")
        buf.write(u"\7\4\2\2\u0357\u0358\5> \2\u0358\u0359\7\5\2\2\u0359")
        buf.write(u"\u035b\3\2\2\2\u035a\u0354\3\2\2\2\u035a\u035b\3\2\2")
        buf.write(u"\2\u035b\65\3\2\2\2\u035c\u035d\t\13\2\2\u035d\67\3\2")
        buf.write(u"\2\2\u035e\u0366\5<\37\2\u035f\u0361\7\23\2\2\u0360\u035f")
        buf.write(u"\3\2\2\2\u0360\u0361\3\2\2\2\u0361\u0362\3\2\2\2\u0362")
        buf.write(u"\u0364\5v<\2\u0363\u0365\5:\36\2\u0364\u0363\3\2\2\2")
        buf.write(u"\u0364\u0365\3\2\2\2\u0365\u0367\3\2\2\2\u0366\u0360")
        buf.write(u"\3\2\2\2\u0366\u0367\3\2\2\2\u03679\3\2\2\2\u0368\u0369")
        buf.write(u"\7\4\2\2\u0369\u036e\5v<\2\u036a\u036b\7\6\2\2\u036b")
        buf.write(u"\u036d\5v<\2\u036c\u036a\3\2\2\2\u036d\u0370\3\2\2\2")
        buf.write(u"\u036e\u036c\3\2\2\2\u036e\u036f\3\2\2\2\u036f\u0371")
        buf.write(u"\3\2\2\2\u0370\u036e\3\2\2\2\u0371\u0372\7\5\2\2\u0372")
        buf.write(u";\3\2\2\2\u0373\u0391\5t;\2\u0374\u0375\7\4\2\2\u0375")
        buf.write(u"\u0376\5\b\5\2\u0376\u0377\7\5\2\2\u0377\u0391\3\2\2")
        buf.write(u"\2\u0378\u0379\7\u00b3\2\2\u0379\u037a\7\4\2\2\u037a")
        buf.write(u"\u037f\5> \2\u037b\u037c\7\6\2\2\u037c\u037e\5> \2\u037d")
        buf.write(u"\u037b\3\2\2\2\u037e\u0381\3\2\2\2\u037f\u037d\3\2\2")
        buf.write(u"\2\u037f\u0380\3\2\2\2\u0380\u0382\3\2\2\2\u0381\u037f")
        buf.write(u"\3\2\2\2\u0382\u0385\7\5\2\2\u0383\u0384\7\u00bc\2\2")
        buf.write(u"\u0384\u0386\7y\2\2\u0385\u0383\3\2\2\2\u0385\u0386\3")
        buf.write(u"\2\2\2\u0386\u0391\3\2\2\2\u0387\u0388\7^\2\2\u0388\u0389")
        buf.write(u"\7\4\2\2\u0389\u038a\5\b\5\2\u038a\u038b\7\5\2\2\u038b")
        buf.write(u"\u0391\3\2\2\2\u038c\u038d\7\4\2\2\u038d\u038e\5.\30")
        buf.write(u"\2\u038e\u038f\7\5\2\2\u038f\u0391\3\2\2\2\u0390\u0373")
        buf.write(u"\3\2\2\2\u0390\u0374\3\2\2\2\u0390\u0378\3\2\2\2\u0390")
        buf.write(u"\u0387\3\2\2\2\u0390\u038c\3\2\2\2\u0391=\3\2\2\2\u0392")
        buf.write(u"\u0393\5@!\2\u0393?\3\2\2\2\u0394\u0395\b!\1\2\u0395")
        buf.write(u"\u0399\5B\"\2\u0396\u0397\7p\2\2\u0397\u0399\5@!\5\u0398")
        buf.write(u"\u0394\3\2\2\2\u0398\u0396\3\2\2\2\u0399\u03a2\3\2\2")
        buf.write(u"\2\u039a\u039b\f\4\2\2\u039b\u039c\7\20\2\2\u039c\u03a1")
        buf.write(u"\5@!\5\u039d\u039e\f\3\2\2\u039e\u039f\7w\2\2\u039f\u03a1")
        buf.write(u"\5@!\4\u03a0\u039a\3\2\2\2\u03a0\u039d\3\2\2\2\u03a1")
        buf.write(u"\u03a4\3\2\2\2\u03a2\u03a0\3\2\2\2\u03a2\u03a3\3\2\2")
        buf.write(u"\2\u03a3A\3\2\2\2\u03a4\u03a2\3\2\2\2\u03a5\u03a7\5F")
        buf.write(u"$\2\u03a6\u03a8\5D#\2\u03a7\u03a6\3\2\2\2\u03a7\u03a8")
        buf.write(u"\3\2\2\2\u03a8C\3\2\2\2\u03a9\u03aa\5N(\2\u03aa\u03ab")
        buf.write(u"\5F$\2\u03ab\u03e7\3\2\2\2\u03ac\u03ad\5N(\2\u03ad\u03ae")
        buf.write(u"\5P)\2\u03ae\u03af\7\4\2\2\u03af\u03b0\5\b\5\2\u03b0")
        buf.write(u"\u03b1\7\5\2\2\u03b1\u03e7\3\2\2\2\u03b2\u03b4\7p\2\2")
        buf.write(u"\u03b3\u03b2\3\2\2\2\u03b3\u03b4\3\2\2\2\u03b4\u03b5")
        buf.write(u"\3\2\2\2\u03b5\u03b6\7\27\2\2\u03b6\u03b7\5F$\2\u03b7")
        buf.write(u"\u03b8\7\20\2\2\u03b8\u03b9\5F$\2\u03b9\u03e7\3\2\2\2")
        buf.write(u"\u03ba\u03bc\7p\2\2\u03bb\u03ba\3\2\2\2\u03bb\u03bc\3")
        buf.write(u"\2\2\2\u03bc\u03bd\3\2\2\2\u03bd\u03be\7Q\2\2\u03be\u03bf")
        buf.write(u"\7\4\2\2\u03bf\u03c4\5> \2\u03c0\u03c1\7\6\2\2\u03c1")
        buf.write(u"\u03c3\5> \2\u03c2\u03c0\3\2\2\2\u03c3\u03c6\3\2\2\2")
        buf.write(u"\u03c4\u03c2\3\2\2\2\u03c4\u03c5\3\2\2\2\u03c5\u03c7")
        buf.write(u"\3\2\2\2\u03c6\u03c4\3\2\2\2\u03c7\u03c8\7\5\2\2\u03c8")
        buf.write(u"\u03e7\3\2\2\2\u03c9\u03cb\7p\2\2\u03ca\u03c9\3\2\2\2")
        buf.write(u"\u03ca\u03cb\3\2\2\2\u03cb\u03cc\3\2\2\2\u03cc\u03cd")
        buf.write(u"\7Q\2\2\u03cd\u03ce\7\4\2\2\u03ce\u03cf\5\b\5\2\u03cf")
        buf.write(u"\u03d0\7\5\2\2\u03d0\u03e7\3\2\2\2\u03d1\u03d3\7p\2\2")
        buf.write(u"\u03d2\u03d1\3\2\2\2\u03d2\u03d3\3\2\2\2\u03d3\u03d4")
        buf.write(u"\3\2\2\2\u03d4\u03d5\7a\2\2\u03d5\u03d8\5F$\2\u03d6\u03d7")
        buf.write(u"\79\2\2\u03d7\u03d9\5F$\2\u03d8\u03d6\3\2\2\2\u03d8\u03d9")
        buf.write(u"\3\2\2\2\u03d9\u03e7\3\2\2\2\u03da\u03dc\7Z\2\2\u03db")
        buf.write(u"\u03dd\7p\2\2\u03dc\u03db\3\2\2\2\u03dc\u03dd\3\2\2\2")
        buf.write(u"\u03dd\u03de\3\2\2\2\u03de\u03e7\7q\2\2\u03df\u03e1\7")
        buf.write(u"Z\2\2\u03e0\u03e2\7p\2\2\u03e1\u03e0\3\2\2\2\u03e1\u03e2")
        buf.write(u"\3\2\2\2\u03e2\u03e3\3\2\2\2\u03e3\u03e4\7\64\2\2\u03e4")
        buf.write(u"\u03e5\7F\2\2\u03e5\u03e7\5F$\2\u03e6\u03a9\3\2\2\2\u03e6")
        buf.write(u"\u03ac\3\2\2\2\u03e6\u03b3\3\2\2\2\u03e6\u03bb\3\2\2")
        buf.write(u"\2\u03e6\u03ca\3\2\2\2\u03e6\u03d2\3\2\2\2\u03e6\u03da")
        buf.write(u"\3\2\2\2\u03e6\u03df\3\2\2\2\u03e7E\3\2\2\2\u03e8\u03e9")
        buf.write(u"\b$\1\2\u03e9\u03ed\5H%\2\u03ea\u03eb\t\f\2\2\u03eb\u03ed")
        buf.write(u"\5F$\6\u03ec\u03e8\3\2\2\2\u03ec\u03ea\3\2\2\2\u03ed")
        buf.write(u"\u03fc\3\2\2\2\u03ee\u03ef\f\5\2\2\u03ef\u03f0\t\r\2")
        buf.write(u"\2\u03f0\u03fb\5F$\6\u03f1\u03f2\f\4\2\2\u03f2\u03f3")
        buf.write(u"\t\f\2\2\u03f3\u03fb\5F$\5\u03f4\u03f5\f\3\2\2\u03f5")
        buf.write(u"\u03f6\7\u00cc\2\2\u03f6\u03fb\5F$\4\u03f7\u03f8\f\7")
        buf.write(u"\2\2\u03f8\u03f9\7\25\2\2\u03f9\u03fb\5L\'\2\u03fa\u03ee")
        buf.write(u"\3\2\2\2\u03fa\u03f1\3\2\2\2\u03fa\u03f4\3\2\2\2\u03fa")
        buf.write(u"\u03f7\3\2\2\2\u03fb\u03fe\3\2\2\2\u03fc\u03fa\3\2\2")
        buf.write(u"\2\u03fc\u03fd\3\2\2\2\u03fdG\3\2\2\2\u03fe\u03fc\3\2")
        buf.write(u"\2\2\u03ff\u0400\b%\1\2\u0400\u04ec\7q\2\2\u0401\u04ec")
        buf.write(u"\5T+\2\u0402\u0403\5v<\2\u0403\u0404\5J&\2\u0404\u04ec")
        buf.write(u"\3\2\2\2\u0405\u0406\7\u00d9\2\2\u0406\u04ec\5J&\2\u0407")
        buf.write(u"\u04ec\5x=\2\u0408\u04ec\5R*\2\u0409\u04ec\5J&\2\u040a")
        buf.write(u"\u04ec\7\u00cf\2\2\u040b\u04ec\7\7\2\2\u040c\u040d\7")
        buf.write(u"\177\2\2\u040d\u040e\7\4\2\2\u040e\u040f\5F$\2\u040f")
        buf.write(u"\u0410\7Q\2\2\u0410\u0411\5F$\2\u0411\u0412\7\5\2\2\u0412")
        buf.write(u"\u04ec\3\2\2\2\u0413\u0414\7\4\2\2\u0414\u0417\5> \2")
        buf.write(u"\u0415\u0416\7\6\2\2\u0416\u0418\5> \2\u0417\u0415\3")
        buf.write(u"\2\2\2\u0418\u0419\3\2\2\2\u0419\u0417\3\2\2\2\u0419")
        buf.write(u"\u041a\3\2\2\2\u041a\u041b\3\2\2\2\u041b\u041c\7\5\2")
        buf.write(u"\2\u041c\u04ec\3\2\2\2\u041d\u041e\7\u0091\2\2\u041e")
        buf.write(u"\u041f\7\4\2\2\u041f\u0424\5> \2\u0420\u0421\7\6\2\2")
        buf.write(u"\u0421\u0423\5> \2\u0422\u0420\3\2\2\2\u0423\u0426\3")
        buf.write(u"\2\2\2\u0424\u0422\3\2\2\2\u0424\u0425\3\2\2\2\u0425")
        buf.write(u"\u0427\3\2\2\2\u0426\u0424\3\2\2\2\u0427\u0428\7\5\2")
        buf.write(u"\2\u0428\u04ec\3\2\2\2\u0429\u042a\5t;\2\u042a\u042b")
        buf.write(u"\7\4\2\2\u042b\u042c\7\u00c9\2\2\u042c\u042e\7\5\2\2")
        buf.write(u"\u042d\u042f\5b\62\2\u042e\u042d\3\2\2\2\u042e\u042f")
        buf.write(u"\3\2\2\2\u042f\u0431\3\2\2\2\u0430\u0432\5d\63\2\u0431")
        buf.write(u"\u0430\3\2\2\2\u0431\u0432\3\2\2\2\u0432\u04ec\3\2\2")
        buf.write(u"\2\u0433\u0434\5t;\2\u0434\u0440\7\4\2\2\u0435\u0437")
        buf.write(u"\5*\26\2\u0436\u0435\3\2\2\2\u0436\u0437\3\2\2\2\u0437")
        buf.write(u"\u0438\3\2\2\2\u0438\u043d\5> \2\u0439\u043a\7\6\2\2")
        buf.write(u"\u043a\u043c\5> \2\u043b\u0439\3\2\2\2\u043c\u043f\3")
        buf.write(u"\2\2\2\u043d\u043b\3\2\2\2\u043d\u043e\3\2\2\2\u043e")
        buf.write(u"\u0441\3\2\2\2\u043f\u043d\3\2\2\2\u0440\u0436\3\2\2")
        buf.write(u"\2\u0440\u0441\3\2\2\2\u0441\u044c\3\2\2\2\u0442\u0443")
        buf.write(u"\7x\2\2\u0443\u0444\7\30\2\2\u0444\u0449\5\34\17\2\u0445")
        buf.write(u"\u0446\7\6\2\2\u0446\u0448\5\34\17\2\u0447\u0445\3\2")
        buf.write(u"\2\2\u0448\u044b\3\2\2\2\u0449\u0447\3\2\2\2\u0449\u044a")
        buf.write(u"\3\2\2\2\u044a\u044d\3\2\2\2\u044b\u0449\3\2\2\2\u044c")
        buf.write(u"\u0442\3\2\2\2\u044c\u044d\3\2\2\2\u044d\u044e\3\2\2")
        buf.write(u"\2\u044e\u0450\7\5\2\2\u044f\u0451\5b\62\2\u0450\u044f")
        buf.write(u"\3\2\2\2\u0450\u0451\3\2\2\2\u0451\u0453\3\2\2\2\u0452")
        buf.write(u"\u0454\5d\63\2\u0453\u0452\3\2\2\2\u0453\u0454\3\2\2")
        buf.write(u"\2\u0454\u04ec\3\2\2\2\u0455\u0456\5v<\2\u0456\u0457")
        buf.write(u"\7\b\2\2\u0457\u0458\5> \2\u0458\u04ec\3\2\2\2\u0459")
        buf.write(u"\u0462\7\4\2\2\u045a\u045f\5v<\2\u045b\u045c\7\6\2\2")
        buf.write(u"\u045c\u045e\5v<\2\u045d\u045b\3\2\2\2\u045e\u0461\3")
        buf.write(u"\2\2\2\u045f\u045d\3\2\2\2\u045f\u0460\3\2\2\2\u0460")
        buf.write(u"\u0463\3\2\2\2\u0461\u045f\3\2\2\2\u0462\u045a\3\2\2")
        buf.write(u"\2\u0462\u0463\3\2\2\2\u0463\u0464\3\2\2\2\u0464\u0465")
        buf.write(u"\7\5\2\2\u0465\u0466\7\b\2\2\u0466\u04ec\5> \2\u0467")
        buf.write(u"\u0468\7\4\2\2\u0468\u0469\5\b\5\2\u0469\u046a\7\5\2")
        buf.write(u"\2\u046a\u04ec\3\2\2\2\u046b\u046c\7=\2\2\u046c\u046d")
        buf.write(u"\7\4\2\2\u046d\u046e\5\b\5\2\u046e\u046f\7\5\2\2\u046f")
        buf.write(u"\u04ec\3\2\2\2\u0470\u0471\7\33\2\2\u0471\u0473\5F$\2")
        buf.write(u"\u0472\u0474\5`\61\2\u0473\u0472\3\2\2\2\u0474\u0475")
        buf.write(u"\3\2\2\2\u0475\u0473\3\2\2\2\u0475\u0476\3\2\2\2\u0476")
        buf.write(u"\u0479\3\2\2\2\u0477\u0478\7\67\2\2\u0478\u047a\5> \2")
        buf.write(u"\u0479\u0477\3\2\2\2\u0479\u047a\3\2\2\2\u047a\u047b")
        buf.write(u"\3\2\2\2\u047b\u047c\78\2\2\u047c\u04ec\3\2\2\2\u047d")
        buf.write(u"\u047f\7\33\2\2\u047e\u0480\5`\61\2\u047f\u047e\3\2\2")
        buf.write(u"\2\u0480\u0481\3\2\2\2\u0481\u047f\3\2\2\2\u0481\u0482")
        buf.write(u"\3\2\2\2\u0482\u0485\3\2\2\2\u0483\u0484\7\67\2\2\u0484")
        buf.write(u"\u0486\5> \2\u0485\u0483\3\2\2\2\u0485\u0486\3\2\2\2")
        buf.write(u"\u0486\u0487\3\2\2\2\u0487\u0488\78\2\2\u0488\u04ec\3")
        buf.write(u"\2\2\2\u0489\u048a\7\34\2\2\u048a\u048b\7\4\2\2\u048b")
        buf.write(u"\u048c\5> \2\u048c\u048d\7\23\2\2\u048d\u048e\5Z.\2\u048e")
        buf.write(u"\u048f\7\5\2\2\u048f\u04ec\3\2\2\2\u0490\u0491\7\u00ad")
        buf.write(u"\2\2\u0491\u0492\7\4\2\2\u0492\u0493\5> \2\u0493\u0494")
        buf.write(u"\7\23\2\2\u0494\u0495\5Z.\2\u0495\u0496\7\5\2\2\u0496")
        buf.write(u"\u04ec\3\2\2\2\u0497\u0498\7\22\2\2\u0498\u04a1\7\t\2")
        buf.write(u"\2\u0499\u049e\5> \2\u049a\u049b\7\6\2\2\u049b\u049d")
        buf.write(u"\5> \2\u049c\u049a\3\2\2\2\u049d\u04a0\3\2\2\2\u049e")
        buf.write(u"\u049c\3\2\2\2\u049e\u049f\3\2\2\2\u049f\u04a2\3\2\2")
        buf.write(u"\2\u04a0\u049e\3\2\2\2\u04a1\u0499\3\2\2\2\u04a1\u04a2")
        buf.write(u"\3\2\2\2\u04a2\u04a3\3\2\2\2\u04a3\u04ec\7\n\2\2\u04a4")
        buf.write(u"\u04ec\5v<\2\u04a5\u04ec\7)\2\2\u04a6\u04aa\7*\2\2\u04a7")
        buf.write(u"\u04a8\7\4\2\2\u04a8\u04a9\7\u00d0\2\2\u04a9\u04ab\7")
        buf.write(u"\5\2\2\u04aa\u04a7\3\2\2\2\u04aa\u04ab\3\2\2\2\u04ab")
        buf.write(u"\u04ec\3\2\2\2\u04ac\u04b0\7+\2\2\u04ad\u04ae\7\4\2\2")
        buf.write(u"\u04ae\u04af\7\u00d0\2\2\u04af\u04b1\7\5\2\2\u04b0\u04ad")
        buf.write(u"\3\2\2\2\u04b0\u04b1\3\2\2\2\u04b1\u04ec\3\2\2\2\u04b2")
        buf.write(u"\u04b6\7c\2\2\u04b3\u04b4\7\4\2\2\u04b4\u04b5\7\u00d0")
        buf.write(u"\2\2\u04b5\u04b7\7\5\2\2\u04b6\u04b3\3\2\2\2\u04b6\u04b7")
        buf.write(u"\3\2\2\2\u04b7\u04ec\3\2\2\2\u04b8\u04bc\7d\2\2\u04b9")
        buf.write(u"\u04ba\7\4\2\2\u04ba\u04bb\7\u00d0\2\2\u04bb\u04bd\7")
        buf.write(u"\5\2\2\u04bc\u04b9\3\2\2\2\u04bc\u04bd\3\2\2\2\u04bd")
        buf.write(u"\u04ec\3\2\2\2\u04be\u04ec\7,\2\2\u04bf\u04c0\7\u00a0")
        buf.write(u"\2\2\u04c0\u04c1\7\4\2\2\u04c1\u04c2\5F$\2\u04c2\u04c3")
        buf.write(u"\7F\2\2\u04c3\u04c6\5F$\2\u04c4\u04c5\7D\2\2\u04c5\u04c7")
        buf.write(u"\5F$\2\u04c6\u04c4\3\2\2\2\u04c6\u04c7\3\2\2\2\u04c7")
        buf.write(u"\u04c8\3\2\2\2\u04c8\u04c9\7\5\2\2\u04c9\u04ec\3\2\2")
        buf.write(u"\2\u04ca\u04cb\7o\2\2\u04cb\u04cc\7\4\2\2\u04cc\u04cf")
        buf.write(u"\5F$\2\u04cd\u04ce\7\6\2\2\u04ce\u04d0\5X-\2\u04cf\u04cd")
        buf.write(u"\3\2\2\2\u04cf\u04d0\3\2\2\2\u04d0\u04d1\3\2\2\2\u04d1")
        buf.write(u"\u04d2\7\5\2\2\u04d2\u04ec\3\2\2\2\u04d3\u04d4\7?\2\2")
        buf.write(u"\u04d4\u04d5\7\4\2\2\u04d5\u04d6\5v<\2\u04d6\u04d7\7")
        buf.write(u"F\2\2\u04d7\u04d8\5F$\2\u04d8\u04d9\7\5\2\2\u04d9\u04ec")
        buf.write(u"\3\2\2\2\u04da\u04db\7\4\2\2\u04db\u04dc\5> \2\u04dc")
        buf.write(u"\u04dd\7\5\2\2\u04dd\u04ec\3\2\2\2\u04de\u04df\7M\2\2")
        buf.write(u"\u04df\u04e8\7\4\2\2\u04e0\u04e5\5t;\2\u04e1\u04e2\7")
        buf.write(u"\6\2\2\u04e2\u04e4\5t;\2\u04e3\u04e1\3\2\2\2\u04e4\u04e7")
        buf.write(u"\3\2\2\2\u04e5\u04e3\3\2\2\2\u04e5\u04e6\3\2\2\2\u04e6")
        buf.write(u"\u04e9\3\2\2\2\u04e7\u04e5\3\2\2\2\u04e8\u04e0\3\2\2")
        buf.write(u"\2\u04e8\u04e9\3\2\2\2\u04e9\u04ea\3\2\2\2\u04ea\u04ec")
        buf.write(u"\7\5\2\2\u04eb\u03ff\3\2\2\2\u04eb\u0401\3\2\2\2\u04eb")
        buf.write(u"\u0402\3\2\2\2\u04eb\u0405\3\2\2\2\u04eb\u0407\3\2\2")
        buf.write(u"\2\u04eb\u0408\3\2\2\2\u04eb\u0409\3\2\2\2\u04eb\u040a")
        buf.write(u"\3\2\2\2\u04eb\u040b\3\2\2\2\u04eb\u040c\3\2\2\2\u04eb")
        buf.write(u"\u0413\3\2\2\2\u04eb\u041d\3\2\2\2\u04eb\u0429\3\2\2")
        buf.write(u"\2\u04eb\u0433\3\2\2\2\u04eb\u0455\3\2\2\2\u04eb\u0459")
        buf.write(u"\3\2\2\2\u04eb\u0467\3\2\2\2\u04eb\u046b\3\2\2\2\u04eb")
        buf.write(u"\u0470\3\2\2\2\u04eb\u047d\3\2\2\2\u04eb\u0489\3\2\2")
        buf.write(u"\2\u04eb\u0490\3\2\2\2\u04eb\u0497\3\2\2\2\u04eb\u04a4")
        buf.write(u"\3\2\2\2\u04eb\u04a5\3\2\2\2\u04eb\u04a6\3\2\2\2\u04eb")
        buf.write(u"\u04ac\3\2\2\2\u04eb\u04b2\3\2\2\2\u04eb\u04b8\3\2\2")
        buf.write(u"\2\u04eb\u04be\3\2\2\2\u04eb\u04bf\3\2\2\2\u04eb\u04ca")
        buf.write(u"\3\2\2\2\u04eb\u04d3\3\2\2\2\u04eb\u04da\3\2\2\2\u04eb")
        buf.write(u"\u04de\3\2\2\2\u04ec\u04f7\3\2\2\2\u04ed\u04ee\f\20\2")
        buf.write(u"\2\u04ee\u04ef\7\t\2\2\u04ef\u04f0\5F$\2\u04f0\u04f1")
        buf.write(u"\7\n\2\2\u04f1\u04f6\3\2\2\2\u04f2\u04f3\f\16\2\2\u04f3")
        buf.write(u"\u04f4\7\3\2\2\u04f4\u04f6\5v<\2\u04f5\u04ed\3\2\2\2")
        buf.write(u"\u04f5\u04f2\3\2\2\2\u04f6\u04f9\3\2\2\2\u04f7\u04f5")
        buf.write(u"\3\2\2\2\u04f7\u04f8\3\2\2\2\u04f8I\3\2\2\2\u04f9\u04f7")
        buf.write(u"\3\2\2\2\u04fa\u0501\7\u00cd\2\2\u04fb\u04fe\7\u00ce")
        buf.write(u"\2\2\u04fc\u04fd\7\u00af\2\2\u04fd\u04ff\7\u00cd\2\2")
        buf.write(u"\u04fe\u04fc\3\2\2\2\u04fe\u04ff\3\2\2\2\u04ff\u0501")
        buf.write(u"\3\2\2\2\u0500\u04fa\3\2\2\2\u0500\u04fb\3\2\2\2\u0501")
        buf.write(u"K\3\2\2\2\u0502\u0503\7\u00a7\2\2\u0503\u0504\7\u00c0")
        buf.write(u"\2\2\u0504\u0509\5T+\2\u0505\u0506\7\u00a7\2\2\u0506")
        buf.write(u"\u0507\7\u00c0\2\2\u0507\u0509\5J&\2\u0508\u0502\3\2")
        buf.write(u"\2\2\u0508\u0505\3\2\2\2\u0509M\3\2\2\2\u050a\u050b\t")
        buf.write(u"\16\2\2\u050bO\3\2\2\2\u050c\u050d\t\17\2\2\u050dQ\3")
        buf.write(u"\2\2\2\u050e\u050f\t\20\2\2\u050fS\3\2\2\2\u0510\u0512")
        buf.write(u"\7X\2\2\u0511\u0513\t\f\2\2\u0512\u0511\3\2\2\2\u0512")
        buf.write(u"\u0513\3\2\2\2\u0513\u0514\3\2\2\2\u0514\u0515\5J&\2")
        buf.write(u"\u0515\u0518\5V,\2\u0516\u0517\7\u00aa\2\2\u0517\u0519")
        buf.write(u"\5V,\2\u0518\u0516\3\2\2\2\u0518\u0519\3\2\2\2\u0519")
        buf.write(u"U\3\2\2\2\u051a\u051b\t\21\2\2\u051bW\3\2\2\2\u051c\u051d")
        buf.write(u"\t\22\2\2\u051dY\3\2\2\2\u051e\u051f\b.\1\2\u051f\u0520")
        buf.write(u"\7\22\2\2\u0520\u0521\7\u00c3\2\2\u0521\u0522\5Z.\2\u0522")
        buf.write(u"\u0523\7\u00c5\2\2\u0523\u054e\3\2\2\2\u0524\u0525\7")
        buf.write(u"f\2\2\u0525\u0526\7\u00c3\2\2\u0526\u0527\5Z.\2\u0527")
        buf.write(u"\u0528\7\6\2\2\u0528\u0529\5Z.\2\u0529\u052a\7\u00c5")
        buf.write(u"\2\2\u052a\u054e\3\2\2\2\u052b\u052c\7\u0091\2\2\u052c")
        buf.write(u"\u052d\7\4\2\2\u052d\u052e\5v<\2\u052e\u0535\5Z.\2\u052f")
        buf.write(u"\u0530\7\6\2\2\u0530\u0531\5v<\2\u0531\u0532\5Z.\2\u0532")
        buf.write(u"\u0534\3\2\2\2\u0533\u052f\3\2\2\2\u0534\u0537\3\2\2")
        buf.write(u"\2\u0535\u0533\3\2\2\2\u0535\u0536\3\2\2\2\u0536\u0538")
        buf.write(u"\3\2\2\2\u0537\u0535\3\2\2\2\u0538\u0539\7\5\2\2\u0539")
        buf.write(u"\u054e\3\2\2\2\u053a\u0546\5^\60\2\u053b\u053c\7\4\2")
        buf.write(u"\2\u053c\u0541\5\\/\2\u053d\u053e\7\6\2\2\u053e\u0540")
        buf.write(u"\5\\/\2\u053f\u053d\3\2\2\2\u0540\u0543\3\2\2\2\u0541")
        buf.write(u"\u053f\3\2\2\2\u0541\u0542\3\2\2\2\u0542\u0544\3\2\2")
        buf.write(u"\2\u0543\u0541\3\2\2\2\u0544\u0545\7\5\2\2\u0545\u0547")
        buf.write(u"\3\2\2\2\u0546\u053b\3\2\2\2\u0546\u0547\3\2\2\2\u0547")
        buf.write(u"\u054e\3\2\2\2\u0548\u0549\7X\2\2\u0549\u054a\5V,\2\u054a")
        buf.write(u"\u054b\7\u00aa\2\2\u054b\u054c\5V,\2\u054c\u054e\3\2")
        buf.write(u"\2\2\u054d\u051e\3\2\2\2\u054d\u0524\3\2\2\2\u054d\u052b")
        buf.write(u"\3\2\2\2\u054d\u053a\3\2\2\2\u054d\u0548\3\2\2\2\u054e")
        buf.write(u"\u0553\3\2\2\2\u054f\u0550\f\b\2\2\u0550\u0552\7\22\2")
        buf.write(u"\2\u0551\u054f\3\2\2\2\u0552\u0555\3\2\2\2\u0553\u0551")
        buf.write(u"\3\2\2\2\u0553\u0554\3\2\2\2\u0554[\3\2\2\2\u0555\u0553")
        buf.write(u"\3\2\2\2\u0556\u0559\7\u00d0\2\2\u0557\u0559\5Z.\2\u0558")
        buf.write(u"\u0556\3\2\2\2\u0558\u0557\3\2\2\2\u0559]\3\2\2\2\u055a")
        buf.write(u"\u055f\7\u00d7\2\2\u055b\u055f\7\u00d8\2\2\u055c\u055f")
        buf.write(u"\7\u00d9\2\2\u055d\u055f\5v<\2\u055e\u055a\3\2\2\2\u055e")
        buf.write(u"\u055b\3\2\2\2\u055e\u055c\3\2\2\2\u055e\u055d\3\2\2")
        buf.write(u"\2\u055f_\3\2\2\2\u0560\u0561\7\u00ba\2\2\u0561\u0562")
        buf.write(u"\5> \2\u0562\u0563\7\u00a6\2\2\u0563\u0564\5> \2\u0564")
        buf.write(u"a\3\2\2\2\u0565\u0566\7A\2\2\u0566\u0567\7\4\2\2\u0567")
        buf.write(u"\u0568\7\u00bb\2\2\u0568\u0569\5@!\2\u0569\u056a\7\5")
        buf.write(u"\2\2\u056ac\3\2\2\2\u056b\u056c\7|\2\2\u056c\u0577\7")
        buf.write(u"\4\2\2\u056d\u056e\7}\2\2\u056e\u056f\7\30\2\2\u056f")
        buf.write(u"\u0574\5> \2\u0570\u0571\7\6\2\2\u0571\u0573\5> \2\u0572")
        buf.write(u"\u0570\3\2\2\2\u0573\u0576\3\2\2\2\u0574\u0572\3\2\2")
        buf.write(u"\2\u0574\u0575\3\2\2\2\u0575\u0578\3\2\2\2\u0576\u0574")
        buf.write(u"\3\2\2\2\u0577\u056d\3\2\2\2\u0577\u0578\3\2\2\2\u0578")
        buf.write(u"\u0583\3\2\2\2\u0579\u057a\7x\2\2\u057a\u057b\7\30\2")
        buf.write(u"\2\u057b\u0580\5\34\17\2\u057c\u057d\7\6\2\2\u057d\u057f")
        buf.write(u"\5\34\17\2\u057e\u057c\3\2\2\2\u057f\u0582\3\2\2\2\u0580")
        buf.write(u"\u057e\3\2\2\2\u0580\u0581\3\2\2\2\u0581\u0584\3\2\2")
        buf.write(u"\2\u0582\u0580\3\2\2\2\u0583\u0579\3\2\2\2\u0583\u0584")
        buf.write(u"\3\2\2\2\u0584\u0586\3\2\2\2\u0585\u0587\5f\64\2\u0586")
        buf.write(u"\u0585\3\2\2\2\u0586\u0587\3\2\2\2\u0587\u0588\3\2\2")
        buf.write(u"\2\u0588\u0589\7\5\2\2\u0589e\3\2\2\2\u058a\u058b\7\u0085")
        buf.write(u"\2\2\u058b\u059b\5h\65\2\u058c\u058d\7\u0092\2\2\u058d")
        buf.write(u"\u059b\5h\65\2\u058e\u058f\7\u0085\2\2\u058f\u0590\7")
        buf.write(u"\27\2\2\u0590\u0591\5h\65\2\u0591\u0592\7\20\2\2\u0592")
        buf.write(u"\u0593\5h\65\2\u0593\u059b\3\2\2\2\u0594\u0595\7\u0092")
        buf.write(u"\2\2\u0595\u0596\7\27\2\2\u0596\u0597\5h\65\2\u0597\u0598")
        buf.write(u"\7\20\2\2\u0598\u0599\5h\65\2\u0599\u059b\3\2\2\2\u059a")
        buf.write(u"\u058a\3\2\2\2\u059a\u058c\3\2\2\2\u059a\u058e\3\2\2")
        buf.write(u"\2\u059a\u0594\3\2\2\2\u059bg\3\2\2\2\u059c\u059d\7\u00b0")
        buf.write(u"\2\2\u059d\u05a6\7\u0080\2\2\u059e\u059f\7\u00b0\2\2")
        buf.write(u"\u059f\u05a6\7C\2\2\u05a0\u05a1\7(\2\2\u05a1\u05a6\7")
        buf.write(u"\u0091\2\2\u05a2\u05a3\5> \2\u05a3\u05a4\t\23\2\2\u05a4")
        buf.write(u"\u05a6\3\2\2\2\u05a5\u059c\3\2\2\2\u05a5\u059e\3\2\2")
        buf.write(u"\2\u05a5\u05a0\3\2\2\2\u05a5\u05a2\3\2\2\2\u05a6i\3\2")
        buf.write(u"\2\2\u05a7\u05a8\7E\2\2\u05a8\u05ac\t\24\2\2\u05a9\u05aa")
        buf.write(u"\7\u00ae\2\2\u05aa\u05ac\t\25\2\2\u05ab\u05a7\3\2\2\2")
        buf.write(u"\u05ab\u05a9\3\2\2\2\u05ack\3\2\2\2\u05ad\u05ae\7[\2")
        buf.write(u"\2\u05ae\u05af\7`\2\2\u05af\u05b3\5n8\2\u05b0\u05b1\7")
        buf.write(u"\u0086\2\2\u05b1\u05b3\t\26\2\2\u05b2\u05ad\3\2\2\2\u05b2")
        buf.write(u"\u05b0\3\2\2\2\u05b3m\3\2\2\2\u05b4\u05b5\7\u0086\2\2")
        buf.write(u"\u05b5\u05bc\7\u00b1\2\2\u05b6\u05b7\7\u0086\2\2\u05b7")
        buf.write(u"\u05bc\7#\2\2\u05b8\u05b9\7\u0089\2\2\u05b9\u05bc\7\u0086")
        buf.write(u"\2\2\u05ba\u05bc\7\u0097\2\2\u05bb\u05b4\3\2\2\2\u05bb")
        buf.write(u"\u05b6\3\2\2\2\u05bb\u05b8\3\2\2\2\u05bb\u05ba\3\2\2")
        buf.write(u"\2\u05bco\3\2\2\2\u05bd\u05c3\5> \2\u05be\u05bf\5v<\2")
        buf.write(u"\u05bf\u05c0\7\13\2\2\u05c0\u05c1\5> \2\u05c1\u05c3\3")
        buf.write(u"\2\2\2\u05c2\u05bd\3\2\2\2\u05c2\u05be\3\2\2\2\u05c3")
        buf.write(u"q\3\2\2\2\u05c4\u05c9\7\u0096\2\2\u05c5\u05c9\7\61\2")
        buf.write(u"\2\u05c6\u05c9\7U\2\2\u05c7\u05c9\5v<\2\u05c8\u05c4\3")
        buf.write(u"\2\2\2\u05c8\u05c5\3\2\2\2\u05c8\u05c6\3\2\2\2\u05c8")
        buf.write(u"\u05c7\3\2\2\2\u05c9s\3\2\2\2\u05ca\u05cf\5v<\2\u05cb")
        buf.write(u"\u05cc\7\3\2\2\u05cc\u05ce\5v<\2\u05cd\u05cb\3\2\2\2")
        buf.write(u"\u05ce\u05d1\3\2\2\2\u05cf\u05cd\3\2\2\2\u05cf\u05d0")
        buf.write(u"\3\2\2\2\u05d0u\3\2\2\2\u05d1\u05cf\3\2\2\2\u05d2\u05d8")
        buf.write(u"\7\u00d3\2\2\u05d3\u05d8\7\u00d5\2\2\u05d4\u05d8\5z>")
        buf.write(u"\2\u05d5\u05d8\7\u00d6\2\2\u05d6\u05d8\7\u00d4\2\2\u05d7")
        buf.write(u"\u05d2\3\2\2\2\u05d7\u05d3\3\2\2\2\u05d7\u05d4\3\2\2")
        buf.write(u"\2\u05d7\u05d5\3\2\2\2\u05d7\u05d6\3\2\2\2\u05d8w\3\2")
        buf.write(u"\2\2\u05d9\u05dd\7\u00d1\2\2\u05da\u05dd\7\u00d2\2\2")
        buf.write(u"\u05db\u05dd\7\u00d0\2\2\u05dc\u05d9\3\2\2\2\u05dc\u05da")
        buf.write(u"\3\2\2\2\u05dc\u05db\3\2\2\2\u05ddy\3\2\2\2\u05de\u05df")
        buf.write(u"\t\27\2\2\u05df{\3\2\2\2\u00bd\u008f\u0094\u009a\u009e")
        buf.write(u"\u00ac\u00b0\u00b4\u00b8\u00c0\u00c4\u00c7\u00ce\u00d7")
        buf.write(u"\u00dd\u00e1\u00e7\u00ee\u00f7\u011a\u0125\u0130\u0133")
        buf.write(u"\u013d\u0142\u0146\u014e\u0154\u015b\u0160\u0164\u016e")
        buf.write(u"\u0171\u0175\u0178\u0180\u0185\u0194\u019a\u019c\u01a2")
        buf.write(u"\u01a8\u01aa\u01b0\u01d9\u01dc\u01e0\u01e4\u01ec\u01f5")
        buf.write(u"\u01f8\u01fc\u020e\u0211\u0219\u021c\u0222\u0229\u022e")
        buf.write(u"\u0234\u023a\u0242\u0253\u0256\u025a\u0262\u0268\u026b")
        buf.write(u"\u026d\u0279\u0280\u0284\u0288\u028c\u0293\u029c\u029f")
        buf.write(u"\u02a3\u02a8\u02ac\u02af\u02b6\u02c1\u02c4\u02ce\u02d1")
        buf.write(u"\u02dc\u02e1\u02e9\u02ec\u02f0\u02f8\u02fb\u02ff\u0303")
        buf.write(u"\u030e\u0311\u0318\u032b\u032f\u0333\u0337\u033b\u033f")
        buf.write(u"\u0341\u034c\u0351\u035a\u0360\u0364\u0366\u036e\u037f")
        buf.write(u"\u0385\u0390\u0398\u03a0\u03a2\u03a7\u03b3\u03bb\u03c4")
        buf.write(u"\u03ca\u03d2\u03d8\u03dc\u03e1\u03e6\u03ec\u03fa\u03fc")
        buf.write(u"\u0419\u0424\u042e\u0431\u0436\u043d\u0440\u0449\u044c")
        buf.write(u"\u0450\u0453\u045f\u0462\u0475\u0479\u0481\u0485\u049e")
        buf.write(u"\u04a1\u04aa\u04b0\u04b6\u04bc\u04c6\u04cf\u04e5\u04e8")
        buf.write(u"\u04eb\u04f5\u04f7\u04fe\u0500\u0508\u0512\u0518\u0535")
        buf.write(u"\u0541\u0546\u054d\u0553\u0558\u055e\u0574\u0577\u0580")
        buf.write(u"\u0583\u0586\u059a\u05a5\u05ab\u05b2\u05bb\u05c2\u05c8")
        buf.write(u"\u05cf\u05d7\u05dc")
        return buf.getvalue()


class SqlBaseParser ( Parser ):

    grammarFileName = "SqlBase.g4"

    atn = ATNDeserializer().deserialize(serializedATN())

    decisionsToDFA = [ DFA(ds, i) for i, ds in enumerate(atn.decisionToState) ]

    sharedContextCache = PredictionContextCache()

    literalNames = [ u"<INVALID>", u"'.'", u"'('", u"')'", u"','", u"'?'", 
                     u"'->'", u"'['", u"']'", u"'=>'", u"'ADD'", u"'ALL'", 
                     u"'ALTER'", u"'ANALYZE'", u"'AND'", u"'ANY'", u"'ARRAY'", 
                     u"'AS'", u"'ASC'", u"'AT'", u"'BERNOULLI'", u"'BETWEEN'", 
                     u"'BY'", u"'CALL'", u"'CASCADE'", u"'CASE'", u"'CAST'", 
                     u"'CATALOGS'", u"'COALESCE'", u"'COLUMN'", u"'COLUMNS'", 
                     u"'COMMENT'", u"'COMMIT'", u"'COMMITTED'", u"'CONSTRAINT'", 
                     u"'CREATE'", u"'CROSS'", u"'CUBE'", u"'CURRENT'", u"'CURRENT_DATE'", 
                     u"'CURRENT_TIME'", u"'CURRENT_TIMESTAMP'", u"'CURRENT_USER'", 
                     u"'DATA'", u"'DATE'", u"'DAY'", u"'DEALLOCATE'", u"'DELETE'", 
                     u"'DESC'", u"'DESCRIBE'", u"'DISTINCT'", u"'DISTRIBUTED'", 
                     u"'DROP'", u"'ELSE'", u"'END'", u"'ESCAPE'", u"'EXCEPT'", 
                     u"'EXCLUDING'", u"'EXECUTE'", u"'EXISTS'", u"'EXPLAIN'", 
                     u"'EXTRACT'", u"'FALSE'", u"'FILTER'", u"'FIRST'", 
                     u"'FOLLOWING'", u"'FOR'", u"'FORMAT'", u"'FROM'", u"'FULL'", 
                     u"'FUNCTIONS'", u"'GRANT'", u"'GRANTS'", u"'GRAPHVIZ'", 
                     u"'GROUP'", u"'GROUPING'", u"'HAVING'", u"'HOUR'", 
                     u"'IF'", u"'IN'", u"'INCLUDING'", u"'INNER'", u"'INPUT'", 
                     u"'INSERT'", u"'INTEGER'", u"'INTERSECT'", u"'INTERVAL'", 
                     u"'INTO'", u"'IS'", u"'ISOLATION'", u"'JOIN'", u"'LAST'", 
                     u"'LATERAL'", u"'LEFT'", u"'LEVEL'", u"'LIKE'", u"'LIMIT'", 
                     u"'LOCALTIME'", u"'LOCALTIMESTAMP'", u"'LOGICAL'", 
                     u"'MAP'", u"'MINUTE'", u"'MONTH'", u"'NATURAL'", u"'NFC'", 
                     u"'NFD'", u"'NFKC'", u"'NFKD'", u"'NO'", u"'NORMALIZE'", 
                     u"'NOT'", u"'NULL'", u"'NULLIF'", u"'NULLS'", u"'ON'", 
                     u"'ONLY'", u"'OPTION'", u"'OR'", u"'ORDER'", u"'ORDINALITY'", 
                     u"'OUTER'", u"'OUTPUT'", u"'OVER'", u"'PARTITION'", 
                     u"'PARTITIONS'", u"'POSITION'", u"'PRECEDING'", u"'PREPARE'", 
                     u"'PRIVILEGES'", u"'PROPERTIES'", u"'PUBLIC'", u"'RANGE'", 
                     u"'READ'", u"'RECURSIVE'", u"'RENAME'", u"'REPEATABLE'", 
                     u"'REPLACE'", u"'RESET'", u"'RESTRICT'", u"'REVOKE'", 
                     u"'RIGHT'", u"'ROLLBACK'", u"'ROLLUP'", u"'ROW'", u"'ROWS'", 
                     u"'SCHEMA'", u"'SCHEMAS'", u"'SECOND'", u"'SELECT'", 
                     u"'SERIALIZABLE'", u"'SESSION'", u"'SET'", u"'SETS'", 
                     u"'SHOW'", u"'SMALLINT'", u"'SOME'", u"'START'", u"'STATS'", 
                     u"'SUBSTRING'", u"'SYSTEM'", u"'TABLE'", u"'TABLES'", 
                     u"'TABLESAMPLE'", u"'TEXT'", u"'THEN'", u"'TIME'", 
                     u"'TIMESTAMP'", u"'TINYINT'", u"'TO'", u"'TRANSACTION'", 
                     u"'TRUE'", u"'TRY_CAST'", u"'TYPE'", u"'UESCAPE'", 
                     u"'UNBOUNDED'", u"'UNCOMMITTED'", u"'UNION'", u"'UNNEST'", 
                     u"'USE'", u"'USING'", u"'VALIDATE'", u"'VALUES'", u"'VERBOSE'", 
                     u"'VIEW'", u"'WHEN'", u"'WHERE'", u"'WITH'", u"'WORK'", 
                     u"'WRITE'", u"'YEAR'", u"'ZONE'", u"'='", u"<INVALID>", 
                     u"'<'", u"'<='", u"'>'", u"'>='", u"'+'", u"'-'", u"'*'", 
                     u"'/'", u"'%'", u"'||'" ]

    symbolicNames = [ u"<INVALID>", u"<INVALID>", u"<INVALID>", u"<INVALID>", 
                      u"<INVALID>", u"<INVALID>", u"<INVALID>", u"<INVALID>", 
                      u"<INVALID>", u"<INVALID>", u"ADD", u"ALL", u"ALTER", 
                      u"ANALYZE", u"AND", u"ANY", u"ARRAY", u"AS", u"ASC", 
                      u"AT", u"BERNOULLI", u"BETWEEN", u"BY", u"CALL", u"CASCADE", 
                      u"CASE", u"CAST", u"CATALOGS", u"COALESCE", u"COLUMN", 
                      u"COLUMNS", u"COMMENT", u"COMMIT", u"COMMITTED", u"CONSTRAINT", 
                      u"CREATE", u"CROSS", u"CUBE", u"CURRENT", u"CURRENT_DATE", 
                      u"CURRENT_TIME", u"CURRENT_TIMESTAMP", u"CURRENT_USER", 
                      u"DATA", u"DATE", u"DAY", u"DEALLOCATE", u"DELETE", 
                      u"DESC", u"DESCRIBE", u"DISTINCT", u"DISTRIBUTED", 
                      u"DROP", u"ELSE", u"END", u"ESCAPE", u"EXCEPT", u"EXCLUDING", 
                      u"EXECUTE", u"EXISTS", u"EXPLAIN", u"EXTRACT", u"FALSE", 
                      u"FILTER", u"FIRST", u"FOLLOWING", u"FOR", u"FORMAT", 
                      u"FROM", u"FULL", u"FUNCTIONS", u"GRANT", u"GRANTS", 
                      u"GRAPHVIZ", u"GROUP", u"GROUPING", u"HAVING", u"HOUR", 
                      u"IF", u"IN", u"INCLUDING", u"INNER", u"INPUT", u"INSERT", 
                      u"INTEGER", u"INTERSECT", u"INTERVAL", u"INTO", u"IS", 
                      u"ISOLATION", u"JOIN", u"LAST", u"LATERAL", u"LEFT", 
                      u"LEVEL", u"LIKE", u"LIMIT", u"LOCALTIME", u"LOCALTIMESTAMP", 
                      u"LOGICAL", u"MAP", u"MINUTE", u"MONTH", u"NATURAL", 
                      u"NFC", u"NFD", u"NFKC", u"NFKD", u"NO", u"NORMALIZE", 
                      u"NOT", u"NULL", u"NULLIF", u"NULLS", u"ON", u"ONLY", 
                      u"OPTION", u"OR", u"ORDER", u"ORDINALITY", u"OUTER", 
                      u"OUTPUT", u"OVER", u"PARTITION", u"PARTITIONS", u"POSITION", 
                      u"PRECEDING", u"PREPARE", u"PRIVILEGES", u"PROPERTIES", 
                      u"PUBLIC", u"RANGE", u"READ", u"RECURSIVE", u"RENAME", 
                      u"REPEATABLE", u"REPLACE", u"RESET", u"RESTRICT", 
                      u"REVOKE", u"RIGHT", u"ROLLBACK", u"ROLLUP", u"ROW", 
                      u"ROWS", u"SCHEMA", u"SCHEMAS", u"SECOND", u"SELECT", 
                      u"SERIALIZABLE", u"SESSION", u"SET", u"SETS", u"SHOW", 
                      u"SMALLINT", u"SOME", u"START", u"STATS", u"SUBSTRING", 
                      u"SYSTEM", u"TABLE", u"TABLES", u"TABLESAMPLE", u"TEXT", 
                      u"THEN", u"TIME", u"TIMESTAMP", u"TINYINT", u"TO", 
                      u"TRANSACTION", u"TRUE", u"TRY_CAST", u"TYPE", u"UESCAPE", 
                      u"UNBOUNDED", u"UNCOMMITTED", u"UNION", u"UNNEST", 
                      u"USE", u"USING", u"VALIDATE", u"VALUES", u"VERBOSE", 
                      u"VIEW", u"WHEN", u"WHERE", u"WITH", u"WORK", u"WRITE", 
                      u"YEAR", u"ZONE", u"EQ", u"NEQ", u"LT", u"LTE", u"GT", 
                      u"GTE", u"PLUS", u"MINUS", u"ASTERISK", u"SLASH", 
                      u"PERCENT", u"CONCAT", u"STRING", u"UNICODE_STRING", 
                      u"BINARY_LITERAL", u"INTEGER_VALUE", u"DECIMAL_VALUE", 
                      u"DOUBLE_VALUE", u"IDENTIFIER", u"DIGIT_IDENTIFIER", 
                      u"QUOTED_IDENTIFIER", u"BACKQUOTED_IDENTIFIER", u"TIME_WITH_TIME_ZONE", 
                      u"TIMESTAMP_WITH_TIME_ZONE", u"DOUBLE_PRECISION", 
                      u"SIMPLE_COMMENT", u"BRACKETED_COMMENT", u"WS", u"UNRECOGNIZED", 
                      u"DELIMITER" ]

    RULE_singleStatement = 0
    RULE_singleExpression = 1
    RULE_statement = 2
    RULE_query = 3
    RULE_with = 4
    RULE_tableElement = 5
    RULE_columnDefinition = 6
    RULE_likeClause = 7
    RULE_properties = 8
    RULE_property = 9
    RULE_queryNoWith = 10
    RULE_queryTerm = 11
    RULE_queryPrimary = 12
    RULE_sortItem = 13
    RULE_querySpecification = 14
    RULE_groupBy = 15
    RULE_groupingElement = 16
    RULE_groupingExpressions = 17
    RULE_groupingSet = 18
    RULE_namedQuery = 19
    RULE_setQuantifier = 20
    RULE_selectItem = 21
    RULE_relation = 22
    RULE_joinType = 23
    RULE_joinCriteria = 24
    RULE_sampledRelation = 25
    RULE_sampleType = 26
    RULE_aliasedRelation = 27
    RULE_columnAliases = 28
    RULE_relationPrimary = 29
    RULE_expression = 30
    RULE_booleanExpression = 31
    RULE_predicated = 32
    RULE_predicate = 33
    RULE_valueExpression = 34
    RULE_primaryExpression = 35
    RULE_string = 36
    RULE_timeZoneSpecifier = 37
    RULE_comparisonOperator = 38
    RULE_comparisonQuantifier = 39
    RULE_booleanValue = 40
    RULE_interval = 41
    RULE_intervalField = 42
    RULE_normalForm = 43
    RULE_type = 44
    RULE_typeParameter = 45
    RULE_baseType = 46
    RULE_whenClause = 47
    RULE_filter = 48
    RULE_over = 49
    RULE_windowFrame = 50
    RULE_frameBound = 51
    RULE_explainOption = 52
    RULE_transactionMode = 53
    RULE_levelOfIsolation = 54
    RULE_callArgument = 55
    RULE_privilege = 56
    RULE_qualifiedName = 57
    RULE_identifier = 58
    RULE_number = 59
    RULE_nonReserved = 60

    ruleNames =  [ u"singleStatement", u"singleExpression", u"statement", 
                   u"query", u"with", u"tableElement", u"columnDefinition", 
                   u"likeClause", u"properties", u"property", u"queryNoWith", 
                   u"queryTerm", u"queryPrimary", u"sortItem", u"querySpecification", 
                   u"groupBy", u"groupingElement", u"groupingExpressions", 
                   u"groupingSet", u"namedQuery", u"setQuantifier", u"selectItem", 
                   u"relation", u"joinType", u"joinCriteria", u"sampledRelation", 
                   u"sampleType", u"aliasedRelation", u"columnAliases", 
                   u"relationPrimary", u"expression", u"booleanExpression", 
                   u"predicated", u"predicate", u"valueExpression", u"primaryExpression", 
                   u"string", u"timeZoneSpecifier", u"comparisonOperator", 
                   u"comparisonQuantifier", u"booleanValue", u"interval", 
                   u"intervalField", u"normalForm", u"type", u"typeParameter", 
                   u"baseType", u"whenClause", u"filter", u"over", u"windowFrame", 
                   u"frameBound", u"explainOption", u"transactionMode", 
                   u"levelOfIsolation", u"callArgument", u"privilege", u"qualifiedName", 
                   u"identifier", u"number", u"nonReserved" ]

    EOF = Token.EOF
    T__0=1
    T__1=2
    T__2=3
    T__3=4
    T__4=5
    T__5=6
    T__6=7
    T__7=8
    T__8=9
    ADD=10
    ALL=11
    ALTER=12
    ANALYZE=13
    AND=14
    ANY=15
    ARRAY=16
    AS=17
    ASC=18
    AT=19
    BERNOULLI=20
    BETWEEN=21
    BY=22
    CALL=23
    CASCADE=24
    CASE=25
    CAST=26
    CATALOGS=27
    COALESCE=28
    COLUMN=29
    COLUMNS=30
    COMMENT=31
    COMMIT=32
    COMMITTED=33
    CONSTRAINT=34
    CREATE=35
    CROSS=36
    CUBE=37
    CURRENT=38
    CURRENT_DATE=39
    CURRENT_TIME=40
    CURRENT_TIMESTAMP=41
    CURRENT_USER=42
    DATA=43
    DATE=44
    DAY=45
    DEALLOCATE=46
    DELETE=47
    DESC=48
    DESCRIBE=49
    DISTINCT=50
    DISTRIBUTED=51
    DROP=52
    ELSE=53
    END=54
    ESCAPE=55
    EXCEPT=56
    EXCLUDING=57
    EXECUTE=58
    EXISTS=59
    EXPLAIN=60
    EXTRACT=61
    FALSE=62
    FILTER=63
    FIRST=64
    FOLLOWING=65
    FOR=66
    FORMAT=67
    FROM=68
    FULL=69
    FUNCTIONS=70
    GRANT=71
    GRANTS=72
    GRAPHVIZ=73
    GROUP=74
    GROUPING=75
    HAVING=76
    HOUR=77
    IF=78
    IN=79
    INCLUDING=80
    INNER=81
    INPUT=82
    INSERT=83
    INTEGER=84
    INTERSECT=85
    INTERVAL=86
    INTO=87
    IS=88
    ISOLATION=89
    JOIN=90
    LAST=91
    LATERAL=92
    LEFT=93
    LEVEL=94
    LIKE=95
    LIMIT=96
    LOCALTIME=97
    LOCALTIMESTAMP=98
    LOGICAL=99
    MAP=100
    MINUTE=101
    MONTH=102
    NATURAL=103
    NFC=104
    NFD=105
    NFKC=106
    NFKD=107
    NO=108
    NORMALIZE=109
    NOT=110
    NULL=111
    NULLIF=112
    NULLS=113
    ON=114
    ONLY=115
    OPTION=116
    OR=117
    ORDER=118
    ORDINALITY=119
    OUTER=120
    OUTPUT=121
    OVER=122
    PARTITION=123
    PARTITIONS=124
    POSITION=125
    PRECEDING=126
    PREPARE=127
    PRIVILEGES=128
    PROPERTIES=129
    PUBLIC=130
    RANGE=131
    READ=132
    RECURSIVE=133
    RENAME=134
    REPEATABLE=135
    REPLACE=136
    RESET=137
    RESTRICT=138
    REVOKE=139
    RIGHT=140
    ROLLBACK=141
    ROLLUP=142
    ROW=143
    ROWS=144
    SCHEMA=145
    SCHEMAS=146
    SECOND=147
    SELECT=148
    SERIALIZABLE=149
    SESSION=150
    SET=151
    SETS=152
    SHOW=153
    SMALLINT=154
    SOME=155
    START=156
    STATS=157
    SUBSTRING=158
    SYSTEM=159
    TABLE=160
    TABLES=161
    TABLESAMPLE=162
    TEXT=163
    THEN=164
    TIME=165
    TIMESTAMP=166
    TINYINT=167
    TO=168
    TRANSACTION=169
    TRUE=170
    TRY_CAST=171
    TYPE=172
    UESCAPE=173
    UNBOUNDED=174
    UNCOMMITTED=175
    UNION=176
    UNNEST=177
    USE=178
    USING=179
    VALIDATE=180
    VALUES=181
    VERBOSE=182
    VIEW=183
    WHEN=184
    WHERE=185
    WITH=186
    WORK=187
    WRITE=188
    YEAR=189
    ZONE=190
    EQ=191
    NEQ=192
    LT=193
    LTE=194
    GT=195
    GTE=196
    PLUS=197
    MINUS=198
    ASTERISK=199
    SLASH=200
    PERCENT=201
    CONCAT=202
    STRING=203
    UNICODE_STRING=204
    BINARY_LITERAL=205
    INTEGER_VALUE=206
    DECIMAL_VALUE=207
    DOUBLE_VALUE=208
    IDENTIFIER=209
    DIGIT_IDENTIFIER=210
    QUOTED_IDENTIFIER=211
    BACKQUOTED_IDENTIFIER=212
    TIME_WITH_TIME_ZONE=213
    TIMESTAMP_WITH_TIME_ZONE=214
    DOUBLE_PRECISION=215
    SIMPLE_COMMENT=216
    BRACKETED_COMMENT=217
    WS=218
    UNRECOGNIZED=219
    DELIMITER=220

    def __init__(self, input, output=sys.stdout):
        super(SqlBaseParser, self).__init__(input, output=output)
        self.checkVersion("4.7.1")
        self._interp = ParserATNSimulator(self, self.atn, self.decisionsToDFA, self.sharedContextCache)
        self._predicates = None



    class SingleStatementContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.SingleStatementContext, self).__init__(parent, invokingState)
            self.parser = parser

        def statement(self):
            return self.getTypedRuleContext(SqlBaseParser.StatementContext,0)


        def EOF(self):
            return self.getToken(SqlBaseParser.EOF, 0)

        def getRuleIndex(self):
            return SqlBaseParser.RULE_singleStatement

        def enterRule(self, listener):
            if hasattr(listener, "enterSingleStatement"):
                listener.enterSingleStatement(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitSingleStatement"):
                listener.exitSingleStatement(self)




    def singleStatement(self):

        localctx = SqlBaseParser.SingleStatementContext(self, self._ctx, self.state)
        self.enterRule(localctx, 0, self.RULE_singleStatement)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 122
            self.statement()
            self.state = 123
            self.match(SqlBaseParser.EOF)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class SingleExpressionContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.SingleExpressionContext, self).__init__(parent, invokingState)
            self.parser = parser

        def expression(self):
            return self.getTypedRuleContext(SqlBaseParser.ExpressionContext,0)


        def EOF(self):
            return self.getToken(SqlBaseParser.EOF, 0)

        def getRuleIndex(self):
            return SqlBaseParser.RULE_singleExpression

        def enterRule(self, listener):
            if hasattr(listener, "enterSingleExpression"):
                listener.enterSingleExpression(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitSingleExpression"):
                listener.exitSingleExpression(self)




    def singleExpression(self):

        localctx = SqlBaseParser.SingleExpressionContext(self, self._ctx, self.state)
        self.enterRule(localctx, 2, self.RULE_singleExpression)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 125
            self.expression()
            self.state = 126
            self.match(SqlBaseParser.EOF)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class StatementContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.StatementContext, self).__init__(parent, invokingState)
            self.parser = parser


        def getRuleIndex(self):
            return SqlBaseParser.RULE_statement

     
        def copyFrom(self, ctx):
            super(SqlBaseParser.StatementContext, self).copyFrom(ctx)



    class ExplainContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.ExplainContext, self).__init__(parser)
            self.copyFrom(ctx)

        def EXPLAIN(self):
            return self.getToken(SqlBaseParser.EXPLAIN, 0)
        def statement(self):
            return self.getTypedRuleContext(SqlBaseParser.StatementContext,0)

        def ANALYZE(self):
            return self.getToken(SqlBaseParser.ANALYZE, 0)
        def VERBOSE(self):
            return self.getToken(SqlBaseParser.VERBOSE, 0)
        def explainOption(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.ExplainOptionContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.ExplainOptionContext,i)


        def enterRule(self, listener):
            if hasattr(listener, "enterExplain"):
                listener.enterExplain(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitExplain"):
                listener.exitExplain(self)


    class PrepareContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.PrepareContext, self).__init__(parser)
            self.copyFrom(ctx)

        def PREPARE(self):
            return self.getToken(SqlBaseParser.PREPARE, 0)
        def identifier(self):
            return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,0)

        def FROM(self):
            return self.getToken(SqlBaseParser.FROM, 0)
        def statement(self):
            return self.getTypedRuleContext(SqlBaseParser.StatementContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterPrepare"):
                listener.enterPrepare(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitPrepare"):
                listener.exitPrepare(self)


    class CreateTableContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.CreateTableContext, self).__init__(parser)
            self.copyFrom(ctx)

        def CREATE(self):
            return self.getToken(SqlBaseParser.CREATE, 0)
        def TABLE(self):
            return self.getToken(SqlBaseParser.TABLE, 0)
        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)

        def tableElement(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.TableElementContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.TableElementContext,i)

        def IF(self):
            return self.getToken(SqlBaseParser.IF, 0)
        def NOT(self):
            return self.getToken(SqlBaseParser.NOT, 0)
        def EXISTS(self):
            return self.getToken(SqlBaseParser.EXISTS, 0)
        def COMMENT(self):
            return self.getToken(SqlBaseParser.COMMENT, 0)
        def string(self):
            return self.getTypedRuleContext(SqlBaseParser.StringContext,0)

        def WITH(self):
            return self.getToken(SqlBaseParser.WITH, 0)
        def properties(self):
            return self.getTypedRuleContext(SqlBaseParser.PropertiesContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterCreateTable"):
                listener.enterCreateTable(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitCreateTable"):
                listener.exitCreateTable(self)


    class StartTransactionContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.StartTransactionContext, self).__init__(parser)
            self.copyFrom(ctx)

        def START(self):
            return self.getToken(SqlBaseParser.START, 0)
        def TRANSACTION(self):
            return self.getToken(SqlBaseParser.TRANSACTION, 0)
        def transactionMode(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.TransactionModeContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.TransactionModeContext,i)


        def enterRule(self, listener):
            if hasattr(listener, "enterStartTransaction"):
                listener.enterStartTransaction(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitStartTransaction"):
                listener.exitStartTransaction(self)


    class CreateTableAsSelectContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.CreateTableAsSelectContext, self).__init__(parser)
            self.copyFrom(ctx)

        def CREATE(self):
            return self.getToken(SqlBaseParser.CREATE, 0)
        def TABLE(self):
            return self.getToken(SqlBaseParser.TABLE, 0)
        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)

        def AS(self):
            return self.getToken(SqlBaseParser.AS, 0)
        def query(self):
            return self.getTypedRuleContext(SqlBaseParser.QueryContext,0)

        def IF(self):
            return self.getToken(SqlBaseParser.IF, 0)
        def NOT(self):
            return self.getToken(SqlBaseParser.NOT, 0)
        def EXISTS(self):
            return self.getToken(SqlBaseParser.EXISTS, 0)
        def columnAliases(self):
            return self.getTypedRuleContext(SqlBaseParser.ColumnAliasesContext,0)

        def COMMENT(self):
            return self.getToken(SqlBaseParser.COMMENT, 0)
        def string(self):
            return self.getTypedRuleContext(SqlBaseParser.StringContext,0)

        def WITH(self, i=None):
            if i is None:
                return self.getTokens(SqlBaseParser.WITH)
            else:
                return self.getToken(SqlBaseParser.WITH, i)
        def properties(self):
            return self.getTypedRuleContext(SqlBaseParser.PropertiesContext,0)

        def DATA(self):
            return self.getToken(SqlBaseParser.DATA, 0)
        def NO(self):
            return self.getToken(SqlBaseParser.NO, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterCreateTableAsSelect"):
                listener.enterCreateTableAsSelect(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitCreateTableAsSelect"):
                listener.exitCreateTableAsSelect(self)


    class UseContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.UseContext, self).__init__(parser)
            self.schema = None # IdentifierContext
            self.catalog = None # IdentifierContext
            self.copyFrom(ctx)

        def USE(self):
            return self.getToken(SqlBaseParser.USE, 0)
        def identifier(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.IdentifierContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,i)


        def enterRule(self, listener):
            if hasattr(listener, "enterUse"):
                listener.enterUse(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitUse"):
                listener.exitUse(self)


    class ShowStatsContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.ShowStatsContext, self).__init__(parser)
            self.copyFrom(ctx)

        def SHOW(self):
            return self.getToken(SqlBaseParser.SHOW, 0)
        def STATS(self):
            return self.getToken(SqlBaseParser.STATS, 0)
        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)

        def FOR(self):
            return self.getToken(SqlBaseParser.FOR, 0)
        def ON(self):
            return self.getToken(SqlBaseParser.ON, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterShowStats"):
                listener.enterShowStats(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitShowStats"):
                listener.exitShowStats(self)


    class DeallocateContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.DeallocateContext, self).__init__(parser)
            self.copyFrom(ctx)

        def DEALLOCATE(self):
            return self.getToken(SqlBaseParser.DEALLOCATE, 0)
        def PREPARE(self):
            return self.getToken(SqlBaseParser.PREPARE, 0)
        def identifier(self):
            return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterDeallocate"):
                listener.enterDeallocate(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitDeallocate"):
                listener.exitDeallocate(self)


    class RenameTableContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.RenameTableContext, self).__init__(parser)
            self._from = None # QualifiedNameContext
            self.to = None # QualifiedNameContext
            self.copyFrom(ctx)

        def ALTER(self):
            return self.getToken(SqlBaseParser.ALTER, 0)
        def TABLE(self):
            return self.getToken(SqlBaseParser.TABLE, 0)
        def RENAME(self):
            return self.getToken(SqlBaseParser.RENAME, 0)
        def TO(self):
            return self.getToken(SqlBaseParser.TO, 0)
        def qualifiedName(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.QualifiedNameContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,i)


        def enterRule(self, listener):
            if hasattr(listener, "enterRenameTable"):
                listener.enterRenameTable(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitRenameTable"):
                listener.exitRenameTable(self)


    class CommitContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.CommitContext, self).__init__(parser)
            self.copyFrom(ctx)

        def COMMIT(self):
            return self.getToken(SqlBaseParser.COMMIT, 0)
        def WORK(self):
            return self.getToken(SqlBaseParser.WORK, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterCommit"):
                listener.enterCommit(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitCommit"):
                listener.exitCommit(self)


    class RevokeContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.RevokeContext, self).__init__(parser)
            self.grantee = None # IdentifierContext
            self.copyFrom(ctx)

        def REVOKE(self):
            return self.getToken(SqlBaseParser.REVOKE, 0)
        def ON(self):
            return self.getToken(SqlBaseParser.ON, 0)
        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)

        def FROM(self):
            return self.getToken(SqlBaseParser.FROM, 0)
        def identifier(self):
            return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,0)

        def privilege(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.PrivilegeContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.PrivilegeContext,i)

        def ALL(self):
            return self.getToken(SqlBaseParser.ALL, 0)
        def PRIVILEGES(self):
            return self.getToken(SqlBaseParser.PRIVILEGES, 0)
        def GRANT(self):
            return self.getToken(SqlBaseParser.GRANT, 0)
        def OPTION(self):
            return self.getToken(SqlBaseParser.OPTION, 0)
        def FOR(self):
            return self.getToken(SqlBaseParser.FOR, 0)
        def TABLE(self):
            return self.getToken(SqlBaseParser.TABLE, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterRevoke"):
                listener.enterRevoke(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitRevoke"):
                listener.exitRevoke(self)


    class ShowPartitionsContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.ShowPartitionsContext, self).__init__(parser)
            self.limit = None # Token
            self.copyFrom(ctx)

        def SHOW(self):
            return self.getToken(SqlBaseParser.SHOW, 0)
        def PARTITIONS(self):
            return self.getToken(SqlBaseParser.PARTITIONS, 0)
        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)

        def FROM(self):
            return self.getToken(SqlBaseParser.FROM, 0)
        def IN(self):
            return self.getToken(SqlBaseParser.IN, 0)
        def WHERE(self):
            return self.getToken(SqlBaseParser.WHERE, 0)
        def booleanExpression(self):
            return self.getTypedRuleContext(SqlBaseParser.BooleanExpressionContext,0)

        def ORDER(self):
            return self.getToken(SqlBaseParser.ORDER, 0)
        def BY(self):
            return self.getToken(SqlBaseParser.BY, 0)
        def sortItem(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.SortItemContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.SortItemContext,i)

        def LIMIT(self):
            return self.getToken(SqlBaseParser.LIMIT, 0)
        def INTEGER_VALUE(self):
            return self.getToken(SqlBaseParser.INTEGER_VALUE, 0)
        def ALL(self):
            return self.getToken(SqlBaseParser.ALL, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterShowPartitions"):
                listener.enterShowPartitions(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitShowPartitions"):
                listener.exitShowPartitions(self)


    class DropColumnContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.DropColumnContext, self).__init__(parser)
            self.tableName = None # QualifiedNameContext
            self.column = None # QualifiedNameContext
            self.copyFrom(ctx)

        def ALTER(self):
            return self.getToken(SqlBaseParser.ALTER, 0)
        def TABLE(self):
            return self.getToken(SqlBaseParser.TABLE, 0)
        def DROP(self):
            return self.getToken(SqlBaseParser.DROP, 0)
        def COLUMN(self):
            return self.getToken(SqlBaseParser.COLUMN, 0)
        def qualifiedName(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.QualifiedNameContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,i)


        def enterRule(self, listener):
            if hasattr(listener, "enterDropColumn"):
                listener.enterDropColumn(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitDropColumn"):
                listener.exitDropColumn(self)


    class DropViewContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.DropViewContext, self).__init__(parser)
            self.copyFrom(ctx)

        def DROP(self):
            return self.getToken(SqlBaseParser.DROP, 0)
        def VIEW(self):
            return self.getToken(SqlBaseParser.VIEW, 0)
        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)

        def IF(self):
            return self.getToken(SqlBaseParser.IF, 0)
        def EXISTS(self):
            return self.getToken(SqlBaseParser.EXISTS, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterDropView"):
                listener.enterDropView(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitDropView"):
                listener.exitDropView(self)


    class DeleteContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.DeleteContext, self).__init__(parser)
            self.copyFrom(ctx)

        def DELETE(self):
            return self.getToken(SqlBaseParser.DELETE, 0)
        def FROM(self):
            return self.getToken(SqlBaseParser.FROM, 0)
        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)

        def WHERE(self):
            return self.getToken(SqlBaseParser.WHERE, 0)
        def booleanExpression(self):
            return self.getTypedRuleContext(SqlBaseParser.BooleanExpressionContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterDelete"):
                listener.enterDelete(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitDelete"):
                listener.exitDelete(self)


    class ShowTablesContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.ShowTablesContext, self).__init__(parser)
            self.pattern = None # StringContext
            self.escape = None # StringContext
            self.copyFrom(ctx)

        def SHOW(self):
            return self.getToken(SqlBaseParser.SHOW, 0)
        def TABLES(self):
            return self.getToken(SqlBaseParser.TABLES, 0)
        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)

        def LIKE(self):
            return self.getToken(SqlBaseParser.LIKE, 0)
        def FROM(self):
            return self.getToken(SqlBaseParser.FROM, 0)
        def IN(self):
            return self.getToken(SqlBaseParser.IN, 0)
        def string(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.StringContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.StringContext,i)

        def ESCAPE(self):
            return self.getToken(SqlBaseParser.ESCAPE, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterShowTables"):
                listener.enterShowTables(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitShowTables"):
                listener.exitShowTables(self)


    class DescribeInputContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.DescribeInputContext, self).__init__(parser)
            self.copyFrom(ctx)

        def DESCRIBE(self):
            return self.getToken(SqlBaseParser.DESCRIBE, 0)
        def INPUT(self):
            return self.getToken(SqlBaseParser.INPUT, 0)
        def identifier(self):
            return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterDescribeInput"):
                listener.enterDescribeInput(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitDescribeInput"):
                listener.exitDescribeInput(self)


    class ShowStatsForQueryContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.ShowStatsForQueryContext, self).__init__(parser)
            self.copyFrom(ctx)

        def SHOW(self):
            return self.getToken(SqlBaseParser.SHOW, 0)
        def STATS(self):
            return self.getToken(SqlBaseParser.STATS, 0)
        def FOR(self):
            return self.getToken(SqlBaseParser.FOR, 0)
        def querySpecification(self):
            return self.getTypedRuleContext(SqlBaseParser.QuerySpecificationContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterShowStatsForQuery"):
                listener.enterShowStatsForQuery(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitShowStatsForQuery"):
                listener.exitShowStatsForQuery(self)


    class ShowCatalogsContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.ShowCatalogsContext, self).__init__(parser)
            self.pattern = None # StringContext
            self.copyFrom(ctx)

        def SHOW(self):
            return self.getToken(SqlBaseParser.SHOW, 0)
        def CATALOGS(self):
            return self.getToken(SqlBaseParser.CATALOGS, 0)
        def LIKE(self):
            return self.getToken(SqlBaseParser.LIKE, 0)
        def string(self):
            return self.getTypedRuleContext(SqlBaseParser.StringContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterShowCatalogs"):
                listener.enterShowCatalogs(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitShowCatalogs"):
                listener.exitShowCatalogs(self)


    class StatementDefaultContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.StatementDefaultContext, self).__init__(parser)
            self.copyFrom(ctx)

        def query(self):
            return self.getTypedRuleContext(SqlBaseParser.QueryContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterStatementDefault"):
                listener.enterStatementDefault(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitStatementDefault"):
                listener.exitStatementDefault(self)


    class RenameColumnContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.RenameColumnContext, self).__init__(parser)
            self.tableName = None # QualifiedNameContext
            self._from = None # IdentifierContext
            self.to = None # IdentifierContext
            self.copyFrom(ctx)

        def ALTER(self):
            return self.getToken(SqlBaseParser.ALTER, 0)
        def TABLE(self):
            return self.getToken(SqlBaseParser.TABLE, 0)
        def RENAME(self):
            return self.getToken(SqlBaseParser.RENAME, 0)
        def COLUMN(self):
            return self.getToken(SqlBaseParser.COLUMN, 0)
        def TO(self):
            return self.getToken(SqlBaseParser.TO, 0)
        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)

        def identifier(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.IdentifierContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,i)


        def enterRule(self, listener):
            if hasattr(listener, "enterRenameColumn"):
                listener.enterRenameColumn(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitRenameColumn"):
                listener.exitRenameColumn(self)


    class SetSessionContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.SetSessionContext, self).__init__(parser)
            self.copyFrom(ctx)

        def SET(self):
            return self.getToken(SqlBaseParser.SET, 0)
        def SESSION(self):
            return self.getToken(SqlBaseParser.SESSION, 0)
        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)

        def EQ(self):
            return self.getToken(SqlBaseParser.EQ, 0)
        def expression(self):
            return self.getTypedRuleContext(SqlBaseParser.ExpressionContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterSetSession"):
                listener.enterSetSession(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitSetSession"):
                listener.exitSetSession(self)


    class CreateViewContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.CreateViewContext, self).__init__(parser)
            self.copyFrom(ctx)

        def CREATE(self):
            return self.getToken(SqlBaseParser.CREATE, 0)
        def VIEW(self):
            return self.getToken(SqlBaseParser.VIEW, 0)
        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)

        def AS(self):
            return self.getToken(SqlBaseParser.AS, 0)
        def query(self):
            return self.getTypedRuleContext(SqlBaseParser.QueryContext,0)

        def OR(self):
            return self.getToken(SqlBaseParser.OR, 0)
        def REPLACE(self):
            return self.getToken(SqlBaseParser.REPLACE, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterCreateView"):
                listener.enterCreateView(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitCreateView"):
                listener.exitCreateView(self)


    class ShowCreateTableContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.ShowCreateTableContext, self).__init__(parser)
            self.copyFrom(ctx)

        def SHOW(self):
            return self.getToken(SqlBaseParser.SHOW, 0)
        def CREATE(self):
            return self.getToken(SqlBaseParser.CREATE, 0)
        def TABLE(self):
            return self.getToken(SqlBaseParser.TABLE, 0)
        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterShowCreateTable"):
                listener.enterShowCreateTable(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitShowCreateTable"):
                listener.exitShowCreateTable(self)


    class ShowSchemasContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.ShowSchemasContext, self).__init__(parser)
            self.pattern = None # StringContext
            self.escape = None # StringContext
            self.copyFrom(ctx)

        def SHOW(self):
            return self.getToken(SqlBaseParser.SHOW, 0)
        def SCHEMAS(self):
            return self.getToken(SqlBaseParser.SCHEMAS, 0)
        def identifier(self):
            return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,0)

        def LIKE(self):
            return self.getToken(SqlBaseParser.LIKE, 0)
        def FROM(self):
            return self.getToken(SqlBaseParser.FROM, 0)
        def IN(self):
            return self.getToken(SqlBaseParser.IN, 0)
        def string(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.StringContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.StringContext,i)

        def ESCAPE(self):
            return self.getToken(SqlBaseParser.ESCAPE, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterShowSchemas"):
                listener.enterShowSchemas(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitShowSchemas"):
                listener.exitShowSchemas(self)


    class DropTableContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.DropTableContext, self).__init__(parser)
            self.copyFrom(ctx)

        def DROP(self):
            return self.getToken(SqlBaseParser.DROP, 0)
        def TABLE(self):
            return self.getToken(SqlBaseParser.TABLE, 0)
        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)

        def IF(self):
            return self.getToken(SqlBaseParser.IF, 0)
        def EXISTS(self):
            return self.getToken(SqlBaseParser.EXISTS, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterDropTable"):
                listener.enterDropTable(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitDropTable"):
                listener.exitDropTable(self)


    class ShowColumnsContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.ShowColumnsContext, self).__init__(parser)
            self.copyFrom(ctx)

        def SHOW(self):
            return self.getToken(SqlBaseParser.SHOW, 0)
        def COLUMNS(self):
            return self.getToken(SqlBaseParser.COLUMNS, 0)
        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)

        def FROM(self):
            return self.getToken(SqlBaseParser.FROM, 0)
        def IN(self):
            return self.getToken(SqlBaseParser.IN, 0)
        def DESCRIBE(self):
            return self.getToken(SqlBaseParser.DESCRIBE, 0)
        def DESC(self):
            return self.getToken(SqlBaseParser.DESC, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterShowColumns"):
                listener.enterShowColumns(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitShowColumns"):
                listener.exitShowColumns(self)


    class RollbackContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.RollbackContext, self).__init__(parser)
            self.copyFrom(ctx)

        def ROLLBACK(self):
            return self.getToken(SqlBaseParser.ROLLBACK, 0)
        def WORK(self):
            return self.getToken(SqlBaseParser.WORK, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterRollback"):
                listener.enterRollback(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitRollback"):
                listener.exitRollback(self)


    class AddColumnContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.AddColumnContext, self).__init__(parser)
            self.tableName = None # QualifiedNameContext
            self.column = None # ColumnDefinitionContext
            self.copyFrom(ctx)

        def ALTER(self):
            return self.getToken(SqlBaseParser.ALTER, 0)
        def TABLE(self):
            return self.getToken(SqlBaseParser.TABLE, 0)
        def ADD(self):
            return self.getToken(SqlBaseParser.ADD, 0)
        def COLUMN(self):
            return self.getToken(SqlBaseParser.COLUMN, 0)
        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)

        def columnDefinition(self):
            return self.getTypedRuleContext(SqlBaseParser.ColumnDefinitionContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterAddColumn"):
                listener.enterAddColumn(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitAddColumn"):
                listener.exitAddColumn(self)


    class ResetSessionContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.ResetSessionContext, self).__init__(parser)
            self.copyFrom(ctx)

        def RESET(self):
            return self.getToken(SqlBaseParser.RESET, 0)
        def SESSION(self):
            return self.getToken(SqlBaseParser.SESSION, 0)
        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterResetSession"):
                listener.enterResetSession(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitResetSession"):
                listener.exitResetSession(self)


    class InsertIntoContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.InsertIntoContext, self).__init__(parser)
            self.copyFrom(ctx)

        def INSERT(self):
            return self.getToken(SqlBaseParser.INSERT, 0)
        def INTO(self):
            return self.getToken(SqlBaseParser.INTO, 0)
        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)

        def query(self):
            return self.getTypedRuleContext(SqlBaseParser.QueryContext,0)

        def columnAliases(self):
            return self.getTypedRuleContext(SqlBaseParser.ColumnAliasesContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterInsertInto"):
                listener.enterInsertInto(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitInsertInto"):
                listener.exitInsertInto(self)


    class ShowSessionContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.ShowSessionContext, self).__init__(parser)
            self.copyFrom(ctx)

        def SHOW(self):
            return self.getToken(SqlBaseParser.SHOW, 0)
        def SESSION(self):
            return self.getToken(SqlBaseParser.SESSION, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterShowSession"):
                listener.enterShowSession(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitShowSession"):
                listener.exitShowSession(self)


    class CreateSchemaContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.CreateSchemaContext, self).__init__(parser)
            self.copyFrom(ctx)

        def CREATE(self):
            return self.getToken(SqlBaseParser.CREATE, 0)
        def SCHEMA(self):
            return self.getToken(SqlBaseParser.SCHEMA, 0)
        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)

        def IF(self):
            return self.getToken(SqlBaseParser.IF, 0)
        def NOT(self):
            return self.getToken(SqlBaseParser.NOT, 0)
        def EXISTS(self):
            return self.getToken(SqlBaseParser.EXISTS, 0)
        def WITH(self):
            return self.getToken(SqlBaseParser.WITH, 0)
        def properties(self):
            return self.getTypedRuleContext(SqlBaseParser.PropertiesContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterCreateSchema"):
                listener.enterCreateSchema(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitCreateSchema"):
                listener.exitCreateSchema(self)


    class ExecuteContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.ExecuteContext, self).__init__(parser)
            self.copyFrom(ctx)

        def EXECUTE(self):
            return self.getToken(SqlBaseParser.EXECUTE, 0)
        def identifier(self):
            return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,0)

        def USING(self):
            return self.getToken(SqlBaseParser.USING, 0)
        def expression(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.ExpressionContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.ExpressionContext,i)


        def enterRule(self, listener):
            if hasattr(listener, "enterExecute"):
                listener.enterExecute(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitExecute"):
                listener.exitExecute(self)


    class CallContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.CallContext, self).__init__(parser)
            self.copyFrom(ctx)

        def CALL(self):
            return self.getToken(SqlBaseParser.CALL, 0)
        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)

        def callArgument(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.CallArgumentContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.CallArgumentContext,i)


        def enterRule(self, listener):
            if hasattr(listener, "enterCall"):
                listener.enterCall(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitCall"):
                listener.exitCall(self)


    class RenameSchemaContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.RenameSchemaContext, self).__init__(parser)
            self.copyFrom(ctx)

        def ALTER(self):
            return self.getToken(SqlBaseParser.ALTER, 0)
        def SCHEMA(self):
            return self.getToken(SqlBaseParser.SCHEMA, 0)
        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)

        def RENAME(self):
            return self.getToken(SqlBaseParser.RENAME, 0)
        def TO(self):
            return self.getToken(SqlBaseParser.TO, 0)
        def identifier(self):
            return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterRenameSchema"):
                listener.enterRenameSchema(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitRenameSchema"):
                listener.exitRenameSchema(self)


    class ShowGrantsContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.ShowGrantsContext, self).__init__(parser)
            self.copyFrom(ctx)

        def SHOW(self):
            return self.getToken(SqlBaseParser.SHOW, 0)
        def GRANTS(self):
            return self.getToken(SqlBaseParser.GRANTS, 0)
        def ON(self):
            return self.getToken(SqlBaseParser.ON, 0)
        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)

        def TABLE(self):
            return self.getToken(SqlBaseParser.TABLE, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterShowGrants"):
                listener.enterShowGrants(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitShowGrants"):
                listener.exitShowGrants(self)


    class ShowFunctionsContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.ShowFunctionsContext, self).__init__(parser)
            self.copyFrom(ctx)

        def SHOW(self):
            return self.getToken(SqlBaseParser.SHOW, 0)
        def FUNCTIONS(self):
            return self.getToken(SqlBaseParser.FUNCTIONS, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterShowFunctions"):
                listener.enterShowFunctions(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitShowFunctions"):
                listener.exitShowFunctions(self)


    class DescribeOutputContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.DescribeOutputContext, self).__init__(parser)
            self.copyFrom(ctx)

        def DESCRIBE(self):
            return self.getToken(SqlBaseParser.DESCRIBE, 0)
        def OUTPUT(self):
            return self.getToken(SqlBaseParser.OUTPUT, 0)
        def identifier(self):
            return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterDescribeOutput"):
                listener.enterDescribeOutput(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitDescribeOutput"):
                listener.exitDescribeOutput(self)


    class DropSchemaContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.DropSchemaContext, self).__init__(parser)
            self.copyFrom(ctx)

        def DROP(self):
            return self.getToken(SqlBaseParser.DROP, 0)
        def SCHEMA(self):
            return self.getToken(SqlBaseParser.SCHEMA, 0)
        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)

        def IF(self):
            return self.getToken(SqlBaseParser.IF, 0)
        def EXISTS(self):
            return self.getToken(SqlBaseParser.EXISTS, 0)
        def CASCADE(self):
            return self.getToken(SqlBaseParser.CASCADE, 0)
        def RESTRICT(self):
            return self.getToken(SqlBaseParser.RESTRICT, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterDropSchema"):
                listener.enterDropSchema(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitDropSchema"):
                listener.exitDropSchema(self)


    class GrantContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.GrantContext, self).__init__(parser)
            self.grantee = None # IdentifierContext
            self.copyFrom(ctx)

        def GRANT(self, i=None):
            if i is None:
                return self.getTokens(SqlBaseParser.GRANT)
            else:
                return self.getToken(SqlBaseParser.GRANT, i)
        def ON(self):
            return self.getToken(SqlBaseParser.ON, 0)
        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)

        def TO(self):
            return self.getToken(SqlBaseParser.TO, 0)
        def identifier(self):
            return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,0)

        def privilege(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.PrivilegeContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.PrivilegeContext,i)

        def ALL(self):
            return self.getToken(SqlBaseParser.ALL, 0)
        def PRIVILEGES(self):
            return self.getToken(SqlBaseParser.PRIVILEGES, 0)
        def TABLE(self):
            return self.getToken(SqlBaseParser.TABLE, 0)
        def WITH(self):
            return self.getToken(SqlBaseParser.WITH, 0)
        def OPTION(self):
            return self.getToken(SqlBaseParser.OPTION, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterGrant"):
                listener.enterGrant(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitGrant"):
                listener.exitGrant(self)


    class ShowCreateViewContext(StatementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StatementContext)
            super(SqlBaseParser.ShowCreateViewContext, self).__init__(parser)
            self.copyFrom(ctx)

        def SHOW(self):
            return self.getToken(SqlBaseParser.SHOW, 0)
        def CREATE(self):
            return self.getToken(SqlBaseParser.CREATE, 0)
        def VIEW(self):
            return self.getToken(SqlBaseParser.VIEW, 0)
        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterShowCreateView"):
                listener.enterShowCreateView(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitShowCreateView"):
                listener.exitShowCreateView(self)



    def statement(self):

        localctx = SqlBaseParser.StatementContext(self, self._ctx, self.state)
        self.enterRule(localctx, 4, self.RULE_statement)
        self._la = 0 # Token type
        try:
            self.state = 535
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,53,self._ctx)
            if la_ == 1:
                localctx = SqlBaseParser.StatementDefaultContext(self, localctx)
                self.enterOuterAlt(localctx, 1)
                self.state = 128
                self.query()
                pass

            elif la_ == 2:
                localctx = SqlBaseParser.UseContext(self, localctx)
                self.enterOuterAlt(localctx, 2)
                self.state = 129
                self.match(SqlBaseParser.USE)
                self.state = 130
                localctx.schema = self.identifier()
                pass

            elif la_ == 3:
                localctx = SqlBaseParser.UseContext(self, localctx)
                self.enterOuterAlt(localctx, 3)
                self.state = 131
                self.match(SqlBaseParser.USE)
                self.state = 132
                localctx.catalog = self.identifier()
                self.state = 133
                self.match(SqlBaseParser.T__0)
                self.state = 134
                localctx.schema = self.identifier()
                pass

            elif la_ == 4:
                localctx = SqlBaseParser.CreateSchemaContext(self, localctx)
                self.enterOuterAlt(localctx, 4)
                self.state = 136
                self.match(SqlBaseParser.CREATE)
                self.state = 137
                self.match(SqlBaseParser.SCHEMA)
                self.state = 141
                self._errHandler.sync(self)
                la_ = self._interp.adaptivePredict(self._input,0,self._ctx)
                if la_ == 1:
                    self.state = 138
                    self.match(SqlBaseParser.IF)
                    self.state = 139
                    self.match(SqlBaseParser.NOT)
                    self.state = 140
                    self.match(SqlBaseParser.EXISTS)


                self.state = 143
                self.qualifiedName()
                self.state = 146
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.WITH:
                    self.state = 144
                    self.match(SqlBaseParser.WITH)
                    self.state = 145
                    self.properties()


                pass

            elif la_ == 5:
                localctx = SqlBaseParser.DropSchemaContext(self, localctx)
                self.enterOuterAlt(localctx, 5)
                self.state = 148
                self.match(SqlBaseParser.DROP)
                self.state = 149
                self.match(SqlBaseParser.SCHEMA)
                self.state = 152
                self._errHandler.sync(self)
                la_ = self._interp.adaptivePredict(self._input,2,self._ctx)
                if la_ == 1:
                    self.state = 150
                    self.match(SqlBaseParser.IF)
                    self.state = 151
                    self.match(SqlBaseParser.EXISTS)


                self.state = 154
                self.qualifiedName()
                self.state = 156
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.CASCADE or _la==SqlBaseParser.RESTRICT:
                    self.state = 155
                    _la = self._input.LA(1)
                    if not(_la==SqlBaseParser.CASCADE or _la==SqlBaseParser.RESTRICT):
                        self._errHandler.recoverInline(self)
                    else:
                        self._errHandler.reportMatch(self)
                        self.consume()


                pass

            elif la_ == 6:
                localctx = SqlBaseParser.RenameSchemaContext(self, localctx)
                self.enterOuterAlt(localctx, 6)
                self.state = 158
                self.match(SqlBaseParser.ALTER)
                self.state = 159
                self.match(SqlBaseParser.SCHEMA)
                self.state = 160
                self.qualifiedName()
                self.state = 161
                self.match(SqlBaseParser.RENAME)
                self.state = 162
                self.match(SqlBaseParser.TO)
                self.state = 163
                self.identifier()
                pass

            elif la_ == 7:
                localctx = SqlBaseParser.CreateTableAsSelectContext(self, localctx)
                self.enterOuterAlt(localctx, 7)
                self.state = 165
                self.match(SqlBaseParser.CREATE)
                self.state = 166
                self.match(SqlBaseParser.TABLE)
                self.state = 170
                self._errHandler.sync(self)
                la_ = self._interp.adaptivePredict(self._input,4,self._ctx)
                if la_ == 1:
                    self.state = 167
                    self.match(SqlBaseParser.IF)
                    self.state = 168
                    self.match(SqlBaseParser.NOT)
                    self.state = 169
                    self.match(SqlBaseParser.EXISTS)


                self.state = 172
                self.qualifiedName()
                self.state = 174
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.T__1:
                    self.state = 173
                    self.columnAliases()


                self.state = 178
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.COMMENT:
                    self.state = 176
                    self.match(SqlBaseParser.COMMENT)
                    self.state = 177
                    self.string()


                self.state = 182
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.WITH:
                    self.state = 180
                    self.match(SqlBaseParser.WITH)
                    self.state = 181
                    self.properties()


                self.state = 184
                self.match(SqlBaseParser.AS)
                self.state = 190
                self._errHandler.sync(self)
                la_ = self._interp.adaptivePredict(self._input,8,self._ctx)
                if la_ == 1:
                    self.state = 185
                    self.query()
                    pass

                elif la_ == 2:
                    self.state = 186
                    self.match(SqlBaseParser.T__1)
                    self.state = 187
                    self.query()
                    self.state = 188
                    self.match(SqlBaseParser.T__2)
                    pass


                self.state = 197
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.WITH:
                    self.state = 192
                    self.match(SqlBaseParser.WITH)
                    self.state = 194
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)
                    if _la==SqlBaseParser.NO:
                        self.state = 193
                        self.match(SqlBaseParser.NO)


                    self.state = 196
                    self.match(SqlBaseParser.DATA)


                pass

            elif la_ == 8:
                localctx = SqlBaseParser.CreateTableContext(self, localctx)
                self.enterOuterAlt(localctx, 8)
                self.state = 199
                self.match(SqlBaseParser.CREATE)
                self.state = 200
                self.match(SqlBaseParser.TABLE)
                self.state = 204
                self._errHandler.sync(self)
                la_ = self._interp.adaptivePredict(self._input,11,self._ctx)
                if la_ == 1:
                    self.state = 201
                    self.match(SqlBaseParser.IF)
                    self.state = 202
                    self.match(SqlBaseParser.NOT)
                    self.state = 203
                    self.match(SqlBaseParser.EXISTS)


                self.state = 206
                self.qualifiedName()
                self.state = 207
                self.match(SqlBaseParser.T__1)
                self.state = 208
                self.tableElement()
                self.state = 213
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                while _la==SqlBaseParser.T__3:
                    self.state = 209
                    self.match(SqlBaseParser.T__3)
                    self.state = 210
                    self.tableElement()
                    self.state = 215
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)

                self.state = 216
                self.match(SqlBaseParser.T__2)
                self.state = 219
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.COMMENT:
                    self.state = 217
                    self.match(SqlBaseParser.COMMENT)
                    self.state = 218
                    self.string()


                self.state = 223
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.WITH:
                    self.state = 221
                    self.match(SqlBaseParser.WITH)
                    self.state = 222
                    self.properties()


                pass

            elif la_ == 9:
                localctx = SqlBaseParser.DropTableContext(self, localctx)
                self.enterOuterAlt(localctx, 9)
                self.state = 225
                self.match(SqlBaseParser.DROP)
                self.state = 226
                self.match(SqlBaseParser.TABLE)
                self.state = 229
                self._errHandler.sync(self)
                la_ = self._interp.adaptivePredict(self._input,15,self._ctx)
                if la_ == 1:
                    self.state = 227
                    self.match(SqlBaseParser.IF)
                    self.state = 228
                    self.match(SqlBaseParser.EXISTS)


                self.state = 231
                self.qualifiedName()
                pass

            elif la_ == 10:
                localctx = SqlBaseParser.InsertIntoContext(self, localctx)
                self.enterOuterAlt(localctx, 10)
                self.state = 232
                self.match(SqlBaseParser.INSERT)
                self.state = 233
                self.match(SqlBaseParser.INTO)
                self.state = 234
                self.qualifiedName()
                self.state = 236
                self._errHandler.sync(self)
                la_ = self._interp.adaptivePredict(self._input,16,self._ctx)
                if la_ == 1:
                    self.state = 235
                    self.columnAliases()


                self.state = 238
                self.query()
                pass

            elif la_ == 11:
                localctx = SqlBaseParser.DeleteContext(self, localctx)
                self.enterOuterAlt(localctx, 11)
                self.state = 240
                self.match(SqlBaseParser.DELETE)
                self.state = 241
                self.match(SqlBaseParser.FROM)
                self.state = 242
                self.qualifiedName()
                self.state = 245
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.WHERE:
                    self.state = 243
                    self.match(SqlBaseParser.WHERE)
                    self.state = 244
                    self.booleanExpression(0)


                pass

            elif la_ == 12:
                localctx = SqlBaseParser.RenameTableContext(self, localctx)
                self.enterOuterAlt(localctx, 12)
                self.state = 247
                self.match(SqlBaseParser.ALTER)
                self.state = 248
                self.match(SqlBaseParser.TABLE)
                self.state = 249
                localctx._from = self.qualifiedName()
                self.state = 250
                self.match(SqlBaseParser.RENAME)
                self.state = 251
                self.match(SqlBaseParser.TO)
                self.state = 252
                localctx.to = self.qualifiedName()
                pass

            elif la_ == 13:
                localctx = SqlBaseParser.RenameColumnContext(self, localctx)
                self.enterOuterAlt(localctx, 13)
                self.state = 254
                self.match(SqlBaseParser.ALTER)
                self.state = 255
                self.match(SqlBaseParser.TABLE)
                self.state = 256
                localctx.tableName = self.qualifiedName()
                self.state = 257
                self.match(SqlBaseParser.RENAME)
                self.state = 258
                self.match(SqlBaseParser.COLUMN)
                self.state = 259
                localctx._from = self.identifier()
                self.state = 260
                self.match(SqlBaseParser.TO)
                self.state = 261
                localctx.to = self.identifier()
                pass

            elif la_ == 14:
                localctx = SqlBaseParser.DropColumnContext(self, localctx)
                self.enterOuterAlt(localctx, 14)
                self.state = 263
                self.match(SqlBaseParser.ALTER)
                self.state = 264
                self.match(SqlBaseParser.TABLE)
                self.state = 265
                localctx.tableName = self.qualifiedName()
                self.state = 266
                self.match(SqlBaseParser.DROP)
                self.state = 267
                self.match(SqlBaseParser.COLUMN)
                self.state = 268
                localctx.column = self.qualifiedName()
                pass

            elif la_ == 15:
                localctx = SqlBaseParser.AddColumnContext(self, localctx)
                self.enterOuterAlt(localctx, 15)
                self.state = 270
                self.match(SqlBaseParser.ALTER)
                self.state = 271
                self.match(SqlBaseParser.TABLE)
                self.state = 272
                localctx.tableName = self.qualifiedName()
                self.state = 273
                self.match(SqlBaseParser.ADD)
                self.state = 274
                self.match(SqlBaseParser.COLUMN)
                self.state = 275
                localctx.column = self.columnDefinition()
                pass

            elif la_ == 16:
                localctx = SqlBaseParser.CreateViewContext(self, localctx)
                self.enterOuterAlt(localctx, 16)
                self.state = 277
                self.match(SqlBaseParser.CREATE)
                self.state = 280
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.OR:
                    self.state = 278
                    self.match(SqlBaseParser.OR)
                    self.state = 279
                    self.match(SqlBaseParser.REPLACE)


                self.state = 282
                self.match(SqlBaseParser.VIEW)
                self.state = 283
                self.qualifiedName()
                self.state = 284
                self.match(SqlBaseParser.AS)
                self.state = 285
                self.query()
                pass

            elif la_ == 17:
                localctx = SqlBaseParser.DropViewContext(self, localctx)
                self.enterOuterAlt(localctx, 17)
                self.state = 287
                self.match(SqlBaseParser.DROP)
                self.state = 288
                self.match(SqlBaseParser.VIEW)
                self.state = 291
                self._errHandler.sync(self)
                la_ = self._interp.adaptivePredict(self._input,19,self._ctx)
                if la_ == 1:
                    self.state = 289
                    self.match(SqlBaseParser.IF)
                    self.state = 290
                    self.match(SqlBaseParser.EXISTS)


                self.state = 293
                self.qualifiedName()
                pass

            elif la_ == 18:
                localctx = SqlBaseParser.CallContext(self, localctx)
                self.enterOuterAlt(localctx, 18)
                self.state = 294
                self.match(SqlBaseParser.CALL)
                self.state = 295
                self.qualifiedName()
                self.state = 296
                self.match(SqlBaseParser.T__1)
                self.state = 305
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if (((_la) & ~0x3f) == 0 and ((1 << _la) & ((1 << SqlBaseParser.T__1) | (1 << SqlBaseParser.T__4) | (1 << SqlBaseParser.ADD) | (1 << SqlBaseParser.ALL) | (1 << SqlBaseParser.ANALYZE) | (1 << SqlBaseParser.ANY) | (1 << SqlBaseParser.ARRAY) | (1 << SqlBaseParser.ASC) | (1 << SqlBaseParser.AT) | (1 << SqlBaseParser.BERNOULLI) | (1 << SqlBaseParser.CALL) | (1 << SqlBaseParser.CASCADE) | (1 << SqlBaseParser.CASE) | (1 << SqlBaseParser.CAST) | (1 << SqlBaseParser.CATALOGS) | (1 << SqlBaseParser.COALESCE) | (1 << SqlBaseParser.COLUMN) | (1 << SqlBaseParser.COLUMNS) | (1 << SqlBaseParser.COMMENT) | (1 << SqlBaseParser.COMMIT) | (1 << SqlBaseParser.COMMITTED) | (1 << SqlBaseParser.CURRENT) | (1 << SqlBaseParser.CURRENT_DATE) | (1 << SqlBaseParser.CURRENT_TIME) | (1 << SqlBaseParser.CURRENT_TIMESTAMP) | (1 << SqlBaseParser.CURRENT_USER) | (1 << SqlBaseParser.DATA) | (1 << SqlBaseParser.DATE) | (1 << SqlBaseParser.DAY) | (1 << SqlBaseParser.DESC) | (1 << SqlBaseParser.DISTRIBUTED) | (1 << SqlBaseParser.EXCLUDING) | (1 << SqlBaseParser.EXISTS) | (1 << SqlBaseParser.EXPLAIN) | (1 << SqlBaseParser.EXTRACT) | (1 << SqlBaseParser.FALSE) | (1 << SqlBaseParser.FILTER))) != 0) or ((((_la - 64)) & ~0x3f) == 0 and ((1 << (_la - 64)) & ((1 << (SqlBaseParser.FIRST - 64)) | (1 << (SqlBaseParser.FOLLOWING - 64)) | (1 << (SqlBaseParser.FORMAT - 64)) | (1 << (SqlBaseParser.FUNCTIONS - 64)) | (1 << (SqlBaseParser.GRANT - 64)) | (1 << (SqlBaseParser.GRANTS - 64)) | (1 << (SqlBaseParser.GRAPHVIZ - 64)) | (1 << (SqlBaseParser.GROUPING - 64)) | (1 << (SqlBaseParser.HOUR - 64)) | (1 << (SqlBaseParser.IF - 64)) | (1 << (SqlBaseParser.INCLUDING - 64)) | (1 << (SqlBaseParser.INPUT - 64)) | (1 << (SqlBaseParser.INTEGER - 64)) | (1 << (SqlBaseParser.INTERVAL - 64)) | (1 << (SqlBaseParser.ISOLATION - 64)) | (1 << (SqlBaseParser.LAST - 64)) | (1 << (SqlBaseParser.LATERAL - 64)) | (1 << (SqlBaseParser.LEVEL - 64)) | (1 << (SqlBaseParser.LIMIT - 64)) | (1 << (SqlBaseParser.LOCALTIME - 64)) | (1 << (SqlBaseParser.LOCALTIMESTAMP - 64)) | (1 << (SqlBaseParser.LOGICAL - 64)) | (1 << (SqlBaseParser.MAP - 64)) | (1 << (SqlBaseParser.MINUTE - 64)) | (1 << (SqlBaseParser.MONTH - 64)) | (1 << (SqlBaseParser.NFC - 64)) | (1 << (SqlBaseParser.NFD - 64)) | (1 << (SqlBaseParser.NFKC - 64)) | (1 << (SqlBaseParser.NFKD - 64)) | (1 << (SqlBaseParser.NO - 64)) | (1 << (SqlBaseParser.NORMALIZE - 64)) | (1 << (SqlBaseParser.NOT - 64)) | (1 << (SqlBaseParser.NULL - 64)) | (1 << (SqlBaseParser.NULLIF - 64)) | (1 << (SqlBaseParser.NULLS - 64)) | (1 << (SqlBaseParser.ONLY - 64)) | (1 << (SqlBaseParser.OPTION - 64)) | (1 << (SqlBaseParser.ORDINALITY - 64)) | (1 << (SqlBaseParser.OUTPUT - 64)) | (1 << (SqlBaseParser.OVER - 64)) | (1 << (SqlBaseParser.PARTITION - 64)) | (1 << (SqlBaseParser.PARTITIONS - 64)) | (1 << (SqlBaseParser.POSITION - 64)) | (1 << (SqlBaseParser.PRECEDING - 64)))) != 0) or ((((_la - 128)) & ~0x3f) == 0 and ((1 << (_la - 128)) & ((1 << (SqlBaseParser.PRIVILEGES - 128)) | (1 << (SqlBaseParser.PROPERTIES - 128)) | (1 << (SqlBaseParser.PUBLIC - 128)) | (1 << (SqlBaseParser.RANGE - 128)) | (1 << (SqlBaseParser.READ - 128)) | (1 << (SqlBaseParser.RENAME - 128)) | (1 << (SqlBaseParser.REPEATABLE - 128)) | (1 << (SqlBaseParser.REPLACE - 128)) | (1 << (SqlBaseParser.RESET - 128)) | (1 << (SqlBaseParser.RESTRICT - 128)) | (1 << (SqlBaseParser.REVOKE - 128)) | (1 << (SqlBaseParser.ROLLBACK - 128)) | (1 << (SqlBaseParser.ROW - 128)) | (1 << (SqlBaseParser.ROWS - 128)) | (1 << (SqlBaseParser.SCHEMA - 128)) | (1 << (SqlBaseParser.SCHEMAS - 128)) | (1 << (SqlBaseParser.SECOND - 128)) | (1 << (SqlBaseParser.SERIALIZABLE - 128)) | (1 << (SqlBaseParser.SESSION - 128)) | (1 << (SqlBaseParser.SET - 128)) | (1 << (SqlBaseParser.SETS - 128)) | (1 << (SqlBaseParser.SHOW - 128)) | (1 << (SqlBaseParser.SMALLINT - 128)) | (1 << (SqlBaseParser.SOME - 128)) | (1 << (SqlBaseParser.START - 128)) | (1 << (SqlBaseParser.STATS - 128)) | (1 << (SqlBaseParser.SUBSTRING - 128)) | (1 << (SqlBaseParser.SYSTEM - 128)) | (1 << (SqlBaseParser.TABLES - 128)) | (1 << (SqlBaseParser.TABLESAMPLE - 128)) | (1 << (SqlBaseParser.TEXT - 128)) | (1 << (SqlBaseParser.TIME - 128)) | (1 << (SqlBaseParser.TIMESTAMP - 128)) | (1 << (SqlBaseParser.TINYINT - 128)) | (1 << (SqlBaseParser.TO - 128)) | (1 << (SqlBaseParser.TRANSACTION - 128)) | (1 << (SqlBaseParser.TRUE - 128)) | (1 << (SqlBaseParser.TRY_CAST - 128)) | (1 << (SqlBaseParser.TYPE - 128)) | (1 << (SqlBaseParser.UNBOUNDED - 128)) | (1 << (SqlBaseParser.UNCOMMITTED - 128)) | (1 << (SqlBaseParser.USE - 128)) | (1 << (SqlBaseParser.VALIDATE - 128)) | (1 << (SqlBaseParser.VERBOSE - 128)) | (1 << (SqlBaseParser.VIEW - 128)) | (1 << (SqlBaseParser.WORK - 128)) | (1 << (SqlBaseParser.WRITE - 128)) | (1 << (SqlBaseParser.YEAR - 128)) | (1 << (SqlBaseParser.ZONE - 128)))) != 0) or ((((_la - 197)) & ~0x3f) == 0 and ((1 << (_la - 197)) & ((1 << (SqlBaseParser.PLUS - 197)) | (1 << (SqlBaseParser.MINUS - 197)) | (1 << (SqlBaseParser.STRING - 197)) | (1 << (SqlBaseParser.UNICODE_STRING - 197)) | (1 << (SqlBaseParser.BINARY_LITERAL - 197)) | (1 << (SqlBaseParser.INTEGER_VALUE - 197)) | (1 << (SqlBaseParser.DECIMAL_VALUE - 197)) | (1 << (SqlBaseParser.DOUBLE_VALUE - 197)) | (1 << (SqlBaseParser.IDENTIFIER - 197)) | (1 << (SqlBaseParser.DIGIT_IDENTIFIER - 197)) | (1 << (SqlBaseParser.QUOTED_IDENTIFIER - 197)) | (1 << (SqlBaseParser.BACKQUOTED_IDENTIFIER - 197)) | (1 << (SqlBaseParser.DOUBLE_PRECISION - 197)))) != 0):
                    self.state = 297
                    self.callArgument()
                    self.state = 302
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)
                    while _la==SqlBaseParser.T__3:
                        self.state = 298
                        self.match(SqlBaseParser.T__3)
                        self.state = 299
                        self.callArgument()
                        self.state = 304
                        self._errHandler.sync(self)
                        _la = self._input.LA(1)



                self.state = 307
                self.match(SqlBaseParser.T__2)
                pass

            elif la_ == 19:
                localctx = SqlBaseParser.GrantContext(self, localctx)
                self.enterOuterAlt(localctx, 19)
                self.state = 309
                self.match(SqlBaseParser.GRANT)
                self.state = 320
                self._errHandler.sync(self)
                la_ = self._interp.adaptivePredict(self._input,23,self._ctx)
                if la_ == 1:
                    self.state = 310
                    self.privilege()
                    self.state = 315
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)
                    while _la==SqlBaseParser.T__3:
                        self.state = 311
                        self.match(SqlBaseParser.T__3)
                        self.state = 312
                        self.privilege()
                        self.state = 317
                        self._errHandler.sync(self)
                        _la = self._input.LA(1)

                    pass

                elif la_ == 2:
                    self.state = 318
                    self.match(SqlBaseParser.ALL)
                    self.state = 319
                    self.match(SqlBaseParser.PRIVILEGES)
                    pass


                self.state = 322
                self.match(SqlBaseParser.ON)
                self.state = 324
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.TABLE:
                    self.state = 323
                    self.match(SqlBaseParser.TABLE)


                self.state = 326
                self.qualifiedName()
                self.state = 327
                self.match(SqlBaseParser.TO)
                self.state = 328
                localctx.grantee = self.identifier()
                self.state = 332
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.WITH:
                    self.state = 329
                    self.match(SqlBaseParser.WITH)
                    self.state = 330
                    self.match(SqlBaseParser.GRANT)
                    self.state = 331
                    self.match(SqlBaseParser.OPTION)


                pass

            elif la_ == 20:
                localctx = SqlBaseParser.RevokeContext(self, localctx)
                self.enterOuterAlt(localctx, 20)
                self.state = 334
                self.match(SqlBaseParser.REVOKE)
                self.state = 338
                self._errHandler.sync(self)
                la_ = self._interp.adaptivePredict(self._input,26,self._ctx)
                if la_ == 1:
                    self.state = 335
                    self.match(SqlBaseParser.GRANT)
                    self.state = 336
                    self.match(SqlBaseParser.OPTION)
                    self.state = 337
                    self.match(SqlBaseParser.FOR)


                self.state = 350
                self._errHandler.sync(self)
                la_ = self._interp.adaptivePredict(self._input,28,self._ctx)
                if la_ == 1:
                    self.state = 340
                    self.privilege()
                    self.state = 345
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)
                    while _la==SqlBaseParser.T__3:
                        self.state = 341
                        self.match(SqlBaseParser.T__3)
                        self.state = 342
                        self.privilege()
                        self.state = 347
                        self._errHandler.sync(self)
                        _la = self._input.LA(1)

                    pass

                elif la_ == 2:
                    self.state = 348
                    self.match(SqlBaseParser.ALL)
                    self.state = 349
                    self.match(SqlBaseParser.PRIVILEGES)
                    pass


                self.state = 352
                self.match(SqlBaseParser.ON)
                self.state = 354
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.TABLE:
                    self.state = 353
                    self.match(SqlBaseParser.TABLE)


                self.state = 356
                self.qualifiedName()
                self.state = 357
                self.match(SqlBaseParser.FROM)
                self.state = 358
                localctx.grantee = self.identifier()
                pass

            elif la_ == 21:
                localctx = SqlBaseParser.ShowGrantsContext(self, localctx)
                self.enterOuterAlt(localctx, 21)
                self.state = 360
                self.match(SqlBaseParser.SHOW)
                self.state = 361
                self.match(SqlBaseParser.GRANTS)
                self.state = 367
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.ON:
                    self.state = 362
                    self.match(SqlBaseParser.ON)
                    self.state = 364
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)
                    if _la==SqlBaseParser.TABLE:
                        self.state = 363
                        self.match(SqlBaseParser.TABLE)


                    self.state = 366
                    self.qualifiedName()


                pass

            elif la_ == 22:
                localctx = SqlBaseParser.ExplainContext(self, localctx)
                self.enterOuterAlt(localctx, 22)
                self.state = 369
                self.match(SqlBaseParser.EXPLAIN)
                self.state = 371
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.ANALYZE:
                    self.state = 370
                    self.match(SqlBaseParser.ANALYZE)


                self.state = 374
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.VERBOSE:
                    self.state = 373
                    self.match(SqlBaseParser.VERBOSE)


                self.state = 387
                self._errHandler.sync(self)
                la_ = self._interp.adaptivePredict(self._input,35,self._ctx)
                if la_ == 1:
                    self.state = 376
                    self.match(SqlBaseParser.T__1)
                    self.state = 377
                    self.explainOption()
                    self.state = 382
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)
                    while _la==SqlBaseParser.T__3:
                        self.state = 378
                        self.match(SqlBaseParser.T__3)
                        self.state = 379
                        self.explainOption()
                        self.state = 384
                        self._errHandler.sync(self)
                        _la = self._input.LA(1)

                    self.state = 385
                    self.match(SqlBaseParser.T__2)


                self.state = 389
                self.statement()
                pass

            elif la_ == 23:
                localctx = SqlBaseParser.ShowCreateTableContext(self, localctx)
                self.enterOuterAlt(localctx, 23)
                self.state = 390
                self.match(SqlBaseParser.SHOW)
                self.state = 391
                self.match(SqlBaseParser.CREATE)
                self.state = 392
                self.match(SqlBaseParser.TABLE)
                self.state = 393
                self.qualifiedName()
                pass

            elif la_ == 24:
                localctx = SqlBaseParser.ShowCreateViewContext(self, localctx)
                self.enterOuterAlt(localctx, 24)
                self.state = 394
                self.match(SqlBaseParser.SHOW)
                self.state = 395
                self.match(SqlBaseParser.CREATE)
                self.state = 396
                self.match(SqlBaseParser.VIEW)
                self.state = 397
                self.qualifiedName()
                pass

            elif la_ == 25:
                localctx = SqlBaseParser.ShowTablesContext(self, localctx)
                self.enterOuterAlt(localctx, 25)
                self.state = 398
                self.match(SqlBaseParser.SHOW)
                self.state = 399
                self.match(SqlBaseParser.TABLES)
                self.state = 402
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.FROM or _la==SqlBaseParser.IN:
                    self.state = 400
                    _la = self._input.LA(1)
                    if not(_la==SqlBaseParser.FROM or _la==SqlBaseParser.IN):
                        self._errHandler.recoverInline(self)
                    else:
                        self._errHandler.reportMatch(self)
                        self.consume()
                    self.state = 401
                    self.qualifiedName()


                self.state = 410
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.LIKE:
                    self.state = 404
                    self.match(SqlBaseParser.LIKE)
                    self.state = 405
                    localctx.pattern = self.string()
                    self.state = 408
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)
                    if _la==SqlBaseParser.ESCAPE:
                        self.state = 406
                        self.match(SqlBaseParser.ESCAPE)
                        self.state = 407
                        localctx.escape = self.string()




                pass

            elif la_ == 26:
                localctx = SqlBaseParser.ShowSchemasContext(self, localctx)
                self.enterOuterAlt(localctx, 26)
                self.state = 412
                self.match(SqlBaseParser.SHOW)
                self.state = 413
                self.match(SqlBaseParser.SCHEMAS)
                self.state = 416
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.FROM or _la==SqlBaseParser.IN:
                    self.state = 414
                    _la = self._input.LA(1)
                    if not(_la==SqlBaseParser.FROM or _la==SqlBaseParser.IN):
                        self._errHandler.recoverInline(self)
                    else:
                        self._errHandler.reportMatch(self)
                        self.consume()
                    self.state = 415
                    self.identifier()


                self.state = 424
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.LIKE:
                    self.state = 418
                    self.match(SqlBaseParser.LIKE)
                    self.state = 419
                    localctx.pattern = self.string()
                    self.state = 422
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)
                    if _la==SqlBaseParser.ESCAPE:
                        self.state = 420
                        self.match(SqlBaseParser.ESCAPE)
                        self.state = 421
                        localctx.escape = self.string()




                pass

            elif la_ == 27:
                localctx = SqlBaseParser.ShowCatalogsContext(self, localctx)
                self.enterOuterAlt(localctx, 27)
                self.state = 426
                self.match(SqlBaseParser.SHOW)
                self.state = 427
                self.match(SqlBaseParser.CATALOGS)
                self.state = 430
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.LIKE:
                    self.state = 428
                    self.match(SqlBaseParser.LIKE)
                    self.state = 429
                    localctx.pattern = self.string()


                pass

            elif la_ == 28:
                localctx = SqlBaseParser.ShowColumnsContext(self, localctx)
                self.enterOuterAlt(localctx, 28)
                self.state = 432
                self.match(SqlBaseParser.SHOW)
                self.state = 433
                self.match(SqlBaseParser.COLUMNS)
                self.state = 434
                _la = self._input.LA(1)
                if not(_la==SqlBaseParser.FROM or _la==SqlBaseParser.IN):
                    self._errHandler.recoverInline(self)
                else:
                    self._errHandler.reportMatch(self)
                    self.consume()
                self.state = 435
                self.qualifiedName()
                pass

            elif la_ == 29:
                localctx = SqlBaseParser.ShowStatsContext(self, localctx)
                self.enterOuterAlt(localctx, 29)
                self.state = 436
                self.match(SqlBaseParser.SHOW)
                self.state = 437
                self.match(SqlBaseParser.STATS)
                self.state = 438
                _la = self._input.LA(1)
                if not(_la==SqlBaseParser.FOR or _la==SqlBaseParser.ON):
                    self._errHandler.recoverInline(self)
                else:
                    self._errHandler.reportMatch(self)
                    self.consume()
                self.state = 439
                self.qualifiedName()
                pass

            elif la_ == 30:
                localctx = SqlBaseParser.ShowStatsForQueryContext(self, localctx)
                self.enterOuterAlt(localctx, 30)
                self.state = 440
                self.match(SqlBaseParser.SHOW)
                self.state = 441
                self.match(SqlBaseParser.STATS)
                self.state = 442
                self.match(SqlBaseParser.FOR)
                self.state = 443
                self.match(SqlBaseParser.T__1)
                self.state = 444
                self.querySpecification()
                self.state = 445
                self.match(SqlBaseParser.T__2)
                pass

            elif la_ == 31:
                localctx = SqlBaseParser.ShowColumnsContext(self, localctx)
                self.enterOuterAlt(localctx, 31)
                self.state = 447
                self.match(SqlBaseParser.DESCRIBE)
                self.state = 448
                self.qualifiedName()
                pass

            elif la_ == 32:
                localctx = SqlBaseParser.ShowColumnsContext(self, localctx)
                self.enterOuterAlt(localctx, 32)
                self.state = 449
                self.match(SqlBaseParser.DESC)
                self.state = 450
                self.qualifiedName()
                pass

            elif la_ == 33:
                localctx = SqlBaseParser.ShowFunctionsContext(self, localctx)
                self.enterOuterAlt(localctx, 33)
                self.state = 451
                self.match(SqlBaseParser.SHOW)
                self.state = 452
                self.match(SqlBaseParser.FUNCTIONS)
                pass

            elif la_ == 34:
                localctx = SqlBaseParser.ShowSessionContext(self, localctx)
                self.enterOuterAlt(localctx, 34)
                self.state = 453
                self.match(SqlBaseParser.SHOW)
                self.state = 454
                self.match(SqlBaseParser.SESSION)
                pass

            elif la_ == 35:
                localctx = SqlBaseParser.SetSessionContext(self, localctx)
                self.enterOuterAlt(localctx, 35)
                self.state = 455
                self.match(SqlBaseParser.SET)
                self.state = 456
                self.match(SqlBaseParser.SESSION)
                self.state = 457
                self.qualifiedName()
                self.state = 458
                self.match(SqlBaseParser.EQ)
                self.state = 459
                self.expression()
                pass

            elif la_ == 36:
                localctx = SqlBaseParser.ResetSessionContext(self, localctx)
                self.enterOuterAlt(localctx, 36)
                self.state = 461
                self.match(SqlBaseParser.RESET)
                self.state = 462
                self.match(SqlBaseParser.SESSION)
                self.state = 463
                self.qualifiedName()
                pass

            elif la_ == 37:
                localctx = SqlBaseParser.StartTransactionContext(self, localctx)
                self.enterOuterAlt(localctx, 37)
                self.state = 464
                self.match(SqlBaseParser.START)
                self.state = 465
                self.match(SqlBaseParser.TRANSACTION)
                self.state = 474
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.ISOLATION or _la==SqlBaseParser.READ:
                    self.state = 466
                    self.transactionMode()
                    self.state = 471
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)
                    while _la==SqlBaseParser.T__3:
                        self.state = 467
                        self.match(SqlBaseParser.T__3)
                        self.state = 468
                        self.transactionMode()
                        self.state = 473
                        self._errHandler.sync(self)
                        _la = self._input.LA(1)



                pass

            elif la_ == 38:
                localctx = SqlBaseParser.CommitContext(self, localctx)
                self.enterOuterAlt(localctx, 38)
                self.state = 476
                self.match(SqlBaseParser.COMMIT)
                self.state = 478
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.WORK:
                    self.state = 477
                    self.match(SqlBaseParser.WORK)


                pass

            elif la_ == 39:
                localctx = SqlBaseParser.RollbackContext(self, localctx)
                self.enterOuterAlt(localctx, 39)
                self.state = 480
                self.match(SqlBaseParser.ROLLBACK)
                self.state = 482
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.WORK:
                    self.state = 481
                    self.match(SqlBaseParser.WORK)


                pass

            elif la_ == 40:
                localctx = SqlBaseParser.ShowPartitionsContext(self, localctx)
                self.enterOuterAlt(localctx, 40)
                self.state = 484
                self.match(SqlBaseParser.SHOW)
                self.state = 485
                self.match(SqlBaseParser.PARTITIONS)
                self.state = 486
                _la = self._input.LA(1)
                if not(_la==SqlBaseParser.FROM or _la==SqlBaseParser.IN):
                    self._errHandler.recoverInline(self)
                else:
                    self._errHandler.reportMatch(self)
                    self.consume()
                self.state = 487
                self.qualifiedName()
                self.state = 490
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.WHERE:
                    self.state = 488
                    self.match(SqlBaseParser.WHERE)
                    self.state = 489
                    self.booleanExpression(0)


                self.state = 502
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.ORDER:
                    self.state = 492
                    self.match(SqlBaseParser.ORDER)
                    self.state = 493
                    self.match(SqlBaseParser.BY)
                    self.state = 494
                    self.sortItem()
                    self.state = 499
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)
                    while _la==SqlBaseParser.T__3:
                        self.state = 495
                        self.match(SqlBaseParser.T__3)
                        self.state = 496
                        self.sortItem()
                        self.state = 501
                        self._errHandler.sync(self)
                        _la = self._input.LA(1)



                self.state = 506
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.LIMIT:
                    self.state = 504
                    self.match(SqlBaseParser.LIMIT)
                    self.state = 505
                    localctx.limit = self._input.LT(1)
                    _la = self._input.LA(1)
                    if not(_la==SqlBaseParser.ALL or _la==SqlBaseParser.INTEGER_VALUE):
                        localctx.limit = self._errHandler.recoverInline(self)
                    else:
                        self._errHandler.reportMatch(self)
                        self.consume()


                pass

            elif la_ == 41:
                localctx = SqlBaseParser.PrepareContext(self, localctx)
                self.enterOuterAlt(localctx, 41)
                self.state = 508
                self.match(SqlBaseParser.PREPARE)
                self.state = 509
                self.identifier()
                self.state = 510
                self.match(SqlBaseParser.FROM)
                self.state = 511
                self.statement()
                pass

            elif la_ == 42:
                localctx = SqlBaseParser.DeallocateContext(self, localctx)
                self.enterOuterAlt(localctx, 42)
                self.state = 513
                self.match(SqlBaseParser.DEALLOCATE)
                self.state = 514
                self.match(SqlBaseParser.PREPARE)
                self.state = 515
                self.identifier()
                pass

            elif la_ == 43:
                localctx = SqlBaseParser.ExecuteContext(self, localctx)
                self.enterOuterAlt(localctx, 43)
                self.state = 516
                self.match(SqlBaseParser.EXECUTE)
                self.state = 517
                self.identifier()
                self.state = 527
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.USING:
                    self.state = 518
                    self.match(SqlBaseParser.USING)
                    self.state = 519
                    self.expression()
                    self.state = 524
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)
                    while _la==SqlBaseParser.T__3:
                        self.state = 520
                        self.match(SqlBaseParser.T__3)
                        self.state = 521
                        self.expression()
                        self.state = 526
                        self._errHandler.sync(self)
                        _la = self._input.LA(1)



                pass

            elif la_ == 44:
                localctx = SqlBaseParser.DescribeInputContext(self, localctx)
                self.enterOuterAlt(localctx, 44)
                self.state = 529
                self.match(SqlBaseParser.DESCRIBE)
                self.state = 530
                self.match(SqlBaseParser.INPUT)
                self.state = 531
                self.identifier()
                pass

            elif la_ == 45:
                localctx = SqlBaseParser.DescribeOutputContext(self, localctx)
                self.enterOuterAlt(localctx, 45)
                self.state = 532
                self.match(SqlBaseParser.DESCRIBE)
                self.state = 533
                self.match(SqlBaseParser.OUTPUT)
                self.state = 534
                self.identifier()
                pass


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class QueryContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.QueryContext, self).__init__(parent, invokingState)
            self.parser = parser

        def queryNoWith(self):
            return self.getTypedRuleContext(SqlBaseParser.QueryNoWithContext,0)


        def _with(self):
            return self.getTypedRuleContext(SqlBaseParser.WithContext,0)


        def getRuleIndex(self):
            return SqlBaseParser.RULE_query

        def enterRule(self, listener):
            if hasattr(listener, "enterQuery"):
                listener.enterQuery(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitQuery"):
                listener.exitQuery(self)




    def query(self):

        localctx = SqlBaseParser.QueryContext(self, self._ctx, self.state)
        self.enterRule(localctx, 6, self.RULE_query)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 538
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==SqlBaseParser.WITH:
                self.state = 537
                self._with()


            self.state = 540
            self.queryNoWith()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class WithContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.WithContext, self).__init__(parent, invokingState)
            self.parser = parser

        def WITH(self):
            return self.getToken(SqlBaseParser.WITH, 0)

        def namedQuery(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.NamedQueryContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.NamedQueryContext,i)


        def RECURSIVE(self):
            return self.getToken(SqlBaseParser.RECURSIVE, 0)

        def getRuleIndex(self):
            return SqlBaseParser.RULE_with

        def enterRule(self, listener):
            if hasattr(listener, "enterWith"):
                listener.enterWith(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitWith"):
                listener.exitWith(self)




    def _with(self):

        localctx = SqlBaseParser.WithContext(self, self._ctx, self.state)
        self.enterRule(localctx, 8, self.RULE_with)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 542
            self.match(SqlBaseParser.WITH)
            self.state = 544
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==SqlBaseParser.RECURSIVE:
                self.state = 543
                self.match(SqlBaseParser.RECURSIVE)


            self.state = 546
            self.namedQuery()
            self.state = 551
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            while _la==SqlBaseParser.T__3:
                self.state = 547
                self.match(SqlBaseParser.T__3)
                self.state = 548
                self.namedQuery()
                self.state = 553
                self._errHandler.sync(self)
                _la = self._input.LA(1)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class TableElementContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.TableElementContext, self).__init__(parent, invokingState)
            self.parser = parser

        def columnDefinition(self):
            return self.getTypedRuleContext(SqlBaseParser.ColumnDefinitionContext,0)


        def likeClause(self):
            return self.getTypedRuleContext(SqlBaseParser.LikeClauseContext,0)


        def getRuleIndex(self):
            return SqlBaseParser.RULE_tableElement

        def enterRule(self, listener):
            if hasattr(listener, "enterTableElement"):
                listener.enterTableElement(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitTableElement"):
                listener.exitTableElement(self)




    def tableElement(self):

        localctx = SqlBaseParser.TableElementContext(self, self._ctx, self.state)
        self.enterRule(localctx, 10, self.RULE_tableElement)
        try:
            self.state = 556
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [SqlBaseParser.ADD, SqlBaseParser.ALL, SqlBaseParser.ANALYZE, SqlBaseParser.ANY, SqlBaseParser.ARRAY, SqlBaseParser.ASC, SqlBaseParser.AT, SqlBaseParser.BERNOULLI, SqlBaseParser.CALL, SqlBaseParser.CASCADE, SqlBaseParser.CATALOGS, SqlBaseParser.COALESCE, SqlBaseParser.COLUMN, SqlBaseParser.COLUMNS, SqlBaseParser.COMMENT, SqlBaseParser.COMMIT, SqlBaseParser.COMMITTED, SqlBaseParser.CURRENT, SqlBaseParser.DATA, SqlBaseParser.DATE, SqlBaseParser.DAY, SqlBaseParser.DESC, SqlBaseParser.DISTRIBUTED, SqlBaseParser.EXCLUDING, SqlBaseParser.EXPLAIN, SqlBaseParser.FILTER, SqlBaseParser.FIRST, SqlBaseParser.FOLLOWING, SqlBaseParser.FORMAT, SqlBaseParser.FUNCTIONS, SqlBaseParser.GRANT, SqlBaseParser.GRANTS, SqlBaseParser.GRAPHVIZ, SqlBaseParser.HOUR, SqlBaseParser.IF, SqlBaseParser.INCLUDING, SqlBaseParser.INPUT, SqlBaseParser.INTEGER, SqlBaseParser.INTERVAL, SqlBaseParser.ISOLATION, SqlBaseParser.LAST, SqlBaseParser.LATERAL, SqlBaseParser.LEVEL, SqlBaseParser.LIMIT, SqlBaseParser.LOGICAL, SqlBaseParser.MAP, SqlBaseParser.MINUTE, SqlBaseParser.MONTH, SqlBaseParser.NFC, SqlBaseParser.NFD, SqlBaseParser.NFKC, SqlBaseParser.NFKD, SqlBaseParser.NO, SqlBaseParser.NULLIF, SqlBaseParser.NULLS, SqlBaseParser.ONLY, SqlBaseParser.OPTION, SqlBaseParser.ORDINALITY, SqlBaseParser.OUTPUT, SqlBaseParser.OVER, SqlBaseParser.PARTITION, SqlBaseParser.PARTITIONS, SqlBaseParser.POSITION, SqlBaseParser.PRECEDING, SqlBaseParser.PRIVILEGES, SqlBaseParser.PROPERTIES, SqlBaseParser.PUBLIC, SqlBaseParser.RANGE, SqlBaseParser.READ, SqlBaseParser.RENAME, SqlBaseParser.REPEATABLE, SqlBaseParser.REPLACE, SqlBaseParser.RESET, SqlBaseParser.RESTRICT, SqlBaseParser.REVOKE, SqlBaseParser.ROLLBACK, SqlBaseParser.ROW, SqlBaseParser.ROWS, SqlBaseParser.SCHEMA, SqlBaseParser.SCHEMAS, SqlBaseParser.SECOND, SqlBaseParser.SERIALIZABLE, SqlBaseParser.SESSION, SqlBaseParser.SET, SqlBaseParser.SETS, SqlBaseParser.SHOW, SqlBaseParser.SMALLINT, SqlBaseParser.SOME, SqlBaseParser.START, SqlBaseParser.STATS, SqlBaseParser.SUBSTRING, SqlBaseParser.SYSTEM, SqlBaseParser.TABLES, SqlBaseParser.TABLESAMPLE, SqlBaseParser.TEXT, SqlBaseParser.TIME, SqlBaseParser.TIMESTAMP, SqlBaseParser.TINYINT, SqlBaseParser.TO, SqlBaseParser.TRANSACTION, SqlBaseParser.TRY_CAST, SqlBaseParser.TYPE, SqlBaseParser.UNBOUNDED, SqlBaseParser.UNCOMMITTED, SqlBaseParser.USE, SqlBaseParser.VALIDATE, SqlBaseParser.VERBOSE, SqlBaseParser.VIEW, SqlBaseParser.WORK, SqlBaseParser.WRITE, SqlBaseParser.YEAR, SqlBaseParser.ZONE, SqlBaseParser.IDENTIFIER, SqlBaseParser.DIGIT_IDENTIFIER, SqlBaseParser.QUOTED_IDENTIFIER, SqlBaseParser.BACKQUOTED_IDENTIFIER]:
                self.enterOuterAlt(localctx, 1)
                self.state = 554
                self.columnDefinition()
                pass
            elif token in [SqlBaseParser.LIKE]:
                self.enterOuterAlt(localctx, 2)
                self.state = 555
                self.likeClause()
                pass
            else:
                raise NoViableAltException(self)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class ColumnDefinitionContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.ColumnDefinitionContext, self).__init__(parent, invokingState)
            self.parser = parser

        def identifier(self):
            return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,0)


        def type(self):
            return self.getTypedRuleContext(SqlBaseParser.TypeContext,0)


        def COMMENT(self):
            return self.getToken(SqlBaseParser.COMMENT, 0)

        def string(self):
            return self.getTypedRuleContext(SqlBaseParser.StringContext,0)


        def getRuleIndex(self):
            return SqlBaseParser.RULE_columnDefinition

        def enterRule(self, listener):
            if hasattr(listener, "enterColumnDefinition"):
                listener.enterColumnDefinition(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitColumnDefinition"):
                listener.exitColumnDefinition(self)




    def columnDefinition(self):

        localctx = SqlBaseParser.ColumnDefinitionContext(self, self._ctx, self.state)
        self.enterRule(localctx, 12, self.RULE_columnDefinition)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 558
            self.identifier()
            self.state = 559
            self.type(0)
            self.state = 562
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==SqlBaseParser.COMMENT:
                self.state = 560
                self.match(SqlBaseParser.COMMENT)
                self.state = 561
                self.string()


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class LikeClauseContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.LikeClauseContext, self).__init__(parent, invokingState)
            self.parser = parser
            self.optionType = None # Token

        def LIKE(self):
            return self.getToken(SqlBaseParser.LIKE, 0)

        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)


        def PROPERTIES(self):
            return self.getToken(SqlBaseParser.PROPERTIES, 0)

        def INCLUDING(self):
            return self.getToken(SqlBaseParser.INCLUDING, 0)

        def EXCLUDING(self):
            return self.getToken(SqlBaseParser.EXCLUDING, 0)

        def getRuleIndex(self):
            return SqlBaseParser.RULE_likeClause

        def enterRule(self, listener):
            if hasattr(listener, "enterLikeClause"):
                listener.enterLikeClause(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitLikeClause"):
                listener.exitLikeClause(self)




    def likeClause(self):

        localctx = SqlBaseParser.LikeClauseContext(self, self._ctx, self.state)
        self.enterRule(localctx, 14, self.RULE_likeClause)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 564
            self.match(SqlBaseParser.LIKE)
            self.state = 565
            self.qualifiedName()
            self.state = 568
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==SqlBaseParser.EXCLUDING or _la==SqlBaseParser.INCLUDING:
                self.state = 566
                localctx.optionType = self._input.LT(1)
                _la = self._input.LA(1)
                if not(_la==SqlBaseParser.EXCLUDING or _la==SqlBaseParser.INCLUDING):
                    localctx.optionType = self._errHandler.recoverInline(self)
                else:
                    self._errHandler.reportMatch(self)
                    self.consume()
                self.state = 567
                self.match(SqlBaseParser.PROPERTIES)


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class PropertiesContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.PropertiesContext, self).__init__(parent, invokingState)
            self.parser = parser

        def property(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.PropertyContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.PropertyContext,i)


        def getRuleIndex(self):
            return SqlBaseParser.RULE_properties

        def enterRule(self, listener):
            if hasattr(listener, "enterProperties"):
                listener.enterProperties(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitProperties"):
                listener.exitProperties(self)




    def properties(self):

        localctx = SqlBaseParser.PropertiesContext(self, self._ctx, self.state)
        self.enterRule(localctx, 16, self.RULE_properties)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 570
            self.match(SqlBaseParser.T__1)
            self.state = 571
            self.property()
            self.state = 576
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            while _la==SqlBaseParser.T__3:
                self.state = 572
                self.match(SqlBaseParser.T__3)
                self.state = 573
                self.property()
                self.state = 578
                self._errHandler.sync(self)
                _la = self._input.LA(1)

            self.state = 579
            self.match(SqlBaseParser.T__2)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class PropertyContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.PropertyContext, self).__init__(parent, invokingState)
            self.parser = parser

        def identifier(self):
            return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,0)


        def EQ(self):
            return self.getToken(SqlBaseParser.EQ, 0)

        def expression(self):
            return self.getTypedRuleContext(SqlBaseParser.ExpressionContext,0)


        def getRuleIndex(self):
            return SqlBaseParser.RULE_property

        def enterRule(self, listener):
            if hasattr(listener, "enterProperty"):
                listener.enterProperty(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitProperty"):
                listener.exitProperty(self)




    def property(self):

        localctx = SqlBaseParser.PropertyContext(self, self._ctx, self.state)
        self.enterRule(localctx, 18, self.RULE_property)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 581
            self.identifier()
            self.state = 582
            self.match(SqlBaseParser.EQ)
            self.state = 583
            self.expression()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class QueryNoWithContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.QueryNoWithContext, self).__init__(parent, invokingState)
            self.parser = parser
            self.limit = None # Token

        def queryTerm(self):
            return self.getTypedRuleContext(SqlBaseParser.QueryTermContext,0)


        def ORDER(self):
            return self.getToken(SqlBaseParser.ORDER, 0)

        def BY(self):
            return self.getToken(SqlBaseParser.BY, 0)

        def sortItem(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.SortItemContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.SortItemContext,i)


        def LIMIT(self):
            return self.getToken(SqlBaseParser.LIMIT, 0)

        def INTEGER_VALUE(self):
            return self.getToken(SqlBaseParser.INTEGER_VALUE, 0)

        def ALL(self):
            return self.getToken(SqlBaseParser.ALL, 0)

        def getRuleIndex(self):
            return SqlBaseParser.RULE_queryNoWith

        def enterRule(self, listener):
            if hasattr(listener, "enterQueryNoWith"):
                listener.enterQueryNoWith(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitQueryNoWith"):
                listener.exitQueryNoWith(self)




    def queryNoWith(self):

        localctx = SqlBaseParser.QueryNoWithContext(self, self._ctx, self.state)
        self.enterRule(localctx, 20, self.RULE_queryNoWith)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 585
            self.queryTerm(0)
            self.state = 596
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==SqlBaseParser.ORDER:
                self.state = 586
                self.match(SqlBaseParser.ORDER)
                self.state = 587
                self.match(SqlBaseParser.BY)
                self.state = 588
                self.sortItem()
                self.state = 593
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                while _la==SqlBaseParser.T__3:
                    self.state = 589
                    self.match(SqlBaseParser.T__3)
                    self.state = 590
                    self.sortItem()
                    self.state = 595
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)



            self.state = 600
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==SqlBaseParser.LIMIT:
                self.state = 598
                self.match(SqlBaseParser.LIMIT)
                self.state = 599
                localctx.limit = self._input.LT(1)
                _la = self._input.LA(1)
                if not(_la==SqlBaseParser.ALL or _la==SqlBaseParser.INTEGER_VALUE):
                    localctx.limit = self._errHandler.recoverInline(self)
                else:
                    self._errHandler.reportMatch(self)
                    self.consume()


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class QueryTermContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.QueryTermContext, self).__init__(parent, invokingState)
            self.parser = parser


        def getRuleIndex(self):
            return SqlBaseParser.RULE_queryTerm

     
        def copyFrom(self, ctx):
            super(SqlBaseParser.QueryTermContext, self).copyFrom(ctx)


    class QueryTermDefaultContext(QueryTermContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.QueryTermContext)
            super(SqlBaseParser.QueryTermDefaultContext, self).__init__(parser)
            self.copyFrom(ctx)

        def queryPrimary(self):
            return self.getTypedRuleContext(SqlBaseParser.QueryPrimaryContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterQueryTermDefault"):
                listener.enterQueryTermDefault(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitQueryTermDefault"):
                listener.exitQueryTermDefault(self)


    class SetOperationContext(QueryTermContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.QueryTermContext)
            super(SqlBaseParser.SetOperationContext, self).__init__(parser)
            self.left = None # QueryTermContext
            self.operator = None # Token
            self.right = None # QueryTermContext
            self.copyFrom(ctx)

        def queryTerm(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.QueryTermContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.QueryTermContext,i)

        def INTERSECT(self):
            return self.getToken(SqlBaseParser.INTERSECT, 0)
        def setQuantifier(self):
            return self.getTypedRuleContext(SqlBaseParser.SetQuantifierContext,0)

        def UNION(self):
            return self.getToken(SqlBaseParser.UNION, 0)
        def EXCEPT(self):
            return self.getToken(SqlBaseParser.EXCEPT, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterSetOperation"):
                listener.enterSetOperation(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitSetOperation"):
                listener.exitSetOperation(self)



    def queryTerm(self, _p=0):
        _parentctx = self._ctx
        _parentState = self.state
        localctx = SqlBaseParser.QueryTermContext(self, self._ctx, _parentState)
        _prevctx = localctx
        _startState = 22
        self.enterRecursionRule(localctx, 22, self.RULE_queryTerm, _p)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            localctx = SqlBaseParser.QueryTermDefaultContext(self, localctx)
            self._ctx = localctx
            _prevctx = localctx

            self.state = 603
            self.queryPrimary()
            self._ctx.stop = self._input.LT(-1)
            self.state = 619
            self._errHandler.sync(self)
            _alt = self._interp.adaptivePredict(self._input,67,self._ctx)
            while _alt!=2 and _alt!=ATN.INVALID_ALT_NUMBER:
                if _alt==1:
                    if self._parseListeners is not None:
                        self.triggerExitRuleEvent()
                    _prevctx = localctx
                    self.state = 617
                    self._errHandler.sync(self)
                    la_ = self._interp.adaptivePredict(self._input,66,self._ctx)
                    if la_ == 1:
                        localctx = SqlBaseParser.SetOperationContext(self, SqlBaseParser.QueryTermContext(self, _parentctx, _parentState))
                        localctx.left = _prevctx
                        self.pushNewRecursionContext(localctx, _startState, self.RULE_queryTerm)
                        self.state = 605
                        if not self.precpred(self._ctx, 2):
                            from antlr4.error.Errors import FailedPredicateException
                            raise FailedPredicateException(self, "self.precpred(self._ctx, 2)")
                        self.state = 606
                        localctx.operator = self.match(SqlBaseParser.INTERSECT)
                        self.state = 608
                        self._errHandler.sync(self)
                        _la = self._input.LA(1)
                        if _la==SqlBaseParser.ALL or _la==SqlBaseParser.DISTINCT:
                            self.state = 607
                            self.setQuantifier()


                        self.state = 610
                        localctx.right = self.queryTerm(3)
                        pass

                    elif la_ == 2:
                        localctx = SqlBaseParser.SetOperationContext(self, SqlBaseParser.QueryTermContext(self, _parentctx, _parentState))
                        localctx.left = _prevctx
                        self.pushNewRecursionContext(localctx, _startState, self.RULE_queryTerm)
                        self.state = 611
                        if not self.precpred(self._ctx, 1):
                            from antlr4.error.Errors import FailedPredicateException
                            raise FailedPredicateException(self, "self.precpred(self._ctx, 1)")
                        self.state = 612
                        localctx.operator = self._input.LT(1)
                        _la = self._input.LA(1)
                        if not(_la==SqlBaseParser.EXCEPT or _la==SqlBaseParser.UNION):
                            localctx.operator = self._errHandler.recoverInline(self)
                        else:
                            self._errHandler.reportMatch(self)
                            self.consume()
                        self.state = 614
                        self._errHandler.sync(self)
                        _la = self._input.LA(1)
                        if _la==SqlBaseParser.ALL or _la==SqlBaseParser.DISTINCT:
                            self.state = 613
                            self.setQuantifier()


                        self.state = 616
                        localctx.right = self.queryTerm(2)
                        pass

             
                self.state = 621
                self._errHandler.sync(self)
                _alt = self._interp.adaptivePredict(self._input,67,self._ctx)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.unrollRecursionContexts(_parentctx)
        return localctx

    class QueryPrimaryContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.QueryPrimaryContext, self).__init__(parent, invokingState)
            self.parser = parser


        def getRuleIndex(self):
            return SqlBaseParser.RULE_queryPrimary

     
        def copyFrom(self, ctx):
            super(SqlBaseParser.QueryPrimaryContext, self).copyFrom(ctx)



    class SubqueryContext(QueryPrimaryContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.QueryPrimaryContext)
            super(SqlBaseParser.SubqueryContext, self).__init__(parser)
            self.copyFrom(ctx)

        def queryNoWith(self):
            return self.getTypedRuleContext(SqlBaseParser.QueryNoWithContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterSubquery"):
                listener.enterSubquery(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitSubquery"):
                listener.exitSubquery(self)


    class QueryPrimaryDefaultContext(QueryPrimaryContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.QueryPrimaryContext)
            super(SqlBaseParser.QueryPrimaryDefaultContext, self).__init__(parser)
            self.copyFrom(ctx)

        def querySpecification(self):
            return self.getTypedRuleContext(SqlBaseParser.QuerySpecificationContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterQueryPrimaryDefault"):
                listener.enterQueryPrimaryDefault(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitQueryPrimaryDefault"):
                listener.exitQueryPrimaryDefault(self)


    class TableContext(QueryPrimaryContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.QueryPrimaryContext)
            super(SqlBaseParser.TableContext, self).__init__(parser)
            self.copyFrom(ctx)

        def TABLE(self):
            return self.getToken(SqlBaseParser.TABLE, 0)
        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterTable"):
                listener.enterTable(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitTable"):
                listener.exitTable(self)


    class InlineTableContext(QueryPrimaryContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.QueryPrimaryContext)
            super(SqlBaseParser.InlineTableContext, self).__init__(parser)
            self.copyFrom(ctx)

        def VALUES(self):
            return self.getToken(SqlBaseParser.VALUES, 0)
        def expression(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.ExpressionContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.ExpressionContext,i)


        def enterRule(self, listener):
            if hasattr(listener, "enterInlineTable"):
                listener.enterInlineTable(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitInlineTable"):
                listener.exitInlineTable(self)



    def queryPrimary(self):

        localctx = SqlBaseParser.QueryPrimaryContext(self, self._ctx, self.state)
        self.enterRule(localctx, 24, self.RULE_queryPrimary)
        try:
            self.state = 638
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [SqlBaseParser.SELECT]:
                localctx = SqlBaseParser.QueryPrimaryDefaultContext(self, localctx)
                self.enterOuterAlt(localctx, 1)
                self.state = 622
                self.querySpecification()
                pass
            elif token in [SqlBaseParser.TABLE]:
                localctx = SqlBaseParser.TableContext(self, localctx)
                self.enterOuterAlt(localctx, 2)
                self.state = 623
                self.match(SqlBaseParser.TABLE)
                self.state = 624
                self.qualifiedName()
                pass
            elif token in [SqlBaseParser.VALUES]:
                localctx = SqlBaseParser.InlineTableContext(self, localctx)
                self.enterOuterAlt(localctx, 3)
                self.state = 625
                self.match(SqlBaseParser.VALUES)
                self.state = 626
                self.expression()
                self.state = 631
                self._errHandler.sync(self)
                _alt = self._interp.adaptivePredict(self._input,68,self._ctx)
                while _alt!=2 and _alt!=ATN.INVALID_ALT_NUMBER:
                    if _alt==1:
                        self.state = 627
                        self.match(SqlBaseParser.T__3)
                        self.state = 628
                        self.expression() 
                    self.state = 633
                    self._errHandler.sync(self)
                    _alt = self._interp.adaptivePredict(self._input,68,self._ctx)

                pass
            elif token in [SqlBaseParser.T__1]:
                localctx = SqlBaseParser.SubqueryContext(self, localctx)
                self.enterOuterAlt(localctx, 4)
                self.state = 634
                self.match(SqlBaseParser.T__1)
                self.state = 635
                self.queryNoWith()
                self.state = 636
                self.match(SqlBaseParser.T__2)
                pass
            else:
                raise NoViableAltException(self)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class SortItemContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.SortItemContext, self).__init__(parent, invokingState)
            self.parser = parser
            self.ordering = None # Token
            self.nullOrdering = None # Token

        def expression(self):
            return self.getTypedRuleContext(SqlBaseParser.ExpressionContext,0)


        def NULLS(self):
            return self.getToken(SqlBaseParser.NULLS, 0)

        def ASC(self):
            return self.getToken(SqlBaseParser.ASC, 0)

        def DESC(self):
            return self.getToken(SqlBaseParser.DESC, 0)

        def FIRST(self):
            return self.getToken(SqlBaseParser.FIRST, 0)

        def LAST(self):
            return self.getToken(SqlBaseParser.LAST, 0)

        def getRuleIndex(self):
            return SqlBaseParser.RULE_sortItem

        def enterRule(self, listener):
            if hasattr(listener, "enterSortItem"):
                listener.enterSortItem(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitSortItem"):
                listener.exitSortItem(self)




    def sortItem(self):

        localctx = SqlBaseParser.SortItemContext(self, self._ctx, self.state)
        self.enterRule(localctx, 26, self.RULE_sortItem)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 640
            self.expression()
            self.state = 642
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==SqlBaseParser.ASC or _la==SqlBaseParser.DESC:
                self.state = 641
                localctx.ordering = self._input.LT(1)
                _la = self._input.LA(1)
                if not(_la==SqlBaseParser.ASC or _la==SqlBaseParser.DESC):
                    localctx.ordering = self._errHandler.recoverInline(self)
                else:
                    self._errHandler.reportMatch(self)
                    self.consume()


            self.state = 646
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==SqlBaseParser.NULLS:
                self.state = 644
                self.match(SqlBaseParser.NULLS)
                self.state = 645
                localctx.nullOrdering = self._input.LT(1)
                _la = self._input.LA(1)
                if not(_la==SqlBaseParser.FIRST or _la==SqlBaseParser.LAST):
                    localctx.nullOrdering = self._errHandler.recoverInline(self)
                else:
                    self._errHandler.reportMatch(self)
                    self.consume()


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class QuerySpecificationContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.QuerySpecificationContext, self).__init__(parent, invokingState)
            self.parser = parser
            self.where = None # BooleanExpressionContext
            self.having = None # BooleanExpressionContext

        def SELECT(self):
            return self.getToken(SqlBaseParser.SELECT, 0)

        def selectItem(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.SelectItemContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.SelectItemContext,i)


        def setQuantifier(self):
            return self.getTypedRuleContext(SqlBaseParser.SetQuantifierContext,0)


        def FROM(self):
            return self.getToken(SqlBaseParser.FROM, 0)

        def relation(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.RelationContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.RelationContext,i)


        def WHERE(self):
            return self.getToken(SqlBaseParser.WHERE, 0)

        def GROUP(self):
            return self.getToken(SqlBaseParser.GROUP, 0)

        def BY(self):
            return self.getToken(SqlBaseParser.BY, 0)

        def groupBy(self):
            return self.getTypedRuleContext(SqlBaseParser.GroupByContext,0)


        def HAVING(self):
            return self.getToken(SqlBaseParser.HAVING, 0)

        def booleanExpression(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.BooleanExpressionContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.BooleanExpressionContext,i)


        def getRuleIndex(self):
            return SqlBaseParser.RULE_querySpecification

        def enterRule(self, listener):
            if hasattr(listener, "enterQuerySpecification"):
                listener.enterQuerySpecification(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitQuerySpecification"):
                listener.exitQuerySpecification(self)




    def querySpecification(self):

        localctx = SqlBaseParser.QuerySpecificationContext(self, self._ctx, self.state)
        self.enterRule(localctx, 28, self.RULE_querySpecification)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 648
            self.match(SqlBaseParser.SELECT)
            self.state = 650
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,72,self._ctx)
            if la_ == 1:
                self.state = 649
                self.setQuantifier()


            self.state = 652
            self.selectItem()
            self.state = 657
            self._errHandler.sync(self)
            _alt = self._interp.adaptivePredict(self._input,73,self._ctx)
            while _alt!=2 and _alt!=ATN.INVALID_ALT_NUMBER:
                if _alt==1:
                    self.state = 653
                    self.match(SqlBaseParser.T__3)
                    self.state = 654
                    self.selectItem() 
                self.state = 659
                self._errHandler.sync(self)
                _alt = self._interp.adaptivePredict(self._input,73,self._ctx)

            self.state = 669
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,75,self._ctx)
            if la_ == 1:
                self.state = 660
                self.match(SqlBaseParser.FROM)
                self.state = 661
                self.relation(0)
                self.state = 666
                self._errHandler.sync(self)
                _alt = self._interp.adaptivePredict(self._input,74,self._ctx)
                while _alt!=2 and _alt!=ATN.INVALID_ALT_NUMBER:
                    if _alt==1:
                        self.state = 662
                        self.match(SqlBaseParser.T__3)
                        self.state = 663
                        self.relation(0) 
                    self.state = 668
                    self._errHandler.sync(self)
                    _alt = self._interp.adaptivePredict(self._input,74,self._ctx)



            self.state = 673
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,76,self._ctx)
            if la_ == 1:
                self.state = 671
                self.match(SqlBaseParser.WHERE)
                self.state = 672
                localctx.where = self.booleanExpression(0)


            self.state = 678
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,77,self._ctx)
            if la_ == 1:
                self.state = 675
                self.match(SqlBaseParser.GROUP)
                self.state = 676
                self.match(SqlBaseParser.BY)
                self.state = 677
                self.groupBy()


            self.state = 682
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,78,self._ctx)
            if la_ == 1:
                self.state = 680
                self.match(SqlBaseParser.HAVING)
                self.state = 681
                localctx.having = self.booleanExpression(0)


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class GroupByContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.GroupByContext, self).__init__(parent, invokingState)
            self.parser = parser

        def groupingElement(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.GroupingElementContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.GroupingElementContext,i)


        def setQuantifier(self):
            return self.getTypedRuleContext(SqlBaseParser.SetQuantifierContext,0)


        def getRuleIndex(self):
            return SqlBaseParser.RULE_groupBy

        def enterRule(self, listener):
            if hasattr(listener, "enterGroupBy"):
                listener.enterGroupBy(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitGroupBy"):
                listener.exitGroupBy(self)




    def groupBy(self):

        localctx = SqlBaseParser.GroupByContext(self, self._ctx, self.state)
        self.enterRule(localctx, 30, self.RULE_groupBy)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 685
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,79,self._ctx)
            if la_ == 1:
                self.state = 684
                self.setQuantifier()


            self.state = 687
            self.groupingElement()
            self.state = 692
            self._errHandler.sync(self)
            _alt = self._interp.adaptivePredict(self._input,80,self._ctx)
            while _alt!=2 and _alt!=ATN.INVALID_ALT_NUMBER:
                if _alt==1:
                    self.state = 688
                    self.match(SqlBaseParser.T__3)
                    self.state = 689
                    self.groupingElement() 
                self.state = 694
                self._errHandler.sync(self)
                _alt = self._interp.adaptivePredict(self._input,80,self._ctx)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class GroupingElementContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.GroupingElementContext, self).__init__(parent, invokingState)
            self.parser = parser


        def getRuleIndex(self):
            return SqlBaseParser.RULE_groupingElement

     
        def copyFrom(self, ctx):
            super(SqlBaseParser.GroupingElementContext, self).copyFrom(ctx)



    class MultipleGroupingSetsContext(GroupingElementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.GroupingElementContext)
            super(SqlBaseParser.MultipleGroupingSetsContext, self).__init__(parser)
            self.copyFrom(ctx)

        def GROUPING(self):
            return self.getToken(SqlBaseParser.GROUPING, 0)
        def SETS(self):
            return self.getToken(SqlBaseParser.SETS, 0)
        def groupingSet(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.GroupingSetContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.GroupingSetContext,i)


        def enterRule(self, listener):
            if hasattr(listener, "enterMultipleGroupingSets"):
                listener.enterMultipleGroupingSets(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitMultipleGroupingSets"):
                listener.exitMultipleGroupingSets(self)


    class SingleGroupingSetContext(GroupingElementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.GroupingElementContext)
            super(SqlBaseParser.SingleGroupingSetContext, self).__init__(parser)
            self.copyFrom(ctx)

        def groupingExpressions(self):
            return self.getTypedRuleContext(SqlBaseParser.GroupingExpressionsContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterSingleGroupingSet"):
                listener.enterSingleGroupingSet(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitSingleGroupingSet"):
                listener.exitSingleGroupingSet(self)


    class CubeContext(GroupingElementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.GroupingElementContext)
            super(SqlBaseParser.CubeContext, self).__init__(parser)
            self.copyFrom(ctx)

        def CUBE(self):
            return self.getToken(SqlBaseParser.CUBE, 0)
        def qualifiedName(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.QualifiedNameContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,i)


        def enterRule(self, listener):
            if hasattr(listener, "enterCube"):
                listener.enterCube(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitCube"):
                listener.exitCube(self)


    class RollupContext(GroupingElementContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.GroupingElementContext)
            super(SqlBaseParser.RollupContext, self).__init__(parser)
            self.copyFrom(ctx)

        def ROLLUP(self):
            return self.getToken(SqlBaseParser.ROLLUP, 0)
        def qualifiedName(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.QualifiedNameContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,i)


        def enterRule(self, listener):
            if hasattr(listener, "enterRollup"):
                listener.enterRollup(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitRollup"):
                listener.exitRollup(self)



    def groupingElement(self):

        localctx = SqlBaseParser.GroupingElementContext(self, self._ctx, self.state)
        self.enterRule(localctx, 32, self.RULE_groupingElement)
        self._la = 0 # Token type
        try:
            self.state = 735
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,86,self._ctx)
            if la_ == 1:
                localctx = SqlBaseParser.SingleGroupingSetContext(self, localctx)
                self.enterOuterAlt(localctx, 1)
                self.state = 695
                self.groupingExpressions()
                pass

            elif la_ == 2:
                localctx = SqlBaseParser.RollupContext(self, localctx)
                self.enterOuterAlt(localctx, 2)
                self.state = 696
                self.match(SqlBaseParser.ROLLUP)
                self.state = 697
                self.match(SqlBaseParser.T__1)
                self.state = 706
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if (((_la) & ~0x3f) == 0 and ((1 << _la) & ((1 << SqlBaseParser.ADD) | (1 << SqlBaseParser.ALL) | (1 << SqlBaseParser.ANALYZE) | (1 << SqlBaseParser.ANY) | (1 << SqlBaseParser.ARRAY) | (1 << SqlBaseParser.ASC) | (1 << SqlBaseParser.AT) | (1 << SqlBaseParser.BERNOULLI) | (1 << SqlBaseParser.CALL) | (1 << SqlBaseParser.CASCADE) | (1 << SqlBaseParser.CATALOGS) | (1 << SqlBaseParser.COALESCE) | (1 << SqlBaseParser.COLUMN) | (1 << SqlBaseParser.COLUMNS) | (1 << SqlBaseParser.COMMENT) | (1 << SqlBaseParser.COMMIT) | (1 << SqlBaseParser.COMMITTED) | (1 << SqlBaseParser.CURRENT) | (1 << SqlBaseParser.DATA) | (1 << SqlBaseParser.DATE) | (1 << SqlBaseParser.DAY) | (1 << SqlBaseParser.DESC) | (1 << SqlBaseParser.DISTRIBUTED) | (1 << SqlBaseParser.EXCLUDING) | (1 << SqlBaseParser.EXPLAIN) | (1 << SqlBaseParser.FILTER))) != 0) or ((((_la - 64)) & ~0x3f) == 0 and ((1 << (_la - 64)) & ((1 << (SqlBaseParser.FIRST - 64)) | (1 << (SqlBaseParser.FOLLOWING - 64)) | (1 << (SqlBaseParser.FORMAT - 64)) | (1 << (SqlBaseParser.FUNCTIONS - 64)) | (1 << (SqlBaseParser.GRANT - 64)) | (1 << (SqlBaseParser.GRANTS - 64)) | (1 << (SqlBaseParser.GRAPHVIZ - 64)) | (1 << (SqlBaseParser.HOUR - 64)) | (1 << (SqlBaseParser.IF - 64)) | (1 << (SqlBaseParser.INCLUDING - 64)) | (1 << (SqlBaseParser.INPUT - 64)) | (1 << (SqlBaseParser.INTEGER - 64)) | (1 << (SqlBaseParser.INTERVAL - 64)) | (1 << (SqlBaseParser.ISOLATION - 64)) | (1 << (SqlBaseParser.LAST - 64)) | (1 << (SqlBaseParser.LATERAL - 64)) | (1 << (SqlBaseParser.LEVEL - 64)) | (1 << (SqlBaseParser.LIMIT - 64)) | (1 << (SqlBaseParser.LOGICAL - 64)) | (1 << (SqlBaseParser.MAP - 64)) | (1 << (SqlBaseParser.MINUTE - 64)) | (1 << (SqlBaseParser.MONTH - 64)) | (1 << (SqlBaseParser.NFC - 64)) | (1 << (SqlBaseParser.NFD - 64)) | (1 << (SqlBaseParser.NFKC - 64)) | (1 << (SqlBaseParser.NFKD - 64)) | (1 << (SqlBaseParser.NO - 64)) | (1 << (SqlBaseParser.NULLIF - 64)) | (1 << (SqlBaseParser.NULLS - 64)) | (1 << (SqlBaseParser.ONLY - 64)) | (1 << (SqlBaseParser.OPTION - 64)) | (1 << (SqlBaseParser.ORDINALITY - 64)) | (1 << (SqlBaseParser.OUTPUT - 64)) | (1 << (SqlBaseParser.OVER - 64)) | (1 << (SqlBaseParser.PARTITION - 64)) | (1 << (SqlBaseParser.PARTITIONS - 64)) | (1 << (SqlBaseParser.POSITION - 64)) | (1 << (SqlBaseParser.PRECEDING - 64)))) != 0) or ((((_la - 128)) & ~0x3f) == 0 and ((1 << (_la - 128)) & ((1 << (SqlBaseParser.PRIVILEGES - 128)) | (1 << (SqlBaseParser.PROPERTIES - 128)) | (1 << (SqlBaseParser.PUBLIC - 128)) | (1 << (SqlBaseParser.RANGE - 128)) | (1 << (SqlBaseParser.READ - 128)) | (1 << (SqlBaseParser.RENAME - 128)) | (1 << (SqlBaseParser.REPEATABLE - 128)) | (1 << (SqlBaseParser.REPLACE - 128)) | (1 << (SqlBaseParser.RESET - 128)) | (1 << (SqlBaseParser.RESTRICT - 128)) | (1 << (SqlBaseParser.REVOKE - 128)) | (1 << (SqlBaseParser.ROLLBACK - 128)) | (1 << (SqlBaseParser.ROW - 128)) | (1 << (SqlBaseParser.ROWS - 128)) | (1 << (SqlBaseParser.SCHEMA - 128)) | (1 << (SqlBaseParser.SCHEMAS - 128)) | (1 << (SqlBaseParser.SECOND - 128)) | (1 << (SqlBaseParser.SERIALIZABLE - 128)) | (1 << (SqlBaseParser.SESSION - 128)) | (1 << (SqlBaseParser.SET - 128)) | (1 << (SqlBaseParser.SETS - 128)) | (1 << (SqlBaseParser.SHOW - 128)) | (1 << (SqlBaseParser.SMALLINT - 128)) | (1 << (SqlBaseParser.SOME - 128)) | (1 << (SqlBaseParser.START - 128)) | (1 << (SqlBaseParser.STATS - 128)) | (1 << (SqlBaseParser.SUBSTRING - 128)) | (1 << (SqlBaseParser.SYSTEM - 128)) | (1 << (SqlBaseParser.TABLES - 128)) | (1 << (SqlBaseParser.TABLESAMPLE - 128)) | (1 << (SqlBaseParser.TEXT - 128)) | (1 << (SqlBaseParser.TIME - 128)) | (1 << (SqlBaseParser.TIMESTAMP - 128)) | (1 << (SqlBaseParser.TINYINT - 128)) | (1 << (SqlBaseParser.TO - 128)) | (1 << (SqlBaseParser.TRANSACTION - 128)) | (1 << (SqlBaseParser.TRY_CAST - 128)) | (1 << (SqlBaseParser.TYPE - 128)) | (1 << (SqlBaseParser.UNBOUNDED - 128)) | (1 << (SqlBaseParser.UNCOMMITTED - 128)) | (1 << (SqlBaseParser.USE - 128)) | (1 << (SqlBaseParser.VALIDATE - 128)) | (1 << (SqlBaseParser.VERBOSE - 128)) | (1 << (SqlBaseParser.VIEW - 128)) | (1 << (SqlBaseParser.WORK - 128)) | (1 << (SqlBaseParser.WRITE - 128)) | (1 << (SqlBaseParser.YEAR - 128)) | (1 << (SqlBaseParser.ZONE - 128)))) != 0) or ((((_la - 209)) & ~0x3f) == 0 and ((1 << (_la - 209)) & ((1 << (SqlBaseParser.IDENTIFIER - 209)) | (1 << (SqlBaseParser.DIGIT_IDENTIFIER - 209)) | (1 << (SqlBaseParser.QUOTED_IDENTIFIER - 209)) | (1 << (SqlBaseParser.BACKQUOTED_IDENTIFIER - 209)))) != 0):
                    self.state = 698
                    self.qualifiedName()
                    self.state = 703
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)
                    while _la==SqlBaseParser.T__3:
                        self.state = 699
                        self.match(SqlBaseParser.T__3)
                        self.state = 700
                        self.qualifiedName()
                        self.state = 705
                        self._errHandler.sync(self)
                        _la = self._input.LA(1)



                self.state = 708
                self.match(SqlBaseParser.T__2)
                pass

            elif la_ == 3:
                localctx = SqlBaseParser.CubeContext(self, localctx)
                self.enterOuterAlt(localctx, 3)
                self.state = 709
                self.match(SqlBaseParser.CUBE)
                self.state = 710
                self.match(SqlBaseParser.T__1)
                self.state = 719
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if (((_la) & ~0x3f) == 0 and ((1 << _la) & ((1 << SqlBaseParser.ADD) | (1 << SqlBaseParser.ALL) | (1 << SqlBaseParser.ANALYZE) | (1 << SqlBaseParser.ANY) | (1 << SqlBaseParser.ARRAY) | (1 << SqlBaseParser.ASC) | (1 << SqlBaseParser.AT) | (1 << SqlBaseParser.BERNOULLI) | (1 << SqlBaseParser.CALL) | (1 << SqlBaseParser.CASCADE) | (1 << SqlBaseParser.CATALOGS) | (1 << SqlBaseParser.COALESCE) | (1 << SqlBaseParser.COLUMN) | (1 << SqlBaseParser.COLUMNS) | (1 << SqlBaseParser.COMMENT) | (1 << SqlBaseParser.COMMIT) | (1 << SqlBaseParser.COMMITTED) | (1 << SqlBaseParser.CURRENT) | (1 << SqlBaseParser.DATA) | (1 << SqlBaseParser.DATE) | (1 << SqlBaseParser.DAY) | (1 << SqlBaseParser.DESC) | (1 << SqlBaseParser.DISTRIBUTED) | (1 << SqlBaseParser.EXCLUDING) | (1 << SqlBaseParser.EXPLAIN) | (1 << SqlBaseParser.FILTER))) != 0) or ((((_la - 64)) & ~0x3f) == 0 and ((1 << (_la - 64)) & ((1 << (SqlBaseParser.FIRST - 64)) | (1 << (SqlBaseParser.FOLLOWING - 64)) | (1 << (SqlBaseParser.FORMAT - 64)) | (1 << (SqlBaseParser.FUNCTIONS - 64)) | (1 << (SqlBaseParser.GRANT - 64)) | (1 << (SqlBaseParser.GRANTS - 64)) | (1 << (SqlBaseParser.GRAPHVIZ - 64)) | (1 << (SqlBaseParser.HOUR - 64)) | (1 << (SqlBaseParser.IF - 64)) | (1 << (SqlBaseParser.INCLUDING - 64)) | (1 << (SqlBaseParser.INPUT - 64)) | (1 << (SqlBaseParser.INTEGER - 64)) | (1 << (SqlBaseParser.INTERVAL - 64)) | (1 << (SqlBaseParser.ISOLATION - 64)) | (1 << (SqlBaseParser.LAST - 64)) | (1 << (SqlBaseParser.LATERAL - 64)) | (1 << (SqlBaseParser.LEVEL - 64)) | (1 << (SqlBaseParser.LIMIT - 64)) | (1 << (SqlBaseParser.LOGICAL - 64)) | (1 << (SqlBaseParser.MAP - 64)) | (1 << (SqlBaseParser.MINUTE - 64)) | (1 << (SqlBaseParser.MONTH - 64)) | (1 << (SqlBaseParser.NFC - 64)) | (1 << (SqlBaseParser.NFD - 64)) | (1 << (SqlBaseParser.NFKC - 64)) | (1 << (SqlBaseParser.NFKD - 64)) | (1 << (SqlBaseParser.NO - 64)) | (1 << (SqlBaseParser.NULLIF - 64)) | (1 << (SqlBaseParser.NULLS - 64)) | (1 << (SqlBaseParser.ONLY - 64)) | (1 << (SqlBaseParser.OPTION - 64)) | (1 << (SqlBaseParser.ORDINALITY - 64)) | (1 << (SqlBaseParser.OUTPUT - 64)) | (1 << (SqlBaseParser.OVER - 64)) | (1 << (SqlBaseParser.PARTITION - 64)) | (1 << (SqlBaseParser.PARTITIONS - 64)) | (1 << (SqlBaseParser.POSITION - 64)) | (1 << (SqlBaseParser.PRECEDING - 64)))) != 0) or ((((_la - 128)) & ~0x3f) == 0 and ((1 << (_la - 128)) & ((1 << (SqlBaseParser.PRIVILEGES - 128)) | (1 << (SqlBaseParser.PROPERTIES - 128)) | (1 << (SqlBaseParser.PUBLIC - 128)) | (1 << (SqlBaseParser.RANGE - 128)) | (1 << (SqlBaseParser.READ - 128)) | (1 << (SqlBaseParser.RENAME - 128)) | (1 << (SqlBaseParser.REPEATABLE - 128)) | (1 << (SqlBaseParser.REPLACE - 128)) | (1 << (SqlBaseParser.RESET - 128)) | (1 << (SqlBaseParser.RESTRICT - 128)) | (1 << (SqlBaseParser.REVOKE - 128)) | (1 << (SqlBaseParser.ROLLBACK - 128)) | (1 << (SqlBaseParser.ROW - 128)) | (1 << (SqlBaseParser.ROWS - 128)) | (1 << (SqlBaseParser.SCHEMA - 128)) | (1 << (SqlBaseParser.SCHEMAS - 128)) | (1 << (SqlBaseParser.SECOND - 128)) | (1 << (SqlBaseParser.SERIALIZABLE - 128)) | (1 << (SqlBaseParser.SESSION - 128)) | (1 << (SqlBaseParser.SET - 128)) | (1 << (SqlBaseParser.SETS - 128)) | (1 << (SqlBaseParser.SHOW - 128)) | (1 << (SqlBaseParser.SMALLINT - 128)) | (1 << (SqlBaseParser.SOME - 128)) | (1 << (SqlBaseParser.START - 128)) | (1 << (SqlBaseParser.STATS - 128)) | (1 << (SqlBaseParser.SUBSTRING - 128)) | (1 << (SqlBaseParser.SYSTEM - 128)) | (1 << (SqlBaseParser.TABLES - 128)) | (1 << (SqlBaseParser.TABLESAMPLE - 128)) | (1 << (SqlBaseParser.TEXT - 128)) | (1 << (SqlBaseParser.TIME - 128)) | (1 << (SqlBaseParser.TIMESTAMP - 128)) | (1 << (SqlBaseParser.TINYINT - 128)) | (1 << (SqlBaseParser.TO - 128)) | (1 << (SqlBaseParser.TRANSACTION - 128)) | (1 << (SqlBaseParser.TRY_CAST - 128)) | (1 << (SqlBaseParser.TYPE - 128)) | (1 << (SqlBaseParser.UNBOUNDED - 128)) | (1 << (SqlBaseParser.UNCOMMITTED - 128)) | (1 << (SqlBaseParser.USE - 128)) | (1 << (SqlBaseParser.VALIDATE - 128)) | (1 << (SqlBaseParser.VERBOSE - 128)) | (1 << (SqlBaseParser.VIEW - 128)) | (1 << (SqlBaseParser.WORK - 128)) | (1 << (SqlBaseParser.WRITE - 128)) | (1 << (SqlBaseParser.YEAR - 128)) | (1 << (SqlBaseParser.ZONE - 128)))) != 0) or ((((_la - 209)) & ~0x3f) == 0 and ((1 << (_la - 209)) & ((1 << (SqlBaseParser.IDENTIFIER - 209)) | (1 << (SqlBaseParser.DIGIT_IDENTIFIER - 209)) | (1 << (SqlBaseParser.QUOTED_IDENTIFIER - 209)) | (1 << (SqlBaseParser.BACKQUOTED_IDENTIFIER - 209)))) != 0):
                    self.state = 711
                    self.qualifiedName()
                    self.state = 716
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)
                    while _la==SqlBaseParser.T__3:
                        self.state = 712
                        self.match(SqlBaseParser.T__3)
                        self.state = 713
                        self.qualifiedName()
                        self.state = 718
                        self._errHandler.sync(self)
                        _la = self._input.LA(1)



                self.state = 721
                self.match(SqlBaseParser.T__2)
                pass

            elif la_ == 4:
                localctx = SqlBaseParser.MultipleGroupingSetsContext(self, localctx)
                self.enterOuterAlt(localctx, 4)
                self.state = 722
                self.match(SqlBaseParser.GROUPING)
                self.state = 723
                self.match(SqlBaseParser.SETS)
                self.state = 724
                self.match(SqlBaseParser.T__1)
                self.state = 725
                self.groupingSet()
                self.state = 730
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                while _la==SqlBaseParser.T__3:
                    self.state = 726
                    self.match(SqlBaseParser.T__3)
                    self.state = 727
                    self.groupingSet()
                    self.state = 732
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)

                self.state = 733
                self.match(SqlBaseParser.T__2)
                pass


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class GroupingExpressionsContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.GroupingExpressionsContext, self).__init__(parent, invokingState)
            self.parser = parser

        def expression(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.ExpressionContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.ExpressionContext,i)


        def getRuleIndex(self):
            return SqlBaseParser.RULE_groupingExpressions

        def enterRule(self, listener):
            if hasattr(listener, "enterGroupingExpressions"):
                listener.enterGroupingExpressions(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitGroupingExpressions"):
                listener.exitGroupingExpressions(self)




    def groupingExpressions(self):

        localctx = SqlBaseParser.GroupingExpressionsContext(self, self._ctx, self.state)
        self.enterRule(localctx, 34, self.RULE_groupingExpressions)
        self._la = 0 # Token type
        try:
            self.state = 750
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,89,self._ctx)
            if la_ == 1:
                self.enterOuterAlt(localctx, 1)
                self.state = 737
                self.match(SqlBaseParser.T__1)
                self.state = 746
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if (((_la) & ~0x3f) == 0 and ((1 << _la) & ((1 << SqlBaseParser.T__1) | (1 << SqlBaseParser.T__4) | (1 << SqlBaseParser.ADD) | (1 << SqlBaseParser.ALL) | (1 << SqlBaseParser.ANALYZE) | (1 << SqlBaseParser.ANY) | (1 << SqlBaseParser.ARRAY) | (1 << SqlBaseParser.ASC) | (1 << SqlBaseParser.AT) | (1 << SqlBaseParser.BERNOULLI) | (1 << SqlBaseParser.CALL) | (1 << SqlBaseParser.CASCADE) | (1 << SqlBaseParser.CASE) | (1 << SqlBaseParser.CAST) | (1 << SqlBaseParser.CATALOGS) | (1 << SqlBaseParser.COALESCE) | (1 << SqlBaseParser.COLUMN) | (1 << SqlBaseParser.COLUMNS) | (1 << SqlBaseParser.COMMENT) | (1 << SqlBaseParser.COMMIT) | (1 << SqlBaseParser.COMMITTED) | (1 << SqlBaseParser.CURRENT) | (1 << SqlBaseParser.CURRENT_DATE) | (1 << SqlBaseParser.CURRENT_TIME) | (1 << SqlBaseParser.CURRENT_TIMESTAMP) | (1 << SqlBaseParser.CURRENT_USER) | (1 << SqlBaseParser.DATA) | (1 << SqlBaseParser.DATE) | (1 << SqlBaseParser.DAY) | (1 << SqlBaseParser.DESC) | (1 << SqlBaseParser.DISTRIBUTED) | (1 << SqlBaseParser.EXCLUDING) | (1 << SqlBaseParser.EXISTS) | (1 << SqlBaseParser.EXPLAIN) | (1 << SqlBaseParser.EXTRACT) | (1 << SqlBaseParser.FALSE) | (1 << SqlBaseParser.FILTER))) != 0) or ((((_la - 64)) & ~0x3f) == 0 and ((1 << (_la - 64)) & ((1 << (SqlBaseParser.FIRST - 64)) | (1 << (SqlBaseParser.FOLLOWING - 64)) | (1 << (SqlBaseParser.FORMAT - 64)) | (1 << (SqlBaseParser.FUNCTIONS - 64)) | (1 << (SqlBaseParser.GRANT - 64)) | (1 << (SqlBaseParser.GRANTS - 64)) | (1 << (SqlBaseParser.GRAPHVIZ - 64)) | (1 << (SqlBaseParser.GROUPING - 64)) | (1 << (SqlBaseParser.HOUR - 64)) | (1 << (SqlBaseParser.IF - 64)) | (1 << (SqlBaseParser.INCLUDING - 64)) | (1 << (SqlBaseParser.INPUT - 64)) | (1 << (SqlBaseParser.INTEGER - 64)) | (1 << (SqlBaseParser.INTERVAL - 64)) | (1 << (SqlBaseParser.ISOLATION - 64)) | (1 << (SqlBaseParser.LAST - 64)) | (1 << (SqlBaseParser.LATERAL - 64)) | (1 << (SqlBaseParser.LEVEL - 64)) | (1 << (SqlBaseParser.LIMIT - 64)) | (1 << (SqlBaseParser.LOCALTIME - 64)) | (1 << (SqlBaseParser.LOCALTIMESTAMP - 64)) | (1 << (SqlBaseParser.LOGICAL - 64)) | (1 << (SqlBaseParser.MAP - 64)) | (1 << (SqlBaseParser.MINUTE - 64)) | (1 << (SqlBaseParser.MONTH - 64)) | (1 << (SqlBaseParser.NFC - 64)) | (1 << (SqlBaseParser.NFD - 64)) | (1 << (SqlBaseParser.NFKC - 64)) | (1 << (SqlBaseParser.NFKD - 64)) | (1 << (SqlBaseParser.NO - 64)) | (1 << (SqlBaseParser.NORMALIZE - 64)) | (1 << (SqlBaseParser.NOT - 64)) | (1 << (SqlBaseParser.NULL - 64)) | (1 << (SqlBaseParser.NULLIF - 64)) | (1 << (SqlBaseParser.NULLS - 64)) | (1 << (SqlBaseParser.ONLY - 64)) | (1 << (SqlBaseParser.OPTION - 64)) | (1 << (SqlBaseParser.ORDINALITY - 64)) | (1 << (SqlBaseParser.OUTPUT - 64)) | (1 << (SqlBaseParser.OVER - 64)) | (1 << (SqlBaseParser.PARTITION - 64)) | (1 << (SqlBaseParser.PARTITIONS - 64)) | (1 << (SqlBaseParser.POSITION - 64)) | (1 << (SqlBaseParser.PRECEDING - 64)))) != 0) or ((((_la - 128)) & ~0x3f) == 0 and ((1 << (_la - 128)) & ((1 << (SqlBaseParser.PRIVILEGES - 128)) | (1 << (SqlBaseParser.PROPERTIES - 128)) | (1 << (SqlBaseParser.PUBLIC - 128)) | (1 << (SqlBaseParser.RANGE - 128)) | (1 << (SqlBaseParser.READ - 128)) | (1 << (SqlBaseParser.RENAME - 128)) | (1 << (SqlBaseParser.REPEATABLE - 128)) | (1 << (SqlBaseParser.REPLACE - 128)) | (1 << (SqlBaseParser.RESET - 128)) | (1 << (SqlBaseParser.RESTRICT - 128)) | (1 << (SqlBaseParser.REVOKE - 128)) | (1 << (SqlBaseParser.ROLLBACK - 128)) | (1 << (SqlBaseParser.ROW - 128)) | (1 << (SqlBaseParser.ROWS - 128)) | (1 << (SqlBaseParser.SCHEMA - 128)) | (1 << (SqlBaseParser.SCHEMAS - 128)) | (1 << (SqlBaseParser.SECOND - 128)) | (1 << (SqlBaseParser.SERIALIZABLE - 128)) | (1 << (SqlBaseParser.SESSION - 128)) | (1 << (SqlBaseParser.SET - 128)) | (1 << (SqlBaseParser.SETS - 128)) | (1 << (SqlBaseParser.SHOW - 128)) | (1 << (SqlBaseParser.SMALLINT - 128)) | (1 << (SqlBaseParser.SOME - 128)) | (1 << (SqlBaseParser.START - 128)) | (1 << (SqlBaseParser.STATS - 128)) | (1 << (SqlBaseParser.SUBSTRING - 128)) | (1 << (SqlBaseParser.SYSTEM - 128)) | (1 << (SqlBaseParser.TABLES - 128)) | (1 << (SqlBaseParser.TABLESAMPLE - 128)) | (1 << (SqlBaseParser.TEXT - 128)) | (1 << (SqlBaseParser.TIME - 128)) | (1 << (SqlBaseParser.TIMESTAMP - 128)) | (1 << (SqlBaseParser.TINYINT - 128)) | (1 << (SqlBaseParser.TO - 128)) | (1 << (SqlBaseParser.TRANSACTION - 128)) | (1 << (SqlBaseParser.TRUE - 128)) | (1 << (SqlBaseParser.TRY_CAST - 128)) | (1 << (SqlBaseParser.TYPE - 128)) | (1 << (SqlBaseParser.UNBOUNDED - 128)) | (1 << (SqlBaseParser.UNCOMMITTED - 128)) | (1 << (SqlBaseParser.USE - 128)) | (1 << (SqlBaseParser.VALIDATE - 128)) | (1 << (SqlBaseParser.VERBOSE - 128)) | (1 << (SqlBaseParser.VIEW - 128)) | (1 << (SqlBaseParser.WORK - 128)) | (1 << (SqlBaseParser.WRITE - 128)) | (1 << (SqlBaseParser.YEAR - 128)) | (1 << (SqlBaseParser.ZONE - 128)))) != 0) or ((((_la - 197)) & ~0x3f) == 0 and ((1 << (_la - 197)) & ((1 << (SqlBaseParser.PLUS - 197)) | (1 << (SqlBaseParser.MINUS - 197)) | (1 << (SqlBaseParser.STRING - 197)) | (1 << (SqlBaseParser.UNICODE_STRING - 197)) | (1 << (SqlBaseParser.BINARY_LITERAL - 197)) | (1 << (SqlBaseParser.INTEGER_VALUE - 197)) | (1 << (SqlBaseParser.DECIMAL_VALUE - 197)) | (1 << (SqlBaseParser.DOUBLE_VALUE - 197)) | (1 << (SqlBaseParser.IDENTIFIER - 197)) | (1 << (SqlBaseParser.DIGIT_IDENTIFIER - 197)) | (1 << (SqlBaseParser.QUOTED_IDENTIFIER - 197)) | (1 << (SqlBaseParser.BACKQUOTED_IDENTIFIER - 197)) | (1 << (SqlBaseParser.DOUBLE_PRECISION - 197)))) != 0):
                    self.state = 738
                    self.expression()
                    self.state = 743
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)
                    while _la==SqlBaseParser.T__3:
                        self.state = 739
                        self.match(SqlBaseParser.T__3)
                        self.state = 740
                        self.expression()
                        self.state = 745
                        self._errHandler.sync(self)
                        _la = self._input.LA(1)



                self.state = 748
                self.match(SqlBaseParser.T__2)
                pass

            elif la_ == 2:
                self.enterOuterAlt(localctx, 2)
                self.state = 749
                self.expression()
                pass


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class GroupingSetContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.GroupingSetContext, self).__init__(parent, invokingState)
            self.parser = parser

        def qualifiedName(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.QualifiedNameContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,i)


        def getRuleIndex(self):
            return SqlBaseParser.RULE_groupingSet

        def enterRule(self, listener):
            if hasattr(listener, "enterGroupingSet"):
                listener.enterGroupingSet(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitGroupingSet"):
                listener.exitGroupingSet(self)




    def groupingSet(self):

        localctx = SqlBaseParser.GroupingSetContext(self, self._ctx, self.state)
        self.enterRule(localctx, 36, self.RULE_groupingSet)
        self._la = 0 # Token type
        try:
            self.state = 765
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [SqlBaseParser.T__1]:
                self.enterOuterAlt(localctx, 1)
                self.state = 752
                self.match(SqlBaseParser.T__1)
                self.state = 761
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if (((_la) & ~0x3f) == 0 and ((1 << _la) & ((1 << SqlBaseParser.ADD) | (1 << SqlBaseParser.ALL) | (1 << SqlBaseParser.ANALYZE) | (1 << SqlBaseParser.ANY) | (1 << SqlBaseParser.ARRAY) | (1 << SqlBaseParser.ASC) | (1 << SqlBaseParser.AT) | (1 << SqlBaseParser.BERNOULLI) | (1 << SqlBaseParser.CALL) | (1 << SqlBaseParser.CASCADE) | (1 << SqlBaseParser.CATALOGS) | (1 << SqlBaseParser.COALESCE) | (1 << SqlBaseParser.COLUMN) | (1 << SqlBaseParser.COLUMNS) | (1 << SqlBaseParser.COMMENT) | (1 << SqlBaseParser.COMMIT) | (1 << SqlBaseParser.COMMITTED) | (1 << SqlBaseParser.CURRENT) | (1 << SqlBaseParser.DATA) | (1 << SqlBaseParser.DATE) | (1 << SqlBaseParser.DAY) | (1 << SqlBaseParser.DESC) | (1 << SqlBaseParser.DISTRIBUTED) | (1 << SqlBaseParser.EXCLUDING) | (1 << SqlBaseParser.EXPLAIN) | (1 << SqlBaseParser.FILTER))) != 0) or ((((_la - 64)) & ~0x3f) == 0 and ((1 << (_la - 64)) & ((1 << (SqlBaseParser.FIRST - 64)) | (1 << (SqlBaseParser.FOLLOWING - 64)) | (1 << (SqlBaseParser.FORMAT - 64)) | (1 << (SqlBaseParser.FUNCTIONS - 64)) | (1 << (SqlBaseParser.GRANT - 64)) | (1 << (SqlBaseParser.GRANTS - 64)) | (1 << (SqlBaseParser.GRAPHVIZ - 64)) | (1 << (SqlBaseParser.HOUR - 64)) | (1 << (SqlBaseParser.IF - 64)) | (1 << (SqlBaseParser.INCLUDING - 64)) | (1 << (SqlBaseParser.INPUT - 64)) | (1 << (SqlBaseParser.INTEGER - 64)) | (1 << (SqlBaseParser.INTERVAL - 64)) | (1 << (SqlBaseParser.ISOLATION - 64)) | (1 << (SqlBaseParser.LAST - 64)) | (1 << (SqlBaseParser.LATERAL - 64)) | (1 << (SqlBaseParser.LEVEL - 64)) | (1 << (SqlBaseParser.LIMIT - 64)) | (1 << (SqlBaseParser.LOGICAL - 64)) | (1 << (SqlBaseParser.MAP - 64)) | (1 << (SqlBaseParser.MINUTE - 64)) | (1 << (SqlBaseParser.MONTH - 64)) | (1 << (SqlBaseParser.NFC - 64)) | (1 << (SqlBaseParser.NFD - 64)) | (1 << (SqlBaseParser.NFKC - 64)) | (1 << (SqlBaseParser.NFKD - 64)) | (1 << (SqlBaseParser.NO - 64)) | (1 << (SqlBaseParser.NULLIF - 64)) | (1 << (SqlBaseParser.NULLS - 64)) | (1 << (SqlBaseParser.ONLY - 64)) | (1 << (SqlBaseParser.OPTION - 64)) | (1 << (SqlBaseParser.ORDINALITY - 64)) | (1 << (SqlBaseParser.OUTPUT - 64)) | (1 << (SqlBaseParser.OVER - 64)) | (1 << (SqlBaseParser.PARTITION - 64)) | (1 << (SqlBaseParser.PARTITIONS - 64)) | (1 << (SqlBaseParser.POSITION - 64)) | (1 << (SqlBaseParser.PRECEDING - 64)))) != 0) or ((((_la - 128)) & ~0x3f) == 0 and ((1 << (_la - 128)) & ((1 << (SqlBaseParser.PRIVILEGES - 128)) | (1 << (SqlBaseParser.PROPERTIES - 128)) | (1 << (SqlBaseParser.PUBLIC - 128)) | (1 << (SqlBaseParser.RANGE - 128)) | (1 << (SqlBaseParser.READ - 128)) | (1 << (SqlBaseParser.RENAME - 128)) | (1 << (SqlBaseParser.REPEATABLE - 128)) | (1 << (SqlBaseParser.REPLACE - 128)) | (1 << (SqlBaseParser.RESET - 128)) | (1 << (SqlBaseParser.RESTRICT - 128)) | (1 << (SqlBaseParser.REVOKE - 128)) | (1 << (SqlBaseParser.ROLLBACK - 128)) | (1 << (SqlBaseParser.ROW - 128)) | (1 << (SqlBaseParser.ROWS - 128)) | (1 << (SqlBaseParser.SCHEMA - 128)) | (1 << (SqlBaseParser.SCHEMAS - 128)) | (1 << (SqlBaseParser.SECOND - 128)) | (1 << (SqlBaseParser.SERIALIZABLE - 128)) | (1 << (SqlBaseParser.SESSION - 128)) | (1 << (SqlBaseParser.SET - 128)) | (1 << (SqlBaseParser.SETS - 128)) | (1 << (SqlBaseParser.SHOW - 128)) | (1 << (SqlBaseParser.SMALLINT - 128)) | (1 << (SqlBaseParser.SOME - 128)) | (1 << (SqlBaseParser.START - 128)) | (1 << (SqlBaseParser.STATS - 128)) | (1 << (SqlBaseParser.SUBSTRING - 128)) | (1 << (SqlBaseParser.SYSTEM - 128)) | (1 << (SqlBaseParser.TABLES - 128)) | (1 << (SqlBaseParser.TABLESAMPLE - 128)) | (1 << (SqlBaseParser.TEXT - 128)) | (1 << (SqlBaseParser.TIME - 128)) | (1 << (SqlBaseParser.TIMESTAMP - 128)) | (1 << (SqlBaseParser.TINYINT - 128)) | (1 << (SqlBaseParser.TO - 128)) | (1 << (SqlBaseParser.TRANSACTION - 128)) | (1 << (SqlBaseParser.TRY_CAST - 128)) | (1 << (SqlBaseParser.TYPE - 128)) | (1 << (SqlBaseParser.UNBOUNDED - 128)) | (1 << (SqlBaseParser.UNCOMMITTED - 128)) | (1 << (SqlBaseParser.USE - 128)) | (1 << (SqlBaseParser.VALIDATE - 128)) | (1 << (SqlBaseParser.VERBOSE - 128)) | (1 << (SqlBaseParser.VIEW - 128)) | (1 << (SqlBaseParser.WORK - 128)) | (1 << (SqlBaseParser.WRITE - 128)) | (1 << (SqlBaseParser.YEAR - 128)) | (1 << (SqlBaseParser.ZONE - 128)))) != 0) or ((((_la - 209)) & ~0x3f) == 0 and ((1 << (_la - 209)) & ((1 << (SqlBaseParser.IDENTIFIER - 209)) | (1 << (SqlBaseParser.DIGIT_IDENTIFIER - 209)) | (1 << (SqlBaseParser.QUOTED_IDENTIFIER - 209)) | (1 << (SqlBaseParser.BACKQUOTED_IDENTIFIER - 209)))) != 0):
                    self.state = 753
                    self.qualifiedName()
                    self.state = 758
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)
                    while _la==SqlBaseParser.T__3:
                        self.state = 754
                        self.match(SqlBaseParser.T__3)
                        self.state = 755
                        self.qualifiedName()
                        self.state = 760
                        self._errHandler.sync(self)
                        _la = self._input.LA(1)



                self.state = 763
                self.match(SqlBaseParser.T__2)
                pass
            elif token in [SqlBaseParser.ADD, SqlBaseParser.ALL, SqlBaseParser.ANALYZE, SqlBaseParser.ANY, SqlBaseParser.ARRAY, SqlBaseParser.ASC, SqlBaseParser.AT, SqlBaseParser.BERNOULLI, SqlBaseParser.CALL, SqlBaseParser.CASCADE, SqlBaseParser.CATALOGS, SqlBaseParser.COALESCE, SqlBaseParser.COLUMN, SqlBaseParser.COLUMNS, SqlBaseParser.COMMENT, SqlBaseParser.COMMIT, SqlBaseParser.COMMITTED, SqlBaseParser.CURRENT, SqlBaseParser.DATA, SqlBaseParser.DATE, SqlBaseParser.DAY, SqlBaseParser.DESC, SqlBaseParser.DISTRIBUTED, SqlBaseParser.EXCLUDING, SqlBaseParser.EXPLAIN, SqlBaseParser.FILTER, SqlBaseParser.FIRST, SqlBaseParser.FOLLOWING, SqlBaseParser.FORMAT, SqlBaseParser.FUNCTIONS, SqlBaseParser.GRANT, SqlBaseParser.GRANTS, SqlBaseParser.GRAPHVIZ, SqlBaseParser.HOUR, SqlBaseParser.IF, SqlBaseParser.INCLUDING, SqlBaseParser.INPUT, SqlBaseParser.INTEGER, SqlBaseParser.INTERVAL, SqlBaseParser.ISOLATION, SqlBaseParser.LAST, SqlBaseParser.LATERAL, SqlBaseParser.LEVEL, SqlBaseParser.LIMIT, SqlBaseParser.LOGICAL, SqlBaseParser.MAP, SqlBaseParser.MINUTE, SqlBaseParser.MONTH, SqlBaseParser.NFC, SqlBaseParser.NFD, SqlBaseParser.NFKC, SqlBaseParser.NFKD, SqlBaseParser.NO, SqlBaseParser.NULLIF, SqlBaseParser.NULLS, SqlBaseParser.ONLY, SqlBaseParser.OPTION, SqlBaseParser.ORDINALITY, SqlBaseParser.OUTPUT, SqlBaseParser.OVER, SqlBaseParser.PARTITION, SqlBaseParser.PARTITIONS, SqlBaseParser.POSITION, SqlBaseParser.PRECEDING, SqlBaseParser.PRIVILEGES, SqlBaseParser.PROPERTIES, SqlBaseParser.PUBLIC, SqlBaseParser.RANGE, SqlBaseParser.READ, SqlBaseParser.RENAME, SqlBaseParser.REPEATABLE, SqlBaseParser.REPLACE, SqlBaseParser.RESET, SqlBaseParser.RESTRICT, SqlBaseParser.REVOKE, SqlBaseParser.ROLLBACK, SqlBaseParser.ROW, SqlBaseParser.ROWS, SqlBaseParser.SCHEMA, SqlBaseParser.SCHEMAS, SqlBaseParser.SECOND, SqlBaseParser.SERIALIZABLE, SqlBaseParser.SESSION, SqlBaseParser.SET, SqlBaseParser.SETS, SqlBaseParser.SHOW, SqlBaseParser.SMALLINT, SqlBaseParser.SOME, SqlBaseParser.START, SqlBaseParser.STATS, SqlBaseParser.SUBSTRING, SqlBaseParser.SYSTEM, SqlBaseParser.TABLES, SqlBaseParser.TABLESAMPLE, SqlBaseParser.TEXT, SqlBaseParser.TIME, SqlBaseParser.TIMESTAMP, SqlBaseParser.TINYINT, SqlBaseParser.TO, SqlBaseParser.TRANSACTION, SqlBaseParser.TRY_CAST, SqlBaseParser.TYPE, SqlBaseParser.UNBOUNDED, SqlBaseParser.UNCOMMITTED, SqlBaseParser.USE, SqlBaseParser.VALIDATE, SqlBaseParser.VERBOSE, SqlBaseParser.VIEW, SqlBaseParser.WORK, SqlBaseParser.WRITE, SqlBaseParser.YEAR, SqlBaseParser.ZONE, SqlBaseParser.IDENTIFIER, SqlBaseParser.DIGIT_IDENTIFIER, SqlBaseParser.QUOTED_IDENTIFIER, SqlBaseParser.BACKQUOTED_IDENTIFIER]:
                self.enterOuterAlt(localctx, 2)
                self.state = 764
                self.qualifiedName()
                pass
            else:
                raise NoViableAltException(self)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class NamedQueryContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.NamedQueryContext, self).__init__(parent, invokingState)
            self.parser = parser
            self.name = None # IdentifierContext

        def AS(self):
            return self.getToken(SqlBaseParser.AS, 0)

        def query(self):
            return self.getTypedRuleContext(SqlBaseParser.QueryContext,0)


        def identifier(self):
            return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,0)


        def columnAliases(self):
            return self.getTypedRuleContext(SqlBaseParser.ColumnAliasesContext,0)


        def getRuleIndex(self):
            return SqlBaseParser.RULE_namedQuery

        def enterRule(self, listener):
            if hasattr(listener, "enterNamedQuery"):
                listener.enterNamedQuery(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitNamedQuery"):
                listener.exitNamedQuery(self)




    def namedQuery(self):

        localctx = SqlBaseParser.NamedQueryContext(self, self._ctx, self.state)
        self.enterRule(localctx, 38, self.RULE_namedQuery)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 767
            localctx.name = self.identifier()
            self.state = 769
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==SqlBaseParser.T__1:
                self.state = 768
                self.columnAliases()


            self.state = 771
            self.match(SqlBaseParser.AS)
            self.state = 772
            self.match(SqlBaseParser.T__1)
            self.state = 773
            self.query()
            self.state = 774
            self.match(SqlBaseParser.T__2)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class SetQuantifierContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.SetQuantifierContext, self).__init__(parent, invokingState)
            self.parser = parser

        def DISTINCT(self):
            return self.getToken(SqlBaseParser.DISTINCT, 0)

        def ALL(self):
            return self.getToken(SqlBaseParser.ALL, 0)

        def getRuleIndex(self):
            return SqlBaseParser.RULE_setQuantifier

        def enterRule(self, listener):
            if hasattr(listener, "enterSetQuantifier"):
                listener.enterSetQuantifier(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitSetQuantifier"):
                listener.exitSetQuantifier(self)




    def setQuantifier(self):

        localctx = SqlBaseParser.SetQuantifierContext(self, self._ctx, self.state)
        self.enterRule(localctx, 40, self.RULE_setQuantifier)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 776
            _la = self._input.LA(1)
            if not(_la==SqlBaseParser.ALL or _la==SqlBaseParser.DISTINCT):
                self._errHandler.recoverInline(self)
            else:
                self._errHandler.reportMatch(self)
                self.consume()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class SelectItemContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.SelectItemContext, self).__init__(parent, invokingState)
            self.parser = parser


        def getRuleIndex(self):
            return SqlBaseParser.RULE_selectItem

     
        def copyFrom(self, ctx):
            super(SqlBaseParser.SelectItemContext, self).copyFrom(ctx)



    class SelectAllContext(SelectItemContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.SelectItemContext)
            super(SqlBaseParser.SelectAllContext, self).__init__(parser)
            self.copyFrom(ctx)

        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)

        def ASTERISK(self):
            return self.getToken(SqlBaseParser.ASTERISK, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterSelectAll"):
                listener.enterSelectAll(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitSelectAll"):
                listener.exitSelectAll(self)


    class SelectSingleContext(SelectItemContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.SelectItemContext)
            super(SqlBaseParser.SelectSingleContext, self).__init__(parser)
            self.copyFrom(ctx)

        def expression(self):
            return self.getTypedRuleContext(SqlBaseParser.ExpressionContext,0)

        def identifier(self):
            return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,0)

        def AS(self):
            return self.getToken(SqlBaseParser.AS, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterSelectSingle"):
                listener.enterSelectSingle(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitSelectSingle"):
                listener.exitSelectSingle(self)



    def selectItem(self):

        localctx = SqlBaseParser.SelectItemContext(self, self._ctx, self.state)
        self.enterRule(localctx, 42, self.RULE_selectItem)
        self._la = 0 # Token type
        try:
            self.state = 790
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,96,self._ctx)
            if la_ == 1:
                localctx = SqlBaseParser.SelectSingleContext(self, localctx)
                self.enterOuterAlt(localctx, 1)
                self.state = 778
                self.expression()
                self.state = 783
                self._errHandler.sync(self)
                la_ = self._interp.adaptivePredict(self._input,95,self._ctx)
                if la_ == 1:
                    self.state = 780
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)
                    if _la==SqlBaseParser.AS:
                        self.state = 779
                        self.match(SqlBaseParser.AS)


                    self.state = 782
                    self.identifier()


                pass

            elif la_ == 2:
                localctx = SqlBaseParser.SelectAllContext(self, localctx)
                self.enterOuterAlt(localctx, 2)
                self.state = 785
                self.qualifiedName()
                self.state = 786
                self.match(SqlBaseParser.T__0)
                self.state = 787
                self.match(SqlBaseParser.ASTERISK)
                pass

            elif la_ == 3:
                localctx = SqlBaseParser.SelectAllContext(self, localctx)
                self.enterOuterAlt(localctx, 3)
                self.state = 789
                self.match(SqlBaseParser.ASTERISK)
                pass


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class RelationContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.RelationContext, self).__init__(parent, invokingState)
            self.parser = parser


        def getRuleIndex(self):
            return SqlBaseParser.RULE_relation

     
        def copyFrom(self, ctx):
            super(SqlBaseParser.RelationContext, self).copyFrom(ctx)


    class RelationDefaultContext(RelationContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.RelationContext)
            super(SqlBaseParser.RelationDefaultContext, self).__init__(parser)
            self.copyFrom(ctx)

        def sampledRelation(self):
            return self.getTypedRuleContext(SqlBaseParser.SampledRelationContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterRelationDefault"):
                listener.enterRelationDefault(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitRelationDefault"):
                listener.exitRelationDefault(self)


    class JoinRelationContext(RelationContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.RelationContext)
            super(SqlBaseParser.JoinRelationContext, self).__init__(parser)
            self.left = None # RelationContext
            self.right = None # SampledRelationContext
            self.rightRelation = None # RelationContext
            self.copyFrom(ctx)

        def relation(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.RelationContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.RelationContext,i)

        def CROSS(self):
            return self.getToken(SqlBaseParser.CROSS, 0)
        def JOIN(self):
            return self.getToken(SqlBaseParser.JOIN, 0)
        def joinType(self):
            return self.getTypedRuleContext(SqlBaseParser.JoinTypeContext,0)

        def joinCriteria(self):
            return self.getTypedRuleContext(SqlBaseParser.JoinCriteriaContext,0)

        def NATURAL(self):
            return self.getToken(SqlBaseParser.NATURAL, 0)
        def sampledRelation(self):
            return self.getTypedRuleContext(SqlBaseParser.SampledRelationContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterJoinRelation"):
                listener.enterJoinRelation(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitJoinRelation"):
                listener.exitJoinRelation(self)



    def relation(self, _p=0):
        _parentctx = self._ctx
        _parentState = self.state
        localctx = SqlBaseParser.RelationContext(self, self._ctx, _parentState)
        _prevctx = localctx
        _startState = 44
        self.enterRecursionRule(localctx, 44, self.RULE_relation, _p)
        try:
            self.enterOuterAlt(localctx, 1)
            localctx = SqlBaseParser.RelationDefaultContext(self, localctx)
            self._ctx = localctx
            _prevctx = localctx

            self.state = 793
            self.sampledRelation()
            self._ctx.stop = self._input.LT(-1)
            self.state = 813
            self._errHandler.sync(self)
            _alt = self._interp.adaptivePredict(self._input,98,self._ctx)
            while _alt!=2 and _alt!=ATN.INVALID_ALT_NUMBER:
                if _alt==1:
                    if self._parseListeners is not None:
                        self.triggerExitRuleEvent()
                    _prevctx = localctx
                    localctx = SqlBaseParser.JoinRelationContext(self, SqlBaseParser.RelationContext(self, _parentctx, _parentState))
                    localctx.left = _prevctx
                    self.pushNewRecursionContext(localctx, _startState, self.RULE_relation)
                    self.state = 795
                    if not self.precpred(self._ctx, 2):
                        from antlr4.error.Errors import FailedPredicateException
                        raise FailedPredicateException(self, "self.precpred(self._ctx, 2)")
                    self.state = 809
                    self._errHandler.sync(self)
                    token = self._input.LA(1)
                    if token in [SqlBaseParser.CROSS]:
                        self.state = 796
                        self.match(SqlBaseParser.CROSS)
                        self.state = 797
                        self.match(SqlBaseParser.JOIN)
                        self.state = 798
                        localctx.right = self.sampledRelation()
                        pass
                    elif token in [SqlBaseParser.FULL, SqlBaseParser.INNER, SqlBaseParser.JOIN, SqlBaseParser.LEFT, SqlBaseParser.RIGHT]:
                        self.state = 799
                        self.joinType()
                        self.state = 800
                        self.match(SqlBaseParser.JOIN)
                        self.state = 801
                        localctx.rightRelation = self.relation(0)
                        self.state = 802
                        self.joinCriteria()
                        pass
                    elif token in [SqlBaseParser.NATURAL]:
                        self.state = 804
                        self.match(SqlBaseParser.NATURAL)
                        self.state = 805
                        self.joinType()
                        self.state = 806
                        self.match(SqlBaseParser.JOIN)
                        self.state = 807
                        localctx.right = self.sampledRelation()
                        pass
                    else:
                        raise NoViableAltException(self)
             
                self.state = 815
                self._errHandler.sync(self)
                _alt = self._interp.adaptivePredict(self._input,98,self._ctx)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.unrollRecursionContexts(_parentctx)
        return localctx

    class JoinTypeContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.JoinTypeContext, self).__init__(parent, invokingState)
            self.parser = parser

        def INNER(self):
            return self.getToken(SqlBaseParser.INNER, 0)

        def LEFT(self):
            return self.getToken(SqlBaseParser.LEFT, 0)

        def OUTER(self):
            return self.getToken(SqlBaseParser.OUTER, 0)

        def RIGHT(self):
            return self.getToken(SqlBaseParser.RIGHT, 0)

        def FULL(self):
            return self.getToken(SqlBaseParser.FULL, 0)

        def getRuleIndex(self):
            return SqlBaseParser.RULE_joinType

        def enterRule(self, listener):
            if hasattr(listener, "enterJoinType"):
                listener.enterJoinType(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitJoinType"):
                listener.exitJoinType(self)




    def joinType(self):

        localctx = SqlBaseParser.JoinTypeContext(self, self._ctx, self.state)
        self.enterRule(localctx, 46, self.RULE_joinType)
        self._la = 0 # Token type
        try:
            self.state = 831
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [SqlBaseParser.INNER, SqlBaseParser.JOIN]:
                self.enterOuterAlt(localctx, 1)
                self.state = 817
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.INNER:
                    self.state = 816
                    self.match(SqlBaseParser.INNER)


                pass
            elif token in [SqlBaseParser.LEFT]:
                self.enterOuterAlt(localctx, 2)
                self.state = 819
                self.match(SqlBaseParser.LEFT)
                self.state = 821
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.OUTER:
                    self.state = 820
                    self.match(SqlBaseParser.OUTER)


                pass
            elif token in [SqlBaseParser.RIGHT]:
                self.enterOuterAlt(localctx, 3)
                self.state = 823
                self.match(SqlBaseParser.RIGHT)
                self.state = 825
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.OUTER:
                    self.state = 824
                    self.match(SqlBaseParser.OUTER)


                pass
            elif token in [SqlBaseParser.FULL]:
                self.enterOuterAlt(localctx, 4)
                self.state = 827
                self.match(SqlBaseParser.FULL)
                self.state = 829
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.OUTER:
                    self.state = 828
                    self.match(SqlBaseParser.OUTER)


                pass
            else:
                raise NoViableAltException(self)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class JoinCriteriaContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.JoinCriteriaContext, self).__init__(parent, invokingState)
            self.parser = parser

        def ON(self):
            return self.getToken(SqlBaseParser.ON, 0)

        def booleanExpression(self):
            return self.getTypedRuleContext(SqlBaseParser.BooleanExpressionContext,0)


        def USING(self):
            return self.getToken(SqlBaseParser.USING, 0)

        def identifier(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.IdentifierContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,i)


        def getRuleIndex(self):
            return SqlBaseParser.RULE_joinCriteria

        def enterRule(self, listener):
            if hasattr(listener, "enterJoinCriteria"):
                listener.enterJoinCriteria(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitJoinCriteria"):
                listener.exitJoinCriteria(self)




    def joinCriteria(self):

        localctx = SqlBaseParser.JoinCriteriaContext(self, self._ctx, self.state)
        self.enterRule(localctx, 48, self.RULE_joinCriteria)
        self._la = 0 # Token type
        try:
            self.state = 847
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [SqlBaseParser.ON]:
                self.enterOuterAlt(localctx, 1)
                self.state = 833
                self.match(SqlBaseParser.ON)
                self.state = 834
                self.booleanExpression(0)
                pass
            elif token in [SqlBaseParser.USING]:
                self.enterOuterAlt(localctx, 2)
                self.state = 835
                self.match(SqlBaseParser.USING)
                self.state = 836
                self.match(SqlBaseParser.T__1)
                self.state = 837
                self.identifier()
                self.state = 842
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                while _la==SqlBaseParser.T__3:
                    self.state = 838
                    self.match(SqlBaseParser.T__3)
                    self.state = 839
                    self.identifier()
                    self.state = 844
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)

                self.state = 845
                self.match(SqlBaseParser.T__2)
                pass
            else:
                raise NoViableAltException(self)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class SampledRelationContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.SampledRelationContext, self).__init__(parent, invokingState)
            self.parser = parser
            self.percentage = None # ExpressionContext

        def aliasedRelation(self):
            return self.getTypedRuleContext(SqlBaseParser.AliasedRelationContext,0)


        def TABLESAMPLE(self):
            return self.getToken(SqlBaseParser.TABLESAMPLE, 0)

        def sampleType(self):
            return self.getTypedRuleContext(SqlBaseParser.SampleTypeContext,0)


        def expression(self):
            return self.getTypedRuleContext(SqlBaseParser.ExpressionContext,0)


        def getRuleIndex(self):
            return SqlBaseParser.RULE_sampledRelation

        def enterRule(self, listener):
            if hasattr(listener, "enterSampledRelation"):
                listener.enterSampledRelation(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitSampledRelation"):
                listener.exitSampledRelation(self)




    def sampledRelation(self):

        localctx = SqlBaseParser.SampledRelationContext(self, self._ctx, self.state)
        self.enterRule(localctx, 50, self.RULE_sampledRelation)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 849
            self.aliasedRelation()
            self.state = 856
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,106,self._ctx)
            if la_ == 1:
                self.state = 850
                self.match(SqlBaseParser.TABLESAMPLE)
                self.state = 851
                self.sampleType()
                self.state = 852
                self.match(SqlBaseParser.T__1)
                self.state = 853
                localctx.percentage = self.expression()
                self.state = 854
                self.match(SqlBaseParser.T__2)


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class SampleTypeContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.SampleTypeContext, self).__init__(parent, invokingState)
            self.parser = parser

        def BERNOULLI(self):
            return self.getToken(SqlBaseParser.BERNOULLI, 0)

        def SYSTEM(self):
            return self.getToken(SqlBaseParser.SYSTEM, 0)

        def getRuleIndex(self):
            return SqlBaseParser.RULE_sampleType

        def enterRule(self, listener):
            if hasattr(listener, "enterSampleType"):
                listener.enterSampleType(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitSampleType"):
                listener.exitSampleType(self)




    def sampleType(self):

        localctx = SqlBaseParser.SampleTypeContext(self, self._ctx, self.state)
        self.enterRule(localctx, 52, self.RULE_sampleType)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 858
            _la = self._input.LA(1)
            if not(_la==SqlBaseParser.BERNOULLI or _la==SqlBaseParser.SYSTEM):
                self._errHandler.recoverInline(self)
            else:
                self._errHandler.reportMatch(self)
                self.consume()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class AliasedRelationContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.AliasedRelationContext, self).__init__(parent, invokingState)
            self.parser = parser

        def relationPrimary(self):
            return self.getTypedRuleContext(SqlBaseParser.RelationPrimaryContext,0)


        def identifier(self):
            return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,0)


        def AS(self):
            return self.getToken(SqlBaseParser.AS, 0)

        def columnAliases(self):
            return self.getTypedRuleContext(SqlBaseParser.ColumnAliasesContext,0)


        def getRuleIndex(self):
            return SqlBaseParser.RULE_aliasedRelation

        def enterRule(self, listener):
            if hasattr(listener, "enterAliasedRelation"):
                listener.enterAliasedRelation(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitAliasedRelation"):
                listener.exitAliasedRelation(self)




    def aliasedRelation(self):

        localctx = SqlBaseParser.AliasedRelationContext(self, self._ctx, self.state)
        self.enterRule(localctx, 54, self.RULE_aliasedRelation)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 860
            self.relationPrimary()
            self.state = 868
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,109,self._ctx)
            if la_ == 1:
                self.state = 862
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.AS:
                    self.state = 861
                    self.match(SqlBaseParser.AS)


                self.state = 864
                self.identifier()
                self.state = 866
                self._errHandler.sync(self)
                la_ = self._interp.adaptivePredict(self._input,108,self._ctx)
                if la_ == 1:
                    self.state = 865
                    self.columnAliases()




        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class ColumnAliasesContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.ColumnAliasesContext, self).__init__(parent, invokingState)
            self.parser = parser

        def identifier(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.IdentifierContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,i)


        def getRuleIndex(self):
            return SqlBaseParser.RULE_columnAliases

        def enterRule(self, listener):
            if hasattr(listener, "enterColumnAliases"):
                listener.enterColumnAliases(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitColumnAliases"):
                listener.exitColumnAliases(self)




    def columnAliases(self):

        localctx = SqlBaseParser.ColumnAliasesContext(self, self._ctx, self.state)
        self.enterRule(localctx, 56, self.RULE_columnAliases)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 870
            self.match(SqlBaseParser.T__1)
            self.state = 871
            self.identifier()
            self.state = 876
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            while _la==SqlBaseParser.T__3:
                self.state = 872
                self.match(SqlBaseParser.T__3)
                self.state = 873
                self.identifier()
                self.state = 878
                self._errHandler.sync(self)
                _la = self._input.LA(1)

            self.state = 879
            self.match(SqlBaseParser.T__2)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class RelationPrimaryContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.RelationPrimaryContext, self).__init__(parent, invokingState)
            self.parser = parser


        def getRuleIndex(self):
            return SqlBaseParser.RULE_relationPrimary

     
        def copyFrom(self, ctx):
            super(SqlBaseParser.RelationPrimaryContext, self).copyFrom(ctx)



    class SubqueryRelationContext(RelationPrimaryContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.RelationPrimaryContext)
            super(SqlBaseParser.SubqueryRelationContext, self).__init__(parser)
            self.copyFrom(ctx)

        def query(self):
            return self.getTypedRuleContext(SqlBaseParser.QueryContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterSubqueryRelation"):
                listener.enterSubqueryRelation(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitSubqueryRelation"):
                listener.exitSubqueryRelation(self)


    class ParenthesizedRelationContext(RelationPrimaryContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.RelationPrimaryContext)
            super(SqlBaseParser.ParenthesizedRelationContext, self).__init__(parser)
            self.copyFrom(ctx)

        def relation(self):
            return self.getTypedRuleContext(SqlBaseParser.RelationContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterParenthesizedRelation"):
                listener.enterParenthesizedRelation(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitParenthesizedRelation"):
                listener.exitParenthesizedRelation(self)


    class UnnestContext(RelationPrimaryContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.RelationPrimaryContext)
            super(SqlBaseParser.UnnestContext, self).__init__(parser)
            self.copyFrom(ctx)

        def UNNEST(self):
            return self.getToken(SqlBaseParser.UNNEST, 0)
        def expression(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.ExpressionContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.ExpressionContext,i)

        def WITH(self):
            return self.getToken(SqlBaseParser.WITH, 0)
        def ORDINALITY(self):
            return self.getToken(SqlBaseParser.ORDINALITY, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterUnnest"):
                listener.enterUnnest(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitUnnest"):
                listener.exitUnnest(self)


    class LateralContext(RelationPrimaryContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.RelationPrimaryContext)
            super(SqlBaseParser.LateralContext, self).__init__(parser)
            self.copyFrom(ctx)

        def LATERAL(self):
            return self.getToken(SqlBaseParser.LATERAL, 0)
        def query(self):
            return self.getTypedRuleContext(SqlBaseParser.QueryContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterLateral"):
                listener.enterLateral(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitLateral"):
                listener.exitLateral(self)


    class TableNameContext(RelationPrimaryContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.RelationPrimaryContext)
            super(SqlBaseParser.TableNameContext, self).__init__(parser)
            self.copyFrom(ctx)

        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterTableName"):
                listener.enterTableName(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitTableName"):
                listener.exitTableName(self)



    def relationPrimary(self):

        localctx = SqlBaseParser.RelationPrimaryContext(self, self._ctx, self.state)
        self.enterRule(localctx, 58, self.RULE_relationPrimary)
        self._la = 0 # Token type
        try:
            self.state = 910
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,113,self._ctx)
            if la_ == 1:
                localctx = SqlBaseParser.TableNameContext(self, localctx)
                self.enterOuterAlt(localctx, 1)
                self.state = 881
                self.qualifiedName()
                pass

            elif la_ == 2:
                localctx = SqlBaseParser.SubqueryRelationContext(self, localctx)
                self.enterOuterAlt(localctx, 2)
                self.state = 882
                self.match(SqlBaseParser.T__1)
                self.state = 883
                self.query()
                self.state = 884
                self.match(SqlBaseParser.T__2)
                pass

            elif la_ == 3:
                localctx = SqlBaseParser.UnnestContext(self, localctx)
                self.enterOuterAlt(localctx, 3)
                self.state = 886
                self.match(SqlBaseParser.UNNEST)
                self.state = 887
                self.match(SqlBaseParser.T__1)
                self.state = 888
                self.expression()
                self.state = 893
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                while _la==SqlBaseParser.T__3:
                    self.state = 889
                    self.match(SqlBaseParser.T__3)
                    self.state = 890
                    self.expression()
                    self.state = 895
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)

                self.state = 896
                self.match(SqlBaseParser.T__2)
                self.state = 899
                self._errHandler.sync(self)
                la_ = self._interp.adaptivePredict(self._input,112,self._ctx)
                if la_ == 1:
                    self.state = 897
                    self.match(SqlBaseParser.WITH)
                    self.state = 898
                    self.match(SqlBaseParser.ORDINALITY)


                pass

            elif la_ == 4:
                localctx = SqlBaseParser.LateralContext(self, localctx)
                self.enterOuterAlt(localctx, 4)
                self.state = 901
                self.match(SqlBaseParser.LATERAL)
                self.state = 902
                self.match(SqlBaseParser.T__1)
                self.state = 903
                self.query()
                self.state = 904
                self.match(SqlBaseParser.T__2)
                pass

            elif la_ == 5:
                localctx = SqlBaseParser.ParenthesizedRelationContext(self, localctx)
                self.enterOuterAlt(localctx, 5)
                self.state = 906
                self.match(SqlBaseParser.T__1)
                self.state = 907
                self.relation(0)
                self.state = 908
                self.match(SqlBaseParser.T__2)
                pass


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class ExpressionContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.ExpressionContext, self).__init__(parent, invokingState)
            self.parser = parser

        def booleanExpression(self):
            return self.getTypedRuleContext(SqlBaseParser.BooleanExpressionContext,0)


        def getRuleIndex(self):
            return SqlBaseParser.RULE_expression

        def enterRule(self, listener):
            if hasattr(listener, "enterExpression"):
                listener.enterExpression(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitExpression"):
                listener.exitExpression(self)




    def expression(self):

        localctx = SqlBaseParser.ExpressionContext(self, self._ctx, self.state)
        self.enterRule(localctx, 60, self.RULE_expression)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 912
            self.booleanExpression(0)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class BooleanExpressionContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.BooleanExpressionContext, self).__init__(parent, invokingState)
            self.parser = parser


        def getRuleIndex(self):
            return SqlBaseParser.RULE_booleanExpression

     
        def copyFrom(self, ctx):
            super(SqlBaseParser.BooleanExpressionContext, self).copyFrom(ctx)


    class LogicalNotContext(BooleanExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.BooleanExpressionContext)
            super(SqlBaseParser.LogicalNotContext, self).__init__(parser)
            self.copyFrom(ctx)

        def NOT(self):
            return self.getToken(SqlBaseParser.NOT, 0)
        def booleanExpression(self):
            return self.getTypedRuleContext(SqlBaseParser.BooleanExpressionContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterLogicalNot"):
                listener.enterLogicalNot(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitLogicalNot"):
                listener.exitLogicalNot(self)


    class BooleanDefaultContext(BooleanExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.BooleanExpressionContext)
            super(SqlBaseParser.BooleanDefaultContext, self).__init__(parser)
            self.copyFrom(ctx)

        def predicated(self):
            return self.getTypedRuleContext(SqlBaseParser.PredicatedContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterBooleanDefault"):
                listener.enterBooleanDefault(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitBooleanDefault"):
                listener.exitBooleanDefault(self)


    class LogicalBinaryContext(BooleanExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.BooleanExpressionContext)
            super(SqlBaseParser.LogicalBinaryContext, self).__init__(parser)
            self.left = None # BooleanExpressionContext
            self.operator = None # Token
            self.right = None # BooleanExpressionContext
            self.copyFrom(ctx)

        def booleanExpression(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.BooleanExpressionContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.BooleanExpressionContext,i)

        def AND(self):
            return self.getToken(SqlBaseParser.AND, 0)
        def OR(self):
            return self.getToken(SqlBaseParser.OR, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterLogicalBinary"):
                listener.enterLogicalBinary(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitLogicalBinary"):
                listener.exitLogicalBinary(self)



    def booleanExpression(self, _p=0):
        _parentctx = self._ctx
        _parentState = self.state
        localctx = SqlBaseParser.BooleanExpressionContext(self, self._ctx, _parentState)
        _prevctx = localctx
        _startState = 62
        self.enterRecursionRule(localctx, 62, self.RULE_booleanExpression, _p)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 918
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [SqlBaseParser.T__1, SqlBaseParser.T__4, SqlBaseParser.ADD, SqlBaseParser.ALL, SqlBaseParser.ANALYZE, SqlBaseParser.ANY, SqlBaseParser.ARRAY, SqlBaseParser.ASC, SqlBaseParser.AT, SqlBaseParser.BERNOULLI, SqlBaseParser.CALL, SqlBaseParser.CASCADE, SqlBaseParser.CASE, SqlBaseParser.CAST, SqlBaseParser.CATALOGS, SqlBaseParser.COALESCE, SqlBaseParser.COLUMN, SqlBaseParser.COLUMNS, SqlBaseParser.COMMENT, SqlBaseParser.COMMIT, SqlBaseParser.COMMITTED, SqlBaseParser.CURRENT, SqlBaseParser.CURRENT_DATE, SqlBaseParser.CURRENT_TIME, SqlBaseParser.CURRENT_TIMESTAMP, SqlBaseParser.CURRENT_USER, SqlBaseParser.DATA, SqlBaseParser.DATE, SqlBaseParser.DAY, SqlBaseParser.DESC, SqlBaseParser.DISTRIBUTED, SqlBaseParser.EXCLUDING, SqlBaseParser.EXISTS, SqlBaseParser.EXPLAIN, SqlBaseParser.EXTRACT, SqlBaseParser.FALSE, SqlBaseParser.FILTER, SqlBaseParser.FIRST, SqlBaseParser.FOLLOWING, SqlBaseParser.FORMAT, SqlBaseParser.FUNCTIONS, SqlBaseParser.GRANT, SqlBaseParser.GRANTS, SqlBaseParser.GRAPHVIZ, SqlBaseParser.GROUPING, SqlBaseParser.HOUR, SqlBaseParser.IF, SqlBaseParser.INCLUDING, SqlBaseParser.INPUT, SqlBaseParser.INTEGER, SqlBaseParser.INTERVAL, SqlBaseParser.ISOLATION, SqlBaseParser.LAST, SqlBaseParser.LATERAL, SqlBaseParser.LEVEL, SqlBaseParser.LIMIT, SqlBaseParser.LOCALTIME, SqlBaseParser.LOCALTIMESTAMP, SqlBaseParser.LOGICAL, SqlBaseParser.MAP, SqlBaseParser.MINUTE, SqlBaseParser.MONTH, SqlBaseParser.NFC, SqlBaseParser.NFD, SqlBaseParser.NFKC, SqlBaseParser.NFKD, SqlBaseParser.NO, SqlBaseParser.NORMALIZE, SqlBaseParser.NULL, SqlBaseParser.NULLIF, SqlBaseParser.NULLS, SqlBaseParser.ONLY, SqlBaseParser.OPTION, SqlBaseParser.ORDINALITY, SqlBaseParser.OUTPUT, SqlBaseParser.OVER, SqlBaseParser.PARTITION, SqlBaseParser.PARTITIONS, SqlBaseParser.POSITION, SqlBaseParser.PRECEDING, SqlBaseParser.PRIVILEGES, SqlBaseParser.PROPERTIES, SqlBaseParser.PUBLIC, SqlBaseParser.RANGE, SqlBaseParser.READ, SqlBaseParser.RENAME, SqlBaseParser.REPEATABLE, SqlBaseParser.REPLACE, SqlBaseParser.RESET, SqlBaseParser.RESTRICT, SqlBaseParser.REVOKE, SqlBaseParser.ROLLBACK, SqlBaseParser.ROW, SqlBaseParser.ROWS, SqlBaseParser.SCHEMA, SqlBaseParser.SCHEMAS, SqlBaseParser.SECOND, SqlBaseParser.SERIALIZABLE, SqlBaseParser.SESSION, SqlBaseParser.SET, SqlBaseParser.SETS, SqlBaseParser.SHOW, SqlBaseParser.SMALLINT, SqlBaseParser.SOME, SqlBaseParser.START, SqlBaseParser.STATS, SqlBaseParser.SUBSTRING, SqlBaseParser.SYSTEM, SqlBaseParser.TABLES, SqlBaseParser.TABLESAMPLE, SqlBaseParser.TEXT, SqlBaseParser.TIME, SqlBaseParser.TIMESTAMP, SqlBaseParser.TINYINT, SqlBaseParser.TO, SqlBaseParser.TRANSACTION, SqlBaseParser.TRUE, SqlBaseParser.TRY_CAST, SqlBaseParser.TYPE, SqlBaseParser.UNBOUNDED, SqlBaseParser.UNCOMMITTED, SqlBaseParser.USE, SqlBaseParser.VALIDATE, SqlBaseParser.VERBOSE, SqlBaseParser.VIEW, SqlBaseParser.WORK, SqlBaseParser.WRITE, SqlBaseParser.YEAR, SqlBaseParser.ZONE, SqlBaseParser.PLUS, SqlBaseParser.MINUS, SqlBaseParser.STRING, SqlBaseParser.UNICODE_STRING, SqlBaseParser.BINARY_LITERAL, SqlBaseParser.INTEGER_VALUE, SqlBaseParser.DECIMAL_VALUE, SqlBaseParser.DOUBLE_VALUE, SqlBaseParser.IDENTIFIER, SqlBaseParser.DIGIT_IDENTIFIER, SqlBaseParser.QUOTED_IDENTIFIER, SqlBaseParser.BACKQUOTED_IDENTIFIER, SqlBaseParser.DOUBLE_PRECISION]:
                localctx = SqlBaseParser.BooleanDefaultContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx

                self.state = 915
                self.predicated()
                pass
            elif token in [SqlBaseParser.NOT]:
                localctx = SqlBaseParser.LogicalNotContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 916
                self.match(SqlBaseParser.NOT)
                self.state = 917
                self.booleanExpression(3)
                pass
            else:
                raise NoViableAltException(self)

            self._ctx.stop = self._input.LT(-1)
            self.state = 928
            self._errHandler.sync(self)
            _alt = self._interp.adaptivePredict(self._input,116,self._ctx)
            while _alt!=2 and _alt!=ATN.INVALID_ALT_NUMBER:
                if _alt==1:
                    if self._parseListeners is not None:
                        self.triggerExitRuleEvent()
                    _prevctx = localctx
                    self.state = 926
                    self._errHandler.sync(self)
                    la_ = self._interp.adaptivePredict(self._input,115,self._ctx)
                    if la_ == 1:
                        localctx = SqlBaseParser.LogicalBinaryContext(self, SqlBaseParser.BooleanExpressionContext(self, _parentctx, _parentState))
                        localctx.left = _prevctx
                        self.pushNewRecursionContext(localctx, _startState, self.RULE_booleanExpression)
                        self.state = 920
                        if not self.precpred(self._ctx, 2):
                            from antlr4.error.Errors import FailedPredicateException
                            raise FailedPredicateException(self, "self.precpred(self._ctx, 2)")
                        self.state = 921
                        localctx.operator = self.match(SqlBaseParser.AND)
                        self.state = 922
                        localctx.right = self.booleanExpression(3)
                        pass

                    elif la_ == 2:
                        localctx = SqlBaseParser.LogicalBinaryContext(self, SqlBaseParser.BooleanExpressionContext(self, _parentctx, _parentState))
                        localctx.left = _prevctx
                        self.pushNewRecursionContext(localctx, _startState, self.RULE_booleanExpression)
                        self.state = 923
                        if not self.precpred(self._ctx, 1):
                            from antlr4.error.Errors import FailedPredicateException
                            raise FailedPredicateException(self, "self.precpred(self._ctx, 1)")
                        self.state = 924
                        localctx.operator = self.match(SqlBaseParser.OR)
                        self.state = 925
                        localctx.right = self.booleanExpression(2)
                        pass

             
                self.state = 930
                self._errHandler.sync(self)
                _alt = self._interp.adaptivePredict(self._input,116,self._ctx)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.unrollRecursionContexts(_parentctx)
        return localctx

    class PredicatedContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.PredicatedContext, self).__init__(parent, invokingState)
            self.parser = parser
            self._valueExpression = None # ValueExpressionContext

        def valueExpression(self):
            return self.getTypedRuleContext(SqlBaseParser.ValueExpressionContext,0)


        def predicate(self):
            return self.getTypedRuleContext(SqlBaseParser.PredicateContext,0)


        def getRuleIndex(self):
            return SqlBaseParser.RULE_predicated

        def enterRule(self, listener):
            if hasattr(listener, "enterPredicated"):
                listener.enterPredicated(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitPredicated"):
                listener.exitPredicated(self)




    def predicated(self):

        localctx = SqlBaseParser.PredicatedContext(self, self._ctx, self.state)
        self.enterRule(localctx, 64, self.RULE_predicated)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 931
            localctx._valueExpression = self.valueExpression(0)
            self.state = 933
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,117,self._ctx)
            if la_ == 1:
                self.state = 932
                self.predicate(localctx._valueExpression)


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class PredicateContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1, value=None):
            super(SqlBaseParser.PredicateContext, self).__init__(parent, invokingState)
            self.parser = parser
            self.value = None
            self.value = value


        def getRuleIndex(self):
            return SqlBaseParser.RULE_predicate

     
        def copyFrom(self, ctx):
            super(SqlBaseParser.PredicateContext, self).copyFrom(ctx)
            self.value = ctx.value



    class ComparisonContext(PredicateContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PredicateContext)
            super(SqlBaseParser.ComparisonContext, self).__init__(parser)
            self.right = None # ValueExpressionContext
            self.copyFrom(ctx)

        def comparisonOperator(self):
            return self.getTypedRuleContext(SqlBaseParser.ComparisonOperatorContext,0)

        def valueExpression(self):
            return self.getTypedRuleContext(SqlBaseParser.ValueExpressionContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterComparison"):
                listener.enterComparison(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitComparison"):
                listener.exitComparison(self)


    class LikeContext(PredicateContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PredicateContext)
            super(SqlBaseParser.LikeContext, self).__init__(parser)
            self.pattern = None # ValueExpressionContext
            self.escape = None # ValueExpressionContext
            self.copyFrom(ctx)

        def LIKE(self):
            return self.getToken(SqlBaseParser.LIKE, 0)
        def valueExpression(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.ValueExpressionContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.ValueExpressionContext,i)

        def NOT(self):
            return self.getToken(SqlBaseParser.NOT, 0)
        def ESCAPE(self):
            return self.getToken(SqlBaseParser.ESCAPE, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterLike"):
                listener.enterLike(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitLike"):
                listener.exitLike(self)


    class InSubqueryContext(PredicateContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PredicateContext)
            super(SqlBaseParser.InSubqueryContext, self).__init__(parser)
            self.copyFrom(ctx)

        def IN(self):
            return self.getToken(SqlBaseParser.IN, 0)
        def query(self):
            return self.getTypedRuleContext(SqlBaseParser.QueryContext,0)

        def NOT(self):
            return self.getToken(SqlBaseParser.NOT, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterInSubquery"):
                listener.enterInSubquery(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitInSubquery"):
                listener.exitInSubquery(self)


    class DistinctFromContext(PredicateContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PredicateContext)
            super(SqlBaseParser.DistinctFromContext, self).__init__(parser)
            self.right = None # ValueExpressionContext
            self.copyFrom(ctx)

        def IS(self):
            return self.getToken(SqlBaseParser.IS, 0)
        def DISTINCT(self):
            return self.getToken(SqlBaseParser.DISTINCT, 0)
        def FROM(self):
            return self.getToken(SqlBaseParser.FROM, 0)
        def valueExpression(self):
            return self.getTypedRuleContext(SqlBaseParser.ValueExpressionContext,0)

        def NOT(self):
            return self.getToken(SqlBaseParser.NOT, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterDistinctFrom"):
                listener.enterDistinctFrom(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitDistinctFrom"):
                listener.exitDistinctFrom(self)


    class InListContext(PredicateContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PredicateContext)
            super(SqlBaseParser.InListContext, self).__init__(parser)
            self.copyFrom(ctx)

        def IN(self):
            return self.getToken(SqlBaseParser.IN, 0)
        def expression(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.ExpressionContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.ExpressionContext,i)

        def NOT(self):
            return self.getToken(SqlBaseParser.NOT, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterInList"):
                listener.enterInList(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitInList"):
                listener.exitInList(self)


    class NullPredicateContext(PredicateContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PredicateContext)
            super(SqlBaseParser.NullPredicateContext, self).__init__(parser)
            self.copyFrom(ctx)

        def IS(self):
            return self.getToken(SqlBaseParser.IS, 0)
        def NULL(self):
            return self.getToken(SqlBaseParser.NULL, 0)
        def NOT(self):
            return self.getToken(SqlBaseParser.NOT, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterNullPredicate"):
                listener.enterNullPredicate(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitNullPredicate"):
                listener.exitNullPredicate(self)


    class BetweenContext(PredicateContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PredicateContext)
            super(SqlBaseParser.BetweenContext, self).__init__(parser)
            self.lower = None # ValueExpressionContext
            self.upper = None # ValueExpressionContext
            self.copyFrom(ctx)

        def BETWEEN(self):
            return self.getToken(SqlBaseParser.BETWEEN, 0)
        def AND(self):
            return self.getToken(SqlBaseParser.AND, 0)
        def valueExpression(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.ValueExpressionContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.ValueExpressionContext,i)

        def NOT(self):
            return self.getToken(SqlBaseParser.NOT, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterBetween"):
                listener.enterBetween(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitBetween"):
                listener.exitBetween(self)


    class QuantifiedComparisonContext(PredicateContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PredicateContext)
            super(SqlBaseParser.QuantifiedComparisonContext, self).__init__(parser)
            self.copyFrom(ctx)

        def comparisonOperator(self):
            return self.getTypedRuleContext(SqlBaseParser.ComparisonOperatorContext,0)

        def comparisonQuantifier(self):
            return self.getTypedRuleContext(SqlBaseParser.ComparisonQuantifierContext,0)

        def query(self):
            return self.getTypedRuleContext(SqlBaseParser.QueryContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterQuantifiedComparison"):
                listener.enterQuantifiedComparison(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitQuantifiedComparison"):
                listener.exitQuantifiedComparison(self)



    def predicate(self, value):

        localctx = SqlBaseParser.PredicateContext(self, self._ctx, self.state, value)
        self.enterRule(localctx, 66, self.RULE_predicate)
        self._la = 0 # Token type
        try:
            self.state = 996
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,126,self._ctx)
            if la_ == 1:
                localctx = SqlBaseParser.ComparisonContext(self, localctx)
                self.enterOuterAlt(localctx, 1)
                self.state = 935
                self.comparisonOperator()
                self.state = 936
                localctx.right = self.valueExpression(0)
                pass

            elif la_ == 2:
                localctx = SqlBaseParser.QuantifiedComparisonContext(self, localctx)
                self.enterOuterAlt(localctx, 2)
                self.state = 938
                self.comparisonOperator()
                self.state = 939
                self.comparisonQuantifier()
                self.state = 940
                self.match(SqlBaseParser.T__1)
                self.state = 941
                self.query()
                self.state = 942
                self.match(SqlBaseParser.T__2)
                pass

            elif la_ == 3:
                localctx = SqlBaseParser.BetweenContext(self, localctx)
                self.enterOuterAlt(localctx, 3)
                self.state = 945
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.NOT:
                    self.state = 944
                    self.match(SqlBaseParser.NOT)


                self.state = 947
                self.match(SqlBaseParser.BETWEEN)
                self.state = 948
                localctx.lower = self.valueExpression(0)
                self.state = 949
                self.match(SqlBaseParser.AND)
                self.state = 950
                localctx.upper = self.valueExpression(0)
                pass

            elif la_ == 4:
                localctx = SqlBaseParser.InListContext(self, localctx)
                self.enterOuterAlt(localctx, 4)
                self.state = 953
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.NOT:
                    self.state = 952
                    self.match(SqlBaseParser.NOT)


                self.state = 955
                self.match(SqlBaseParser.IN)
                self.state = 956
                self.match(SqlBaseParser.T__1)
                self.state = 957
                self.expression()
                self.state = 962
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                while _la==SqlBaseParser.T__3:
                    self.state = 958
                    self.match(SqlBaseParser.T__3)
                    self.state = 959
                    self.expression()
                    self.state = 964
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)

                self.state = 965
                self.match(SqlBaseParser.T__2)
                pass

            elif la_ == 5:
                localctx = SqlBaseParser.InSubqueryContext(self, localctx)
                self.enterOuterAlt(localctx, 5)
                self.state = 968
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.NOT:
                    self.state = 967
                    self.match(SqlBaseParser.NOT)


                self.state = 970
                self.match(SqlBaseParser.IN)
                self.state = 971
                self.match(SqlBaseParser.T__1)
                self.state = 972
                self.query()
                self.state = 973
                self.match(SqlBaseParser.T__2)
                pass

            elif la_ == 6:
                localctx = SqlBaseParser.LikeContext(self, localctx)
                self.enterOuterAlt(localctx, 6)
                self.state = 976
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.NOT:
                    self.state = 975
                    self.match(SqlBaseParser.NOT)


                self.state = 978
                self.match(SqlBaseParser.LIKE)
                self.state = 979
                localctx.pattern = self.valueExpression(0)
                self.state = 982
                self._errHandler.sync(self)
                la_ = self._interp.adaptivePredict(self._input,123,self._ctx)
                if la_ == 1:
                    self.state = 980
                    self.match(SqlBaseParser.ESCAPE)
                    self.state = 981
                    localctx.escape = self.valueExpression(0)


                pass

            elif la_ == 7:
                localctx = SqlBaseParser.NullPredicateContext(self, localctx)
                self.enterOuterAlt(localctx, 7)
                self.state = 984
                self.match(SqlBaseParser.IS)
                self.state = 986
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.NOT:
                    self.state = 985
                    self.match(SqlBaseParser.NOT)


                self.state = 988
                self.match(SqlBaseParser.NULL)
                pass

            elif la_ == 8:
                localctx = SqlBaseParser.DistinctFromContext(self, localctx)
                self.enterOuterAlt(localctx, 8)
                self.state = 989
                self.match(SqlBaseParser.IS)
                self.state = 991
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.NOT:
                    self.state = 990
                    self.match(SqlBaseParser.NOT)


                self.state = 993
                self.match(SqlBaseParser.DISTINCT)
                self.state = 994
                self.match(SqlBaseParser.FROM)
                self.state = 995
                localctx.right = self.valueExpression(0)
                pass


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class ValueExpressionContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.ValueExpressionContext, self).__init__(parent, invokingState)
            self.parser = parser


        def getRuleIndex(self):
            return SqlBaseParser.RULE_valueExpression

     
        def copyFrom(self, ctx):
            super(SqlBaseParser.ValueExpressionContext, self).copyFrom(ctx)


    class ValueExpressionDefaultContext(ValueExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.ValueExpressionContext)
            super(SqlBaseParser.ValueExpressionDefaultContext, self).__init__(parser)
            self.copyFrom(ctx)

        def primaryExpression(self):
            return self.getTypedRuleContext(SqlBaseParser.PrimaryExpressionContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterValueExpressionDefault"):
                listener.enterValueExpressionDefault(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitValueExpressionDefault"):
                listener.exitValueExpressionDefault(self)


    class ConcatenationContext(ValueExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.ValueExpressionContext)
            super(SqlBaseParser.ConcatenationContext, self).__init__(parser)
            self.left = None # ValueExpressionContext
            self.right = None # ValueExpressionContext
            self.copyFrom(ctx)

        def CONCAT(self):
            return self.getToken(SqlBaseParser.CONCAT, 0)
        def valueExpression(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.ValueExpressionContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.ValueExpressionContext,i)


        def enterRule(self, listener):
            if hasattr(listener, "enterConcatenation"):
                listener.enterConcatenation(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitConcatenation"):
                listener.exitConcatenation(self)


    class ArithmeticBinaryContext(ValueExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.ValueExpressionContext)
            super(SqlBaseParser.ArithmeticBinaryContext, self).__init__(parser)
            self.left = None # ValueExpressionContext
            self.operator = None # Token
            self.right = None # ValueExpressionContext
            self.copyFrom(ctx)

        def valueExpression(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.ValueExpressionContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.ValueExpressionContext,i)

        def ASTERISK(self):
            return self.getToken(SqlBaseParser.ASTERISK, 0)
        def SLASH(self):
            return self.getToken(SqlBaseParser.SLASH, 0)
        def PERCENT(self):
            return self.getToken(SqlBaseParser.PERCENT, 0)
        def PLUS(self):
            return self.getToken(SqlBaseParser.PLUS, 0)
        def MINUS(self):
            return self.getToken(SqlBaseParser.MINUS, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterArithmeticBinary"):
                listener.enterArithmeticBinary(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitArithmeticBinary"):
                listener.exitArithmeticBinary(self)


    class ArithmeticUnaryContext(ValueExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.ValueExpressionContext)
            super(SqlBaseParser.ArithmeticUnaryContext, self).__init__(parser)
            self.operator = None # Token
            self.copyFrom(ctx)

        def valueExpression(self):
            return self.getTypedRuleContext(SqlBaseParser.ValueExpressionContext,0)

        def MINUS(self):
            return self.getToken(SqlBaseParser.MINUS, 0)
        def PLUS(self):
            return self.getToken(SqlBaseParser.PLUS, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterArithmeticUnary"):
                listener.enterArithmeticUnary(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitArithmeticUnary"):
                listener.exitArithmeticUnary(self)


    class AtTimeZoneContext(ValueExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.ValueExpressionContext)
            super(SqlBaseParser.AtTimeZoneContext, self).__init__(parser)
            self.copyFrom(ctx)

        def valueExpression(self):
            return self.getTypedRuleContext(SqlBaseParser.ValueExpressionContext,0)

        def AT(self):
            return self.getToken(SqlBaseParser.AT, 0)
        def timeZoneSpecifier(self):
            return self.getTypedRuleContext(SqlBaseParser.TimeZoneSpecifierContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterAtTimeZone"):
                listener.enterAtTimeZone(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitAtTimeZone"):
                listener.exitAtTimeZone(self)



    def valueExpression(self, _p=0):
        _parentctx = self._ctx
        _parentState = self.state
        localctx = SqlBaseParser.ValueExpressionContext(self, self._ctx, _parentState)
        _prevctx = localctx
        _startState = 68
        self.enterRecursionRule(localctx, 68, self.RULE_valueExpression, _p)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 1002
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [SqlBaseParser.T__1, SqlBaseParser.T__4, SqlBaseParser.ADD, SqlBaseParser.ALL, SqlBaseParser.ANALYZE, SqlBaseParser.ANY, SqlBaseParser.ARRAY, SqlBaseParser.ASC, SqlBaseParser.AT, SqlBaseParser.BERNOULLI, SqlBaseParser.CALL, SqlBaseParser.CASCADE, SqlBaseParser.CASE, SqlBaseParser.CAST, SqlBaseParser.CATALOGS, SqlBaseParser.COALESCE, SqlBaseParser.COLUMN, SqlBaseParser.COLUMNS, SqlBaseParser.COMMENT, SqlBaseParser.COMMIT, SqlBaseParser.COMMITTED, SqlBaseParser.CURRENT, SqlBaseParser.CURRENT_DATE, SqlBaseParser.CURRENT_TIME, SqlBaseParser.CURRENT_TIMESTAMP, SqlBaseParser.CURRENT_USER, SqlBaseParser.DATA, SqlBaseParser.DATE, SqlBaseParser.DAY, SqlBaseParser.DESC, SqlBaseParser.DISTRIBUTED, SqlBaseParser.EXCLUDING, SqlBaseParser.EXISTS, SqlBaseParser.EXPLAIN, SqlBaseParser.EXTRACT, SqlBaseParser.FALSE, SqlBaseParser.FILTER, SqlBaseParser.FIRST, SqlBaseParser.FOLLOWING, SqlBaseParser.FORMAT, SqlBaseParser.FUNCTIONS, SqlBaseParser.GRANT, SqlBaseParser.GRANTS, SqlBaseParser.GRAPHVIZ, SqlBaseParser.GROUPING, SqlBaseParser.HOUR, SqlBaseParser.IF, SqlBaseParser.INCLUDING, SqlBaseParser.INPUT, SqlBaseParser.INTEGER, SqlBaseParser.INTERVAL, SqlBaseParser.ISOLATION, SqlBaseParser.LAST, SqlBaseParser.LATERAL, SqlBaseParser.LEVEL, SqlBaseParser.LIMIT, SqlBaseParser.LOCALTIME, SqlBaseParser.LOCALTIMESTAMP, SqlBaseParser.LOGICAL, SqlBaseParser.MAP, SqlBaseParser.MINUTE, SqlBaseParser.MONTH, SqlBaseParser.NFC, SqlBaseParser.NFD, SqlBaseParser.NFKC, SqlBaseParser.NFKD, SqlBaseParser.NO, SqlBaseParser.NORMALIZE, SqlBaseParser.NULL, SqlBaseParser.NULLIF, SqlBaseParser.NULLS, SqlBaseParser.ONLY, SqlBaseParser.OPTION, SqlBaseParser.ORDINALITY, SqlBaseParser.OUTPUT, SqlBaseParser.OVER, SqlBaseParser.PARTITION, SqlBaseParser.PARTITIONS, SqlBaseParser.POSITION, SqlBaseParser.PRECEDING, SqlBaseParser.PRIVILEGES, SqlBaseParser.PROPERTIES, SqlBaseParser.PUBLIC, SqlBaseParser.RANGE, SqlBaseParser.READ, SqlBaseParser.RENAME, SqlBaseParser.REPEATABLE, SqlBaseParser.REPLACE, SqlBaseParser.RESET, SqlBaseParser.RESTRICT, SqlBaseParser.REVOKE, SqlBaseParser.ROLLBACK, SqlBaseParser.ROW, SqlBaseParser.ROWS, SqlBaseParser.SCHEMA, SqlBaseParser.SCHEMAS, SqlBaseParser.SECOND, SqlBaseParser.SERIALIZABLE, SqlBaseParser.SESSION, SqlBaseParser.SET, SqlBaseParser.SETS, SqlBaseParser.SHOW, SqlBaseParser.SMALLINT, SqlBaseParser.SOME, SqlBaseParser.START, SqlBaseParser.STATS, SqlBaseParser.SUBSTRING, SqlBaseParser.SYSTEM, SqlBaseParser.TABLES, SqlBaseParser.TABLESAMPLE, SqlBaseParser.TEXT, SqlBaseParser.TIME, SqlBaseParser.TIMESTAMP, SqlBaseParser.TINYINT, SqlBaseParser.TO, SqlBaseParser.TRANSACTION, SqlBaseParser.TRUE, SqlBaseParser.TRY_CAST, SqlBaseParser.TYPE, SqlBaseParser.UNBOUNDED, SqlBaseParser.UNCOMMITTED, SqlBaseParser.USE, SqlBaseParser.VALIDATE, SqlBaseParser.VERBOSE, SqlBaseParser.VIEW, SqlBaseParser.WORK, SqlBaseParser.WRITE, SqlBaseParser.YEAR, SqlBaseParser.ZONE, SqlBaseParser.STRING, SqlBaseParser.UNICODE_STRING, SqlBaseParser.BINARY_LITERAL, SqlBaseParser.INTEGER_VALUE, SqlBaseParser.DECIMAL_VALUE, SqlBaseParser.DOUBLE_VALUE, SqlBaseParser.IDENTIFIER, SqlBaseParser.DIGIT_IDENTIFIER, SqlBaseParser.QUOTED_IDENTIFIER, SqlBaseParser.BACKQUOTED_IDENTIFIER, SqlBaseParser.DOUBLE_PRECISION]:
                localctx = SqlBaseParser.ValueExpressionDefaultContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx

                self.state = 999
                self.primaryExpression(0)
                pass
            elif token in [SqlBaseParser.PLUS, SqlBaseParser.MINUS]:
                localctx = SqlBaseParser.ArithmeticUnaryContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1000
                localctx.operator = self._input.LT(1)
                _la = self._input.LA(1)
                if not(_la==SqlBaseParser.PLUS or _la==SqlBaseParser.MINUS):
                    localctx.operator = self._errHandler.recoverInline(self)
                else:
                    self._errHandler.reportMatch(self)
                    self.consume()
                self.state = 1001
                self.valueExpression(4)
                pass
            else:
                raise NoViableAltException(self)

            self._ctx.stop = self._input.LT(-1)
            self.state = 1018
            self._errHandler.sync(self)
            _alt = self._interp.adaptivePredict(self._input,129,self._ctx)
            while _alt!=2 and _alt!=ATN.INVALID_ALT_NUMBER:
                if _alt==1:
                    if self._parseListeners is not None:
                        self.triggerExitRuleEvent()
                    _prevctx = localctx
                    self.state = 1016
                    self._errHandler.sync(self)
                    la_ = self._interp.adaptivePredict(self._input,128,self._ctx)
                    if la_ == 1:
                        localctx = SqlBaseParser.ArithmeticBinaryContext(self, SqlBaseParser.ValueExpressionContext(self, _parentctx, _parentState))
                        localctx.left = _prevctx
                        self.pushNewRecursionContext(localctx, _startState, self.RULE_valueExpression)
                        self.state = 1004
                        if not self.precpred(self._ctx, 3):
                            from antlr4.error.Errors import FailedPredicateException
                            raise FailedPredicateException(self, "self.precpred(self._ctx, 3)")
                        self.state = 1005
                        localctx.operator = self._input.LT(1)
                        _la = self._input.LA(1)
                        if not(((((_la - 199)) & ~0x3f) == 0 and ((1 << (_la - 199)) & ((1 << (SqlBaseParser.ASTERISK - 199)) | (1 << (SqlBaseParser.SLASH - 199)) | (1 << (SqlBaseParser.PERCENT - 199)))) != 0)):
                            localctx.operator = self._errHandler.recoverInline(self)
                        else:
                            self._errHandler.reportMatch(self)
                            self.consume()
                        self.state = 1006
                        localctx.right = self.valueExpression(4)
                        pass

                    elif la_ == 2:
                        localctx = SqlBaseParser.ArithmeticBinaryContext(self, SqlBaseParser.ValueExpressionContext(self, _parentctx, _parentState))
                        localctx.left = _prevctx
                        self.pushNewRecursionContext(localctx, _startState, self.RULE_valueExpression)
                        self.state = 1007
                        if not self.precpred(self._ctx, 2):
                            from antlr4.error.Errors import FailedPredicateException
                            raise FailedPredicateException(self, "self.precpred(self._ctx, 2)")
                        self.state = 1008
                        localctx.operator = self._input.LT(1)
                        _la = self._input.LA(1)
                        if not(_la==SqlBaseParser.PLUS or _la==SqlBaseParser.MINUS):
                            localctx.operator = self._errHandler.recoverInline(self)
                        else:
                            self._errHandler.reportMatch(self)
                            self.consume()
                        self.state = 1009
                        localctx.right = self.valueExpression(3)
                        pass

                    elif la_ == 3:
                        localctx = SqlBaseParser.ConcatenationContext(self, SqlBaseParser.ValueExpressionContext(self, _parentctx, _parentState))
                        localctx.left = _prevctx
                        self.pushNewRecursionContext(localctx, _startState, self.RULE_valueExpression)
                        self.state = 1010
                        if not self.precpred(self._ctx, 1):
                            from antlr4.error.Errors import FailedPredicateException
                            raise FailedPredicateException(self, "self.precpred(self._ctx, 1)")
                        self.state = 1011
                        self.match(SqlBaseParser.CONCAT)
                        self.state = 1012
                        localctx.right = self.valueExpression(2)
                        pass

                    elif la_ == 4:
                        localctx = SqlBaseParser.AtTimeZoneContext(self, SqlBaseParser.ValueExpressionContext(self, _parentctx, _parentState))
                        self.pushNewRecursionContext(localctx, _startState, self.RULE_valueExpression)
                        self.state = 1013
                        if not self.precpred(self._ctx, 5):
                            from antlr4.error.Errors import FailedPredicateException
                            raise FailedPredicateException(self, "self.precpred(self._ctx, 5)")
                        self.state = 1014
                        self.match(SqlBaseParser.AT)
                        self.state = 1015
                        self.timeZoneSpecifier()
                        pass

             
                self.state = 1020
                self._errHandler.sync(self)
                _alt = self._interp.adaptivePredict(self._input,129,self._ctx)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.unrollRecursionContexts(_parentctx)
        return localctx

    class PrimaryExpressionContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.PrimaryExpressionContext, self).__init__(parent, invokingState)
            self.parser = parser


        def getRuleIndex(self):
            return SqlBaseParser.RULE_primaryExpression

     
        def copyFrom(self, ctx):
            super(SqlBaseParser.PrimaryExpressionContext, self).copyFrom(ctx)


    class DereferenceContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.DereferenceContext, self).__init__(parser)
            self.base = None # PrimaryExpressionContext
            self.fieldName = None # IdentifierContext
            self.copyFrom(ctx)

        def primaryExpression(self):
            return self.getTypedRuleContext(SqlBaseParser.PrimaryExpressionContext,0)

        def identifier(self):
            return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterDereference"):
                listener.enterDereference(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitDereference"):
                listener.exitDereference(self)


    class TypeConstructorContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.TypeConstructorContext, self).__init__(parser)
            self.copyFrom(ctx)

        def identifier(self):
            return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,0)

        def string(self):
            return self.getTypedRuleContext(SqlBaseParser.StringContext,0)

        def DOUBLE_PRECISION(self):
            return self.getToken(SqlBaseParser.DOUBLE_PRECISION, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterTypeConstructor"):
                listener.enterTypeConstructor(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitTypeConstructor"):
                listener.exitTypeConstructor(self)


    class SpecialDateTimeFunctionContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.SpecialDateTimeFunctionContext, self).__init__(parser)
            self.name = None # Token
            self.precision = None # Token
            self.copyFrom(ctx)

        def CURRENT_DATE(self):
            return self.getToken(SqlBaseParser.CURRENT_DATE, 0)
        def CURRENT_TIME(self):
            return self.getToken(SqlBaseParser.CURRENT_TIME, 0)
        def INTEGER_VALUE(self):
            return self.getToken(SqlBaseParser.INTEGER_VALUE, 0)
        def CURRENT_TIMESTAMP(self):
            return self.getToken(SqlBaseParser.CURRENT_TIMESTAMP, 0)
        def LOCALTIME(self):
            return self.getToken(SqlBaseParser.LOCALTIME, 0)
        def LOCALTIMESTAMP(self):
            return self.getToken(SqlBaseParser.LOCALTIMESTAMP, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterSpecialDateTimeFunction"):
                listener.enterSpecialDateTimeFunction(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitSpecialDateTimeFunction"):
                listener.exitSpecialDateTimeFunction(self)


    class SubstringContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.SubstringContext, self).__init__(parser)
            self.copyFrom(ctx)

        def SUBSTRING(self):
            return self.getToken(SqlBaseParser.SUBSTRING, 0)
        def valueExpression(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.ValueExpressionContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.ValueExpressionContext,i)

        def FROM(self):
            return self.getToken(SqlBaseParser.FROM, 0)
        def FOR(self):
            return self.getToken(SqlBaseParser.FOR, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterSubstring"):
                listener.enterSubstring(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitSubstring"):
                listener.exitSubstring(self)


    class CastContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.CastContext, self).__init__(parser)
            self.copyFrom(ctx)

        def CAST(self):
            return self.getToken(SqlBaseParser.CAST, 0)
        def expression(self):
            return self.getTypedRuleContext(SqlBaseParser.ExpressionContext,0)

        def AS(self):
            return self.getToken(SqlBaseParser.AS, 0)
        def type(self):
            return self.getTypedRuleContext(SqlBaseParser.TypeContext,0)

        def TRY_CAST(self):
            return self.getToken(SqlBaseParser.TRY_CAST, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterCast"):
                listener.enterCast(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitCast"):
                listener.exitCast(self)


    class LambdaContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.LambdaContext, self).__init__(parser)
            self.copyFrom(ctx)

        def identifier(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.IdentifierContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,i)

        def expression(self):
            return self.getTypedRuleContext(SqlBaseParser.ExpressionContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterLambda"):
                listener.enterLambda(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitLambda"):
                listener.exitLambda(self)


    class ParenthesizedExpressionContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.ParenthesizedExpressionContext, self).__init__(parser)
            self.copyFrom(ctx)

        def expression(self):
            return self.getTypedRuleContext(SqlBaseParser.ExpressionContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterParenthesizedExpression"):
                listener.enterParenthesizedExpression(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitParenthesizedExpression"):
                listener.exitParenthesizedExpression(self)


    class ParameterContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.ParameterContext, self).__init__(parser)
            self.copyFrom(ctx)


        def enterRule(self, listener):
            if hasattr(listener, "enterParameter"):
                listener.enterParameter(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitParameter"):
                listener.exitParameter(self)


    class NormalizeContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.NormalizeContext, self).__init__(parser)
            self.copyFrom(ctx)

        def NORMALIZE(self):
            return self.getToken(SqlBaseParser.NORMALIZE, 0)
        def valueExpression(self):
            return self.getTypedRuleContext(SqlBaseParser.ValueExpressionContext,0)

        def normalForm(self):
            return self.getTypedRuleContext(SqlBaseParser.NormalFormContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterNormalize"):
                listener.enterNormalize(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitNormalize"):
                listener.exitNormalize(self)


    class IntervalLiteralContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.IntervalLiteralContext, self).__init__(parser)
            self.copyFrom(ctx)

        def interval(self):
            return self.getTypedRuleContext(SqlBaseParser.IntervalContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterIntervalLiteral"):
                listener.enterIntervalLiteral(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitIntervalLiteral"):
                listener.exitIntervalLiteral(self)


    class NumericLiteralContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.NumericLiteralContext, self).__init__(parser)
            self.copyFrom(ctx)

        def number(self):
            return self.getTypedRuleContext(SqlBaseParser.NumberContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterNumericLiteral"):
                listener.enterNumericLiteral(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitNumericLiteral"):
                listener.exitNumericLiteral(self)


    class BooleanLiteralContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.BooleanLiteralContext, self).__init__(parser)
            self.copyFrom(ctx)

        def booleanValue(self):
            return self.getTypedRuleContext(SqlBaseParser.BooleanValueContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterBooleanLiteral"):
                listener.enterBooleanLiteral(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitBooleanLiteral"):
                listener.exitBooleanLiteral(self)


    class SimpleCaseContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.SimpleCaseContext, self).__init__(parser)
            self.elseExpression = None # ExpressionContext
            self.copyFrom(ctx)

        def CASE(self):
            return self.getToken(SqlBaseParser.CASE, 0)
        def valueExpression(self):
            return self.getTypedRuleContext(SqlBaseParser.ValueExpressionContext,0)

        def END(self):
            return self.getToken(SqlBaseParser.END, 0)
        def whenClause(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.WhenClauseContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.WhenClauseContext,i)

        def ELSE(self):
            return self.getToken(SqlBaseParser.ELSE, 0)
        def expression(self):
            return self.getTypedRuleContext(SqlBaseParser.ExpressionContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterSimpleCase"):
                listener.enterSimpleCase(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitSimpleCase"):
                listener.exitSimpleCase(self)


    class ColumnReferenceContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.ColumnReferenceContext, self).__init__(parser)
            self.copyFrom(ctx)

        def identifier(self):
            return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterColumnReference"):
                listener.enterColumnReference(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitColumnReference"):
                listener.exitColumnReference(self)


    class NullLiteralContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.NullLiteralContext, self).__init__(parser)
            self.copyFrom(ctx)

        def NULL(self):
            return self.getToken(SqlBaseParser.NULL, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterNullLiteral"):
                listener.enterNullLiteral(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitNullLiteral"):
                listener.exitNullLiteral(self)


    class RowConstructorContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.RowConstructorContext, self).__init__(parser)
            self.copyFrom(ctx)

        def expression(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.ExpressionContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.ExpressionContext,i)

        def ROW(self):
            return self.getToken(SqlBaseParser.ROW, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterRowConstructor"):
                listener.enterRowConstructor(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitRowConstructor"):
                listener.exitRowConstructor(self)


    class SubscriptContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.SubscriptContext, self).__init__(parser)
            self.value = None # PrimaryExpressionContext
            self.index = None # ValueExpressionContext
            self.copyFrom(ctx)

        def primaryExpression(self):
            return self.getTypedRuleContext(SqlBaseParser.PrimaryExpressionContext,0)

        def valueExpression(self):
            return self.getTypedRuleContext(SqlBaseParser.ValueExpressionContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterSubscript"):
                listener.enterSubscript(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitSubscript"):
                listener.exitSubscript(self)


    class SubqueryExpressionContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.SubqueryExpressionContext, self).__init__(parser)
            self.copyFrom(ctx)

        def query(self):
            return self.getTypedRuleContext(SqlBaseParser.QueryContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterSubqueryExpression"):
                listener.enterSubqueryExpression(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitSubqueryExpression"):
                listener.exitSubqueryExpression(self)


    class BinaryLiteralContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.BinaryLiteralContext, self).__init__(parser)
            self.copyFrom(ctx)

        def BINARY_LITERAL(self):
            return self.getToken(SqlBaseParser.BINARY_LITERAL, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterBinaryLiteral"):
                listener.enterBinaryLiteral(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitBinaryLiteral"):
                listener.exitBinaryLiteral(self)


    class CurrentUserContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.CurrentUserContext, self).__init__(parser)
            self.name = None # Token
            self.copyFrom(ctx)

        def CURRENT_USER(self):
            return self.getToken(SqlBaseParser.CURRENT_USER, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterCurrentUser"):
                listener.enterCurrentUser(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitCurrentUser"):
                listener.exitCurrentUser(self)


    class ExtractContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.ExtractContext, self).__init__(parser)
            self.copyFrom(ctx)

        def EXTRACT(self):
            return self.getToken(SqlBaseParser.EXTRACT, 0)
        def identifier(self):
            return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,0)

        def FROM(self):
            return self.getToken(SqlBaseParser.FROM, 0)
        def valueExpression(self):
            return self.getTypedRuleContext(SqlBaseParser.ValueExpressionContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterExtract"):
                listener.enterExtract(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitExtract"):
                listener.exitExtract(self)


    class StringLiteralContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.StringLiteralContext, self).__init__(parser)
            self.copyFrom(ctx)

        def string(self):
            return self.getTypedRuleContext(SqlBaseParser.StringContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterStringLiteral"):
                listener.enterStringLiteral(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitStringLiteral"):
                listener.exitStringLiteral(self)


    class ArrayConstructorContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.ArrayConstructorContext, self).__init__(parser)
            self.copyFrom(ctx)

        def ARRAY(self):
            return self.getToken(SqlBaseParser.ARRAY, 0)
        def expression(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.ExpressionContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.ExpressionContext,i)


        def enterRule(self, listener):
            if hasattr(listener, "enterArrayConstructor"):
                listener.enterArrayConstructor(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitArrayConstructor"):
                listener.exitArrayConstructor(self)


    class FunctionCallContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.FunctionCallContext, self).__init__(parser)
            self.copyFrom(ctx)

        def qualifiedName(self):
            return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,0)

        def ASTERISK(self):
            return self.getToken(SqlBaseParser.ASTERISK, 0)
        def filter(self):
            return self.getTypedRuleContext(SqlBaseParser.FilterContext,0)

        def over(self):
            return self.getTypedRuleContext(SqlBaseParser.OverContext,0)

        def expression(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.ExpressionContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.ExpressionContext,i)

        def ORDER(self):
            return self.getToken(SqlBaseParser.ORDER, 0)
        def BY(self):
            return self.getToken(SqlBaseParser.BY, 0)
        def sortItem(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.SortItemContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.SortItemContext,i)

        def setQuantifier(self):
            return self.getTypedRuleContext(SqlBaseParser.SetQuantifierContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterFunctionCall"):
                listener.enterFunctionCall(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitFunctionCall"):
                listener.exitFunctionCall(self)


    class ExistsContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.ExistsContext, self).__init__(parser)
            self.copyFrom(ctx)

        def EXISTS(self):
            return self.getToken(SqlBaseParser.EXISTS, 0)
        def query(self):
            return self.getTypedRuleContext(SqlBaseParser.QueryContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterExists"):
                listener.enterExists(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitExists"):
                listener.exitExists(self)


    class PositionContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.PositionContext, self).__init__(parser)
            self.copyFrom(ctx)

        def POSITION(self):
            return self.getToken(SqlBaseParser.POSITION, 0)
        def valueExpression(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.ValueExpressionContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.ValueExpressionContext,i)

        def IN(self):
            return self.getToken(SqlBaseParser.IN, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterPosition"):
                listener.enterPosition(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitPosition"):
                listener.exitPosition(self)


    class SearchedCaseContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.SearchedCaseContext, self).__init__(parser)
            self.elseExpression = None # ExpressionContext
            self.copyFrom(ctx)

        def CASE(self):
            return self.getToken(SqlBaseParser.CASE, 0)
        def END(self):
            return self.getToken(SqlBaseParser.END, 0)
        def whenClause(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.WhenClauseContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.WhenClauseContext,i)

        def ELSE(self):
            return self.getToken(SqlBaseParser.ELSE, 0)
        def expression(self):
            return self.getTypedRuleContext(SqlBaseParser.ExpressionContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterSearchedCase"):
                listener.enterSearchedCase(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitSearchedCase"):
                listener.exitSearchedCase(self)


    class GroupingOperationContext(PrimaryExpressionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.PrimaryExpressionContext)
            super(SqlBaseParser.GroupingOperationContext, self).__init__(parser)
            self.copyFrom(ctx)

        def GROUPING(self):
            return self.getToken(SqlBaseParser.GROUPING, 0)
        def qualifiedName(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.QualifiedNameContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.QualifiedNameContext,i)


        def enterRule(self, listener):
            if hasattr(listener, "enterGroupingOperation"):
                listener.enterGroupingOperation(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitGroupingOperation"):
                listener.exitGroupingOperation(self)



    def primaryExpression(self, _p=0):
        _parentctx = self._ctx
        _parentState = self.state
        localctx = SqlBaseParser.PrimaryExpressionContext(self, self._ctx, _parentState)
        _prevctx = localctx
        _startState = 70
        self.enterRecursionRule(localctx, 70, self.RULE_primaryExpression, _p)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 1257
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,157,self._ctx)
            if la_ == 1:
                localctx = SqlBaseParser.NullLiteralContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx

                self.state = 1022
                self.match(SqlBaseParser.NULL)
                pass

            elif la_ == 2:
                localctx = SqlBaseParser.IntervalLiteralContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1023
                self.interval()
                pass

            elif la_ == 3:
                localctx = SqlBaseParser.TypeConstructorContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1024
                self.identifier()
                self.state = 1025
                self.string()
                pass

            elif la_ == 4:
                localctx = SqlBaseParser.TypeConstructorContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1027
                self.match(SqlBaseParser.DOUBLE_PRECISION)
                self.state = 1028
                self.string()
                pass

            elif la_ == 5:
                localctx = SqlBaseParser.NumericLiteralContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1029
                self.number()
                pass

            elif la_ == 6:
                localctx = SqlBaseParser.BooleanLiteralContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1030
                self.booleanValue()
                pass

            elif la_ == 7:
                localctx = SqlBaseParser.StringLiteralContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1031
                self.string()
                pass

            elif la_ == 8:
                localctx = SqlBaseParser.BinaryLiteralContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1032
                self.match(SqlBaseParser.BINARY_LITERAL)
                pass

            elif la_ == 9:
                localctx = SqlBaseParser.ParameterContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1033
                self.match(SqlBaseParser.T__4)
                pass

            elif la_ == 10:
                localctx = SqlBaseParser.PositionContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1034
                self.match(SqlBaseParser.POSITION)
                self.state = 1035
                self.match(SqlBaseParser.T__1)
                self.state = 1036
                self.valueExpression(0)
                self.state = 1037
                self.match(SqlBaseParser.IN)
                self.state = 1038
                self.valueExpression(0)
                self.state = 1039
                self.match(SqlBaseParser.T__2)
                pass

            elif la_ == 11:
                localctx = SqlBaseParser.RowConstructorContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1041
                self.match(SqlBaseParser.T__1)
                self.state = 1042
                self.expression()
                self.state = 1045 
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                while True:
                    self.state = 1043
                    self.match(SqlBaseParser.T__3)
                    self.state = 1044
                    self.expression()
                    self.state = 1047 
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)
                    if not (_la==SqlBaseParser.T__3):
                        break

                self.state = 1049
                self.match(SqlBaseParser.T__2)
                pass

            elif la_ == 12:
                localctx = SqlBaseParser.RowConstructorContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1051
                self.match(SqlBaseParser.ROW)
                self.state = 1052
                self.match(SqlBaseParser.T__1)
                self.state = 1053
                self.expression()
                self.state = 1058
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                while _la==SqlBaseParser.T__3:
                    self.state = 1054
                    self.match(SqlBaseParser.T__3)
                    self.state = 1055
                    self.expression()
                    self.state = 1060
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)

                self.state = 1061
                self.match(SqlBaseParser.T__2)
                pass

            elif la_ == 13:
                localctx = SqlBaseParser.FunctionCallContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1063
                self.qualifiedName()
                self.state = 1064
                self.match(SqlBaseParser.T__1)
                self.state = 1065
                self.match(SqlBaseParser.ASTERISK)
                self.state = 1066
                self.match(SqlBaseParser.T__2)
                self.state = 1068
                self._errHandler.sync(self)
                la_ = self._interp.adaptivePredict(self._input,132,self._ctx)
                if la_ == 1:
                    self.state = 1067
                    self.filter()


                self.state = 1071
                self._errHandler.sync(self)
                la_ = self._interp.adaptivePredict(self._input,133,self._ctx)
                if la_ == 1:
                    self.state = 1070
                    self.over()


                pass

            elif la_ == 14:
                localctx = SqlBaseParser.FunctionCallContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1073
                self.qualifiedName()
                self.state = 1074
                self.match(SqlBaseParser.T__1)
                self.state = 1086
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if (((_la) & ~0x3f) == 0 and ((1 << _la) & ((1 << SqlBaseParser.T__1) | (1 << SqlBaseParser.T__4) | (1 << SqlBaseParser.ADD) | (1 << SqlBaseParser.ALL) | (1 << SqlBaseParser.ANALYZE) | (1 << SqlBaseParser.ANY) | (1 << SqlBaseParser.ARRAY) | (1 << SqlBaseParser.ASC) | (1 << SqlBaseParser.AT) | (1 << SqlBaseParser.BERNOULLI) | (1 << SqlBaseParser.CALL) | (1 << SqlBaseParser.CASCADE) | (1 << SqlBaseParser.CASE) | (1 << SqlBaseParser.CAST) | (1 << SqlBaseParser.CATALOGS) | (1 << SqlBaseParser.COALESCE) | (1 << SqlBaseParser.COLUMN) | (1 << SqlBaseParser.COLUMNS) | (1 << SqlBaseParser.COMMENT) | (1 << SqlBaseParser.COMMIT) | (1 << SqlBaseParser.COMMITTED) | (1 << SqlBaseParser.CURRENT) | (1 << SqlBaseParser.CURRENT_DATE) | (1 << SqlBaseParser.CURRENT_TIME) | (1 << SqlBaseParser.CURRENT_TIMESTAMP) | (1 << SqlBaseParser.CURRENT_USER) | (1 << SqlBaseParser.DATA) | (1 << SqlBaseParser.DATE) | (1 << SqlBaseParser.DAY) | (1 << SqlBaseParser.DESC) | (1 << SqlBaseParser.DISTINCT) | (1 << SqlBaseParser.DISTRIBUTED) | (1 << SqlBaseParser.EXCLUDING) | (1 << SqlBaseParser.EXISTS) | (1 << SqlBaseParser.EXPLAIN) | (1 << SqlBaseParser.EXTRACT) | (1 << SqlBaseParser.FALSE) | (1 << SqlBaseParser.FILTER))) != 0) or ((((_la - 64)) & ~0x3f) == 0 and ((1 << (_la - 64)) & ((1 << (SqlBaseParser.FIRST - 64)) | (1 << (SqlBaseParser.FOLLOWING - 64)) | (1 << (SqlBaseParser.FORMAT - 64)) | (1 << (SqlBaseParser.FUNCTIONS - 64)) | (1 << (SqlBaseParser.GRANT - 64)) | (1 << (SqlBaseParser.GRANTS - 64)) | (1 << (SqlBaseParser.GRAPHVIZ - 64)) | (1 << (SqlBaseParser.GROUPING - 64)) | (1 << (SqlBaseParser.HOUR - 64)) | (1 << (SqlBaseParser.IF - 64)) | (1 << (SqlBaseParser.INCLUDING - 64)) | (1 << (SqlBaseParser.INPUT - 64)) | (1 << (SqlBaseParser.INTEGER - 64)) | (1 << (SqlBaseParser.INTERVAL - 64)) | (1 << (SqlBaseParser.ISOLATION - 64)) | (1 << (SqlBaseParser.LAST - 64)) | (1 << (SqlBaseParser.LATERAL - 64)) | (1 << (SqlBaseParser.LEVEL - 64)) | (1 << (SqlBaseParser.LIMIT - 64)) | (1 << (SqlBaseParser.LOCALTIME - 64)) | (1 << (SqlBaseParser.LOCALTIMESTAMP - 64)) | (1 << (SqlBaseParser.LOGICAL - 64)) | (1 << (SqlBaseParser.MAP - 64)) | (1 << (SqlBaseParser.MINUTE - 64)) | (1 << (SqlBaseParser.MONTH - 64)) | (1 << (SqlBaseParser.NFC - 64)) | (1 << (SqlBaseParser.NFD - 64)) | (1 << (SqlBaseParser.NFKC - 64)) | (1 << (SqlBaseParser.NFKD - 64)) | (1 << (SqlBaseParser.NO - 64)) | (1 << (SqlBaseParser.NORMALIZE - 64)) | (1 << (SqlBaseParser.NOT - 64)) | (1 << (SqlBaseParser.NULL - 64)) | (1 << (SqlBaseParser.NULLIF - 64)) | (1 << (SqlBaseParser.NULLS - 64)) | (1 << (SqlBaseParser.ONLY - 64)) | (1 << (SqlBaseParser.OPTION - 64)) | (1 << (SqlBaseParser.ORDINALITY - 64)) | (1 << (SqlBaseParser.OUTPUT - 64)) | (1 << (SqlBaseParser.OVER - 64)) | (1 << (SqlBaseParser.PARTITION - 64)) | (1 << (SqlBaseParser.PARTITIONS - 64)) | (1 << (SqlBaseParser.POSITION - 64)) | (1 << (SqlBaseParser.PRECEDING - 64)))) != 0) or ((((_la - 128)) & ~0x3f) == 0 and ((1 << (_la - 128)) & ((1 << (SqlBaseParser.PRIVILEGES - 128)) | (1 << (SqlBaseParser.PROPERTIES - 128)) | (1 << (SqlBaseParser.PUBLIC - 128)) | (1 << (SqlBaseParser.RANGE - 128)) | (1 << (SqlBaseParser.READ - 128)) | (1 << (SqlBaseParser.RENAME - 128)) | (1 << (SqlBaseParser.REPEATABLE - 128)) | (1 << (SqlBaseParser.REPLACE - 128)) | (1 << (SqlBaseParser.RESET - 128)) | (1 << (SqlBaseParser.RESTRICT - 128)) | (1 << (SqlBaseParser.REVOKE - 128)) | (1 << (SqlBaseParser.ROLLBACK - 128)) | (1 << (SqlBaseParser.ROW - 128)) | (1 << (SqlBaseParser.ROWS - 128)) | (1 << (SqlBaseParser.SCHEMA - 128)) | (1 << (SqlBaseParser.SCHEMAS - 128)) | (1 << (SqlBaseParser.SECOND - 128)) | (1 << (SqlBaseParser.SERIALIZABLE - 128)) | (1 << (SqlBaseParser.SESSION - 128)) | (1 << (SqlBaseParser.SET - 128)) | (1 << (SqlBaseParser.SETS - 128)) | (1 << (SqlBaseParser.SHOW - 128)) | (1 << (SqlBaseParser.SMALLINT - 128)) | (1 << (SqlBaseParser.SOME - 128)) | (1 << (SqlBaseParser.START - 128)) | (1 << (SqlBaseParser.STATS - 128)) | (1 << (SqlBaseParser.SUBSTRING - 128)) | (1 << (SqlBaseParser.SYSTEM - 128)) | (1 << (SqlBaseParser.TABLES - 128)) | (1 << (SqlBaseParser.TABLESAMPLE - 128)) | (1 << (SqlBaseParser.TEXT - 128)) | (1 << (SqlBaseParser.TIME - 128)) | (1 << (SqlBaseParser.TIMESTAMP - 128)) | (1 << (SqlBaseParser.TINYINT - 128)) | (1 << (SqlBaseParser.TO - 128)) | (1 << (SqlBaseParser.TRANSACTION - 128)) | (1 << (SqlBaseParser.TRUE - 128)) | (1 << (SqlBaseParser.TRY_CAST - 128)) | (1 << (SqlBaseParser.TYPE - 128)) | (1 << (SqlBaseParser.UNBOUNDED - 128)) | (1 << (SqlBaseParser.UNCOMMITTED - 128)) | (1 << (SqlBaseParser.USE - 128)) | (1 << (SqlBaseParser.VALIDATE - 128)) | (1 << (SqlBaseParser.VERBOSE - 128)) | (1 << (SqlBaseParser.VIEW - 128)) | (1 << (SqlBaseParser.WORK - 128)) | (1 << (SqlBaseParser.WRITE - 128)) | (1 << (SqlBaseParser.YEAR - 128)) | (1 << (SqlBaseParser.ZONE - 128)))) != 0) or ((((_la - 197)) & ~0x3f) == 0 and ((1 << (_la - 197)) & ((1 << (SqlBaseParser.PLUS - 197)) | (1 << (SqlBaseParser.MINUS - 197)) | (1 << (SqlBaseParser.STRING - 197)) | (1 << (SqlBaseParser.UNICODE_STRING - 197)) | (1 << (SqlBaseParser.BINARY_LITERAL - 197)) | (1 << (SqlBaseParser.INTEGER_VALUE - 197)) | (1 << (SqlBaseParser.DECIMAL_VALUE - 197)) | (1 << (SqlBaseParser.DOUBLE_VALUE - 197)) | (1 << (SqlBaseParser.IDENTIFIER - 197)) | (1 << (SqlBaseParser.DIGIT_IDENTIFIER - 197)) | (1 << (SqlBaseParser.QUOTED_IDENTIFIER - 197)) | (1 << (SqlBaseParser.BACKQUOTED_IDENTIFIER - 197)) | (1 << (SqlBaseParser.DOUBLE_PRECISION - 197)))) != 0):
                    self.state = 1076
                    self._errHandler.sync(self)
                    la_ = self._interp.adaptivePredict(self._input,134,self._ctx)
                    if la_ == 1:
                        self.state = 1075
                        self.setQuantifier()


                    self.state = 1078
                    self.expression()
                    self.state = 1083
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)
                    while _la==SqlBaseParser.T__3:
                        self.state = 1079
                        self.match(SqlBaseParser.T__3)
                        self.state = 1080
                        self.expression()
                        self.state = 1085
                        self._errHandler.sync(self)
                        _la = self._input.LA(1)



                self.state = 1098
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.ORDER:
                    self.state = 1088
                    self.match(SqlBaseParser.ORDER)
                    self.state = 1089
                    self.match(SqlBaseParser.BY)
                    self.state = 1090
                    self.sortItem()
                    self.state = 1095
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)
                    while _la==SqlBaseParser.T__3:
                        self.state = 1091
                        self.match(SqlBaseParser.T__3)
                        self.state = 1092
                        self.sortItem()
                        self.state = 1097
                        self._errHandler.sync(self)
                        _la = self._input.LA(1)



                self.state = 1100
                self.match(SqlBaseParser.T__2)
                self.state = 1102
                self._errHandler.sync(self)
                la_ = self._interp.adaptivePredict(self._input,139,self._ctx)
                if la_ == 1:
                    self.state = 1101
                    self.filter()


                self.state = 1105
                self._errHandler.sync(self)
                la_ = self._interp.adaptivePredict(self._input,140,self._ctx)
                if la_ == 1:
                    self.state = 1104
                    self.over()


                pass

            elif la_ == 15:
                localctx = SqlBaseParser.LambdaContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1107
                self.identifier()
                self.state = 1108
                self.match(SqlBaseParser.T__5)
                self.state = 1109
                self.expression()
                pass

            elif la_ == 16:
                localctx = SqlBaseParser.LambdaContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1111
                self.match(SqlBaseParser.T__1)
                self.state = 1120
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if (((_la) & ~0x3f) == 0 and ((1 << _la) & ((1 << SqlBaseParser.ADD) | (1 << SqlBaseParser.ALL) | (1 << SqlBaseParser.ANALYZE) | (1 << SqlBaseParser.ANY) | (1 << SqlBaseParser.ARRAY) | (1 << SqlBaseParser.ASC) | (1 << SqlBaseParser.AT) | (1 << SqlBaseParser.BERNOULLI) | (1 << SqlBaseParser.CALL) | (1 << SqlBaseParser.CASCADE) | (1 << SqlBaseParser.CATALOGS) | (1 << SqlBaseParser.COALESCE) | (1 << SqlBaseParser.COLUMN) | (1 << SqlBaseParser.COLUMNS) | (1 << SqlBaseParser.COMMENT) | (1 << SqlBaseParser.COMMIT) | (1 << SqlBaseParser.COMMITTED) | (1 << SqlBaseParser.CURRENT) | (1 << SqlBaseParser.DATA) | (1 << SqlBaseParser.DATE) | (1 << SqlBaseParser.DAY) | (1 << SqlBaseParser.DESC) | (1 << SqlBaseParser.DISTRIBUTED) | (1 << SqlBaseParser.EXCLUDING) | (1 << SqlBaseParser.EXPLAIN) | (1 << SqlBaseParser.FILTER))) != 0) or ((((_la - 64)) & ~0x3f) == 0 and ((1 << (_la - 64)) & ((1 << (SqlBaseParser.FIRST - 64)) | (1 << (SqlBaseParser.FOLLOWING - 64)) | (1 << (SqlBaseParser.FORMAT - 64)) | (1 << (SqlBaseParser.FUNCTIONS - 64)) | (1 << (SqlBaseParser.GRANT - 64)) | (1 << (SqlBaseParser.GRANTS - 64)) | (1 << (SqlBaseParser.GRAPHVIZ - 64)) | (1 << (SqlBaseParser.HOUR - 64)) | (1 << (SqlBaseParser.IF - 64)) | (1 << (SqlBaseParser.INCLUDING - 64)) | (1 << (SqlBaseParser.INPUT - 64)) | (1 << (SqlBaseParser.INTEGER - 64)) | (1 << (SqlBaseParser.INTERVAL - 64)) | (1 << (SqlBaseParser.ISOLATION - 64)) | (1 << (SqlBaseParser.LAST - 64)) | (1 << (SqlBaseParser.LATERAL - 64)) | (1 << (SqlBaseParser.LEVEL - 64)) | (1 << (SqlBaseParser.LIMIT - 64)) | (1 << (SqlBaseParser.LOGICAL - 64)) | (1 << (SqlBaseParser.MAP - 64)) | (1 << (SqlBaseParser.MINUTE - 64)) | (1 << (SqlBaseParser.MONTH - 64)) | (1 << (SqlBaseParser.NFC - 64)) | (1 << (SqlBaseParser.NFD - 64)) | (1 << (SqlBaseParser.NFKC - 64)) | (1 << (SqlBaseParser.NFKD - 64)) | (1 << (SqlBaseParser.NO - 64)) | (1 << (SqlBaseParser.NULLIF - 64)) | (1 << (SqlBaseParser.NULLS - 64)) | (1 << (SqlBaseParser.ONLY - 64)) | (1 << (SqlBaseParser.OPTION - 64)) | (1 << (SqlBaseParser.ORDINALITY - 64)) | (1 << (SqlBaseParser.OUTPUT - 64)) | (1 << (SqlBaseParser.OVER - 64)) | (1 << (SqlBaseParser.PARTITION - 64)) | (1 << (SqlBaseParser.PARTITIONS - 64)) | (1 << (SqlBaseParser.POSITION - 64)) | (1 << (SqlBaseParser.PRECEDING - 64)))) != 0) or ((((_la - 128)) & ~0x3f) == 0 and ((1 << (_la - 128)) & ((1 << (SqlBaseParser.PRIVILEGES - 128)) | (1 << (SqlBaseParser.PROPERTIES - 128)) | (1 << (SqlBaseParser.PUBLIC - 128)) | (1 << (SqlBaseParser.RANGE - 128)) | (1 << (SqlBaseParser.READ - 128)) | (1 << (SqlBaseParser.RENAME - 128)) | (1 << (SqlBaseParser.REPEATABLE - 128)) | (1 << (SqlBaseParser.REPLACE - 128)) | (1 << (SqlBaseParser.RESET - 128)) | (1 << (SqlBaseParser.RESTRICT - 128)) | (1 << (SqlBaseParser.REVOKE - 128)) | (1 << (SqlBaseParser.ROLLBACK - 128)) | (1 << (SqlBaseParser.ROW - 128)) | (1 << (SqlBaseParser.ROWS - 128)) | (1 << (SqlBaseParser.SCHEMA - 128)) | (1 << (SqlBaseParser.SCHEMAS - 128)) | (1 << (SqlBaseParser.SECOND - 128)) | (1 << (SqlBaseParser.SERIALIZABLE - 128)) | (1 << (SqlBaseParser.SESSION - 128)) | (1 << (SqlBaseParser.SET - 128)) | (1 << (SqlBaseParser.SETS - 128)) | (1 << (SqlBaseParser.SHOW - 128)) | (1 << (SqlBaseParser.SMALLINT - 128)) | (1 << (SqlBaseParser.SOME - 128)) | (1 << (SqlBaseParser.START - 128)) | (1 << (SqlBaseParser.STATS - 128)) | (1 << (SqlBaseParser.SUBSTRING - 128)) | (1 << (SqlBaseParser.SYSTEM - 128)) | (1 << (SqlBaseParser.TABLES - 128)) | (1 << (SqlBaseParser.TABLESAMPLE - 128)) | (1 << (SqlBaseParser.TEXT - 128)) | (1 << (SqlBaseParser.TIME - 128)) | (1 << (SqlBaseParser.TIMESTAMP - 128)) | (1 << (SqlBaseParser.TINYINT - 128)) | (1 << (SqlBaseParser.TO - 128)) | (1 << (SqlBaseParser.TRANSACTION - 128)) | (1 << (SqlBaseParser.TRY_CAST - 128)) | (1 << (SqlBaseParser.TYPE - 128)) | (1 << (SqlBaseParser.UNBOUNDED - 128)) | (1 << (SqlBaseParser.UNCOMMITTED - 128)) | (1 << (SqlBaseParser.USE - 128)) | (1 << (SqlBaseParser.VALIDATE - 128)) | (1 << (SqlBaseParser.VERBOSE - 128)) | (1 << (SqlBaseParser.VIEW - 128)) | (1 << (SqlBaseParser.WORK - 128)) | (1 << (SqlBaseParser.WRITE - 128)) | (1 << (SqlBaseParser.YEAR - 128)) | (1 << (SqlBaseParser.ZONE - 128)))) != 0) or ((((_la - 209)) & ~0x3f) == 0 and ((1 << (_la - 209)) & ((1 << (SqlBaseParser.IDENTIFIER - 209)) | (1 << (SqlBaseParser.DIGIT_IDENTIFIER - 209)) | (1 << (SqlBaseParser.QUOTED_IDENTIFIER - 209)) | (1 << (SqlBaseParser.BACKQUOTED_IDENTIFIER - 209)))) != 0):
                    self.state = 1112
                    self.identifier()
                    self.state = 1117
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)
                    while _la==SqlBaseParser.T__3:
                        self.state = 1113
                        self.match(SqlBaseParser.T__3)
                        self.state = 1114
                        self.identifier()
                        self.state = 1119
                        self._errHandler.sync(self)
                        _la = self._input.LA(1)



                self.state = 1122
                self.match(SqlBaseParser.T__2)
                self.state = 1123
                self.match(SqlBaseParser.T__5)
                self.state = 1124
                self.expression()
                pass

            elif la_ == 17:
                localctx = SqlBaseParser.SubqueryExpressionContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1125
                self.match(SqlBaseParser.T__1)
                self.state = 1126
                self.query()
                self.state = 1127
                self.match(SqlBaseParser.T__2)
                pass

            elif la_ == 18:
                localctx = SqlBaseParser.ExistsContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1129
                self.match(SqlBaseParser.EXISTS)
                self.state = 1130
                self.match(SqlBaseParser.T__1)
                self.state = 1131
                self.query()
                self.state = 1132
                self.match(SqlBaseParser.T__2)
                pass

            elif la_ == 19:
                localctx = SqlBaseParser.SimpleCaseContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1134
                self.match(SqlBaseParser.CASE)
                self.state = 1135
                self.valueExpression(0)
                self.state = 1137 
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                while True:
                    self.state = 1136
                    self.whenClause()
                    self.state = 1139 
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)
                    if not (_la==SqlBaseParser.WHEN):
                        break

                self.state = 1143
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.ELSE:
                    self.state = 1141
                    self.match(SqlBaseParser.ELSE)
                    self.state = 1142
                    localctx.elseExpression = self.expression()


                self.state = 1145
                self.match(SqlBaseParser.END)
                pass

            elif la_ == 20:
                localctx = SqlBaseParser.SearchedCaseContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1147
                self.match(SqlBaseParser.CASE)
                self.state = 1149 
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                while True:
                    self.state = 1148
                    self.whenClause()
                    self.state = 1151 
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)
                    if not (_la==SqlBaseParser.WHEN):
                        break

                self.state = 1155
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.ELSE:
                    self.state = 1153
                    self.match(SqlBaseParser.ELSE)
                    self.state = 1154
                    localctx.elseExpression = self.expression()


                self.state = 1157
                self.match(SqlBaseParser.END)
                pass

            elif la_ == 21:
                localctx = SqlBaseParser.CastContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1159
                self.match(SqlBaseParser.CAST)
                self.state = 1160
                self.match(SqlBaseParser.T__1)
                self.state = 1161
                self.expression()
                self.state = 1162
                self.match(SqlBaseParser.AS)
                self.state = 1163
                self.type(0)
                self.state = 1164
                self.match(SqlBaseParser.T__2)
                pass

            elif la_ == 22:
                localctx = SqlBaseParser.CastContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1166
                self.match(SqlBaseParser.TRY_CAST)
                self.state = 1167
                self.match(SqlBaseParser.T__1)
                self.state = 1168
                self.expression()
                self.state = 1169
                self.match(SqlBaseParser.AS)
                self.state = 1170
                self.type(0)
                self.state = 1171
                self.match(SqlBaseParser.T__2)
                pass

            elif la_ == 23:
                localctx = SqlBaseParser.ArrayConstructorContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1173
                self.match(SqlBaseParser.ARRAY)
                self.state = 1174
                self.match(SqlBaseParser.T__6)
                self.state = 1183
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if (((_la) & ~0x3f) == 0 and ((1 << _la) & ((1 << SqlBaseParser.T__1) | (1 << SqlBaseParser.T__4) | (1 << SqlBaseParser.ADD) | (1 << SqlBaseParser.ALL) | (1 << SqlBaseParser.ANALYZE) | (1 << SqlBaseParser.ANY) | (1 << SqlBaseParser.ARRAY) | (1 << SqlBaseParser.ASC) | (1 << SqlBaseParser.AT) | (1 << SqlBaseParser.BERNOULLI) | (1 << SqlBaseParser.CALL) | (1 << SqlBaseParser.CASCADE) | (1 << SqlBaseParser.CASE) | (1 << SqlBaseParser.CAST) | (1 << SqlBaseParser.CATALOGS) | (1 << SqlBaseParser.COALESCE) | (1 << SqlBaseParser.COLUMN) | (1 << SqlBaseParser.COLUMNS) | (1 << SqlBaseParser.COMMENT) | (1 << SqlBaseParser.COMMIT) | (1 << SqlBaseParser.COMMITTED) | (1 << SqlBaseParser.CURRENT) | (1 << SqlBaseParser.CURRENT_DATE) | (1 << SqlBaseParser.CURRENT_TIME) | (1 << SqlBaseParser.CURRENT_TIMESTAMP) | (1 << SqlBaseParser.CURRENT_USER) | (1 << SqlBaseParser.DATA) | (1 << SqlBaseParser.DATE) | (1 << SqlBaseParser.DAY) | (1 << SqlBaseParser.DESC) | (1 << SqlBaseParser.DISTRIBUTED) | (1 << SqlBaseParser.EXCLUDING) | (1 << SqlBaseParser.EXISTS) | (1 << SqlBaseParser.EXPLAIN) | (1 << SqlBaseParser.EXTRACT) | (1 << SqlBaseParser.FALSE) | (1 << SqlBaseParser.FILTER))) != 0) or ((((_la - 64)) & ~0x3f) == 0 and ((1 << (_la - 64)) & ((1 << (SqlBaseParser.FIRST - 64)) | (1 << (SqlBaseParser.FOLLOWING - 64)) | (1 << (SqlBaseParser.FORMAT - 64)) | (1 << (SqlBaseParser.FUNCTIONS - 64)) | (1 << (SqlBaseParser.GRANT - 64)) | (1 << (SqlBaseParser.GRANTS - 64)) | (1 << (SqlBaseParser.GRAPHVIZ - 64)) | (1 << (SqlBaseParser.GROUPING - 64)) | (1 << (SqlBaseParser.HOUR - 64)) | (1 << (SqlBaseParser.IF - 64)) | (1 << (SqlBaseParser.INCLUDING - 64)) | (1 << (SqlBaseParser.INPUT - 64)) | (1 << (SqlBaseParser.INTEGER - 64)) | (1 << (SqlBaseParser.INTERVAL - 64)) | (1 << (SqlBaseParser.ISOLATION - 64)) | (1 << (SqlBaseParser.LAST - 64)) | (1 << (SqlBaseParser.LATERAL - 64)) | (1 << (SqlBaseParser.LEVEL - 64)) | (1 << (SqlBaseParser.LIMIT - 64)) | (1 << (SqlBaseParser.LOCALTIME - 64)) | (1 << (SqlBaseParser.LOCALTIMESTAMP - 64)) | (1 << (SqlBaseParser.LOGICAL - 64)) | (1 << (SqlBaseParser.MAP - 64)) | (1 << (SqlBaseParser.MINUTE - 64)) | (1 << (SqlBaseParser.MONTH - 64)) | (1 << (SqlBaseParser.NFC - 64)) | (1 << (SqlBaseParser.NFD - 64)) | (1 << (SqlBaseParser.NFKC - 64)) | (1 << (SqlBaseParser.NFKD - 64)) | (1 << (SqlBaseParser.NO - 64)) | (1 << (SqlBaseParser.NORMALIZE - 64)) | (1 << (SqlBaseParser.NOT - 64)) | (1 << (SqlBaseParser.NULL - 64)) | (1 << (SqlBaseParser.NULLIF - 64)) | (1 << (SqlBaseParser.NULLS - 64)) | (1 << (SqlBaseParser.ONLY - 64)) | (1 << (SqlBaseParser.OPTION - 64)) | (1 << (SqlBaseParser.ORDINALITY - 64)) | (1 << (SqlBaseParser.OUTPUT - 64)) | (1 << (SqlBaseParser.OVER - 64)) | (1 << (SqlBaseParser.PARTITION - 64)) | (1 << (SqlBaseParser.PARTITIONS - 64)) | (1 << (SqlBaseParser.POSITION - 64)) | (1 << (SqlBaseParser.PRECEDING - 64)))) != 0) or ((((_la - 128)) & ~0x3f) == 0 and ((1 << (_la - 128)) & ((1 << (SqlBaseParser.PRIVILEGES - 128)) | (1 << (SqlBaseParser.PROPERTIES - 128)) | (1 << (SqlBaseParser.PUBLIC - 128)) | (1 << (SqlBaseParser.RANGE - 128)) | (1 << (SqlBaseParser.READ - 128)) | (1 << (SqlBaseParser.RENAME - 128)) | (1 << (SqlBaseParser.REPEATABLE - 128)) | (1 << (SqlBaseParser.REPLACE - 128)) | (1 << (SqlBaseParser.RESET - 128)) | (1 << (SqlBaseParser.RESTRICT - 128)) | (1 << (SqlBaseParser.REVOKE - 128)) | (1 << (SqlBaseParser.ROLLBACK - 128)) | (1 << (SqlBaseParser.ROW - 128)) | (1 << (SqlBaseParser.ROWS - 128)) | (1 << (SqlBaseParser.SCHEMA - 128)) | (1 << (SqlBaseParser.SCHEMAS - 128)) | (1 << (SqlBaseParser.SECOND - 128)) | (1 << (SqlBaseParser.SERIALIZABLE - 128)) | (1 << (SqlBaseParser.SESSION - 128)) | (1 << (SqlBaseParser.SET - 128)) | (1 << (SqlBaseParser.SETS - 128)) | (1 << (SqlBaseParser.SHOW - 128)) | (1 << (SqlBaseParser.SMALLINT - 128)) | (1 << (SqlBaseParser.SOME - 128)) | (1 << (SqlBaseParser.START - 128)) | (1 << (SqlBaseParser.STATS - 128)) | (1 << (SqlBaseParser.SUBSTRING - 128)) | (1 << (SqlBaseParser.SYSTEM - 128)) | (1 << (SqlBaseParser.TABLES - 128)) | (1 << (SqlBaseParser.TABLESAMPLE - 128)) | (1 << (SqlBaseParser.TEXT - 128)) | (1 << (SqlBaseParser.TIME - 128)) | (1 << (SqlBaseParser.TIMESTAMP - 128)) | (1 << (SqlBaseParser.TINYINT - 128)) | (1 << (SqlBaseParser.TO - 128)) | (1 << (SqlBaseParser.TRANSACTION - 128)) | (1 << (SqlBaseParser.TRUE - 128)) | (1 << (SqlBaseParser.TRY_CAST - 128)) | (1 << (SqlBaseParser.TYPE - 128)) | (1 << (SqlBaseParser.UNBOUNDED - 128)) | (1 << (SqlBaseParser.UNCOMMITTED - 128)) | (1 << (SqlBaseParser.USE - 128)) | (1 << (SqlBaseParser.VALIDATE - 128)) | (1 << (SqlBaseParser.VERBOSE - 128)) | (1 << (SqlBaseParser.VIEW - 128)) | (1 << (SqlBaseParser.WORK - 128)) | (1 << (SqlBaseParser.WRITE - 128)) | (1 << (SqlBaseParser.YEAR - 128)) | (1 << (SqlBaseParser.ZONE - 128)))) != 0) or ((((_la - 197)) & ~0x3f) == 0 and ((1 << (_la - 197)) & ((1 << (SqlBaseParser.PLUS - 197)) | (1 << (SqlBaseParser.MINUS - 197)) | (1 << (SqlBaseParser.STRING - 197)) | (1 << (SqlBaseParser.UNICODE_STRING - 197)) | (1 << (SqlBaseParser.BINARY_LITERAL - 197)) | (1 << (SqlBaseParser.INTEGER_VALUE - 197)) | (1 << (SqlBaseParser.DECIMAL_VALUE - 197)) | (1 << (SqlBaseParser.DOUBLE_VALUE - 197)) | (1 << (SqlBaseParser.IDENTIFIER - 197)) | (1 << (SqlBaseParser.DIGIT_IDENTIFIER - 197)) | (1 << (SqlBaseParser.QUOTED_IDENTIFIER - 197)) | (1 << (SqlBaseParser.BACKQUOTED_IDENTIFIER - 197)) | (1 << (SqlBaseParser.DOUBLE_PRECISION - 197)))) != 0):
                    self.state = 1175
                    self.expression()
                    self.state = 1180
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)
                    while _la==SqlBaseParser.T__3:
                        self.state = 1176
                        self.match(SqlBaseParser.T__3)
                        self.state = 1177
                        self.expression()
                        self.state = 1182
                        self._errHandler.sync(self)
                        _la = self._input.LA(1)



                self.state = 1185
                self.match(SqlBaseParser.T__7)
                pass

            elif la_ == 24:
                localctx = SqlBaseParser.ColumnReferenceContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1186
                self.identifier()
                pass

            elif la_ == 25:
                localctx = SqlBaseParser.SpecialDateTimeFunctionContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1187
                localctx.name = self.match(SqlBaseParser.CURRENT_DATE)
                pass

            elif la_ == 26:
                localctx = SqlBaseParser.SpecialDateTimeFunctionContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1188
                localctx.name = self.match(SqlBaseParser.CURRENT_TIME)
                self.state = 1192
                self._errHandler.sync(self)
                la_ = self._interp.adaptivePredict(self._input,149,self._ctx)
                if la_ == 1:
                    self.state = 1189
                    self.match(SqlBaseParser.T__1)
                    self.state = 1190
                    localctx.precision = self.match(SqlBaseParser.INTEGER_VALUE)
                    self.state = 1191
                    self.match(SqlBaseParser.T__2)


                pass

            elif la_ == 27:
                localctx = SqlBaseParser.SpecialDateTimeFunctionContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1194
                localctx.name = self.match(SqlBaseParser.CURRENT_TIMESTAMP)
                self.state = 1198
                self._errHandler.sync(self)
                la_ = self._interp.adaptivePredict(self._input,150,self._ctx)
                if la_ == 1:
                    self.state = 1195
                    self.match(SqlBaseParser.T__1)
                    self.state = 1196
                    localctx.precision = self.match(SqlBaseParser.INTEGER_VALUE)
                    self.state = 1197
                    self.match(SqlBaseParser.T__2)


                pass

            elif la_ == 28:
                localctx = SqlBaseParser.SpecialDateTimeFunctionContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1200
                localctx.name = self.match(SqlBaseParser.LOCALTIME)
                self.state = 1204
                self._errHandler.sync(self)
                la_ = self._interp.adaptivePredict(self._input,151,self._ctx)
                if la_ == 1:
                    self.state = 1201
                    self.match(SqlBaseParser.T__1)
                    self.state = 1202
                    localctx.precision = self.match(SqlBaseParser.INTEGER_VALUE)
                    self.state = 1203
                    self.match(SqlBaseParser.T__2)


                pass

            elif la_ == 29:
                localctx = SqlBaseParser.SpecialDateTimeFunctionContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1206
                localctx.name = self.match(SqlBaseParser.LOCALTIMESTAMP)
                self.state = 1210
                self._errHandler.sync(self)
                la_ = self._interp.adaptivePredict(self._input,152,self._ctx)
                if la_ == 1:
                    self.state = 1207
                    self.match(SqlBaseParser.T__1)
                    self.state = 1208
                    localctx.precision = self.match(SqlBaseParser.INTEGER_VALUE)
                    self.state = 1209
                    self.match(SqlBaseParser.T__2)


                pass

            elif la_ == 30:
                localctx = SqlBaseParser.CurrentUserContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1212
                localctx.name = self.match(SqlBaseParser.CURRENT_USER)
                pass

            elif la_ == 31:
                localctx = SqlBaseParser.SubstringContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1213
                self.match(SqlBaseParser.SUBSTRING)
                self.state = 1214
                self.match(SqlBaseParser.T__1)
                self.state = 1215
                self.valueExpression(0)
                self.state = 1216
                self.match(SqlBaseParser.FROM)
                self.state = 1217
                self.valueExpression(0)
                self.state = 1220
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.FOR:
                    self.state = 1218
                    self.match(SqlBaseParser.FOR)
                    self.state = 1219
                    self.valueExpression(0)


                self.state = 1222
                self.match(SqlBaseParser.T__2)
                pass

            elif la_ == 32:
                localctx = SqlBaseParser.NormalizeContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1224
                self.match(SqlBaseParser.NORMALIZE)
                self.state = 1225
                self.match(SqlBaseParser.T__1)
                self.state = 1226
                self.valueExpression(0)
                self.state = 1229
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if _la==SqlBaseParser.T__3:
                    self.state = 1227
                    self.match(SqlBaseParser.T__3)
                    self.state = 1228
                    self.normalForm()


                self.state = 1231
                self.match(SqlBaseParser.T__2)
                pass

            elif la_ == 33:
                localctx = SqlBaseParser.ExtractContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1233
                self.match(SqlBaseParser.EXTRACT)
                self.state = 1234
                self.match(SqlBaseParser.T__1)
                self.state = 1235
                self.identifier()
                self.state = 1236
                self.match(SqlBaseParser.FROM)
                self.state = 1237
                self.valueExpression(0)
                self.state = 1238
                self.match(SqlBaseParser.T__2)
                pass

            elif la_ == 34:
                localctx = SqlBaseParser.ParenthesizedExpressionContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1240
                self.match(SqlBaseParser.T__1)
                self.state = 1241
                self.expression()
                self.state = 1242
                self.match(SqlBaseParser.T__2)
                pass

            elif la_ == 35:
                localctx = SqlBaseParser.GroupingOperationContext(self, localctx)
                self._ctx = localctx
                _prevctx = localctx
                self.state = 1244
                self.match(SqlBaseParser.GROUPING)
                self.state = 1245
                self.match(SqlBaseParser.T__1)
                self.state = 1254
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                if (((_la) & ~0x3f) == 0 and ((1 << _la) & ((1 << SqlBaseParser.ADD) | (1 << SqlBaseParser.ALL) | (1 << SqlBaseParser.ANALYZE) | (1 << SqlBaseParser.ANY) | (1 << SqlBaseParser.ARRAY) | (1 << SqlBaseParser.ASC) | (1 << SqlBaseParser.AT) | (1 << SqlBaseParser.BERNOULLI) | (1 << SqlBaseParser.CALL) | (1 << SqlBaseParser.CASCADE) | (1 << SqlBaseParser.CATALOGS) | (1 << SqlBaseParser.COALESCE) | (1 << SqlBaseParser.COLUMN) | (1 << SqlBaseParser.COLUMNS) | (1 << SqlBaseParser.COMMENT) | (1 << SqlBaseParser.COMMIT) | (1 << SqlBaseParser.COMMITTED) | (1 << SqlBaseParser.CURRENT) | (1 << SqlBaseParser.DATA) | (1 << SqlBaseParser.DATE) | (1 << SqlBaseParser.DAY) | (1 << SqlBaseParser.DESC) | (1 << SqlBaseParser.DISTRIBUTED) | (1 << SqlBaseParser.EXCLUDING) | (1 << SqlBaseParser.EXPLAIN) | (1 << SqlBaseParser.FILTER))) != 0) or ((((_la - 64)) & ~0x3f) == 0 and ((1 << (_la - 64)) & ((1 << (SqlBaseParser.FIRST - 64)) | (1 << (SqlBaseParser.FOLLOWING - 64)) | (1 << (SqlBaseParser.FORMAT - 64)) | (1 << (SqlBaseParser.FUNCTIONS - 64)) | (1 << (SqlBaseParser.GRANT - 64)) | (1 << (SqlBaseParser.GRANTS - 64)) | (1 << (SqlBaseParser.GRAPHVIZ - 64)) | (1 << (SqlBaseParser.HOUR - 64)) | (1 << (SqlBaseParser.IF - 64)) | (1 << (SqlBaseParser.INCLUDING - 64)) | (1 << (SqlBaseParser.INPUT - 64)) | (1 << (SqlBaseParser.INTEGER - 64)) | (1 << (SqlBaseParser.INTERVAL - 64)) | (1 << (SqlBaseParser.ISOLATION - 64)) | (1 << (SqlBaseParser.LAST - 64)) | (1 << (SqlBaseParser.LATERAL - 64)) | (1 << (SqlBaseParser.LEVEL - 64)) | (1 << (SqlBaseParser.LIMIT - 64)) | (1 << (SqlBaseParser.LOGICAL - 64)) | (1 << (SqlBaseParser.MAP - 64)) | (1 << (SqlBaseParser.MINUTE - 64)) | (1 << (SqlBaseParser.MONTH - 64)) | (1 << (SqlBaseParser.NFC - 64)) | (1 << (SqlBaseParser.NFD - 64)) | (1 << (SqlBaseParser.NFKC - 64)) | (1 << (SqlBaseParser.NFKD - 64)) | (1 << (SqlBaseParser.NO - 64)) | (1 << (SqlBaseParser.NULLIF - 64)) | (1 << (SqlBaseParser.NULLS - 64)) | (1 << (SqlBaseParser.ONLY - 64)) | (1 << (SqlBaseParser.OPTION - 64)) | (1 << (SqlBaseParser.ORDINALITY - 64)) | (1 << (SqlBaseParser.OUTPUT - 64)) | (1 << (SqlBaseParser.OVER - 64)) | (1 << (SqlBaseParser.PARTITION - 64)) | (1 << (SqlBaseParser.PARTITIONS - 64)) | (1 << (SqlBaseParser.POSITION - 64)) | (1 << (SqlBaseParser.PRECEDING - 64)))) != 0) or ((((_la - 128)) & ~0x3f) == 0 and ((1 << (_la - 128)) & ((1 << (SqlBaseParser.PRIVILEGES - 128)) | (1 << (SqlBaseParser.PROPERTIES - 128)) | (1 << (SqlBaseParser.PUBLIC - 128)) | (1 << (SqlBaseParser.RANGE - 128)) | (1 << (SqlBaseParser.READ - 128)) | (1 << (SqlBaseParser.RENAME - 128)) | (1 << (SqlBaseParser.REPEATABLE - 128)) | (1 << (SqlBaseParser.REPLACE - 128)) | (1 << (SqlBaseParser.RESET - 128)) | (1 << (SqlBaseParser.RESTRICT - 128)) | (1 << (SqlBaseParser.REVOKE - 128)) | (1 << (SqlBaseParser.ROLLBACK - 128)) | (1 << (SqlBaseParser.ROW - 128)) | (1 << (SqlBaseParser.ROWS - 128)) | (1 << (SqlBaseParser.SCHEMA - 128)) | (1 << (SqlBaseParser.SCHEMAS - 128)) | (1 << (SqlBaseParser.SECOND - 128)) | (1 << (SqlBaseParser.SERIALIZABLE - 128)) | (1 << (SqlBaseParser.SESSION - 128)) | (1 << (SqlBaseParser.SET - 128)) | (1 << (SqlBaseParser.SETS - 128)) | (1 << (SqlBaseParser.SHOW - 128)) | (1 << (SqlBaseParser.SMALLINT - 128)) | (1 << (SqlBaseParser.SOME - 128)) | (1 << (SqlBaseParser.START - 128)) | (1 << (SqlBaseParser.STATS - 128)) | (1 << (SqlBaseParser.SUBSTRING - 128)) | (1 << (SqlBaseParser.SYSTEM - 128)) | (1 << (SqlBaseParser.TABLES - 128)) | (1 << (SqlBaseParser.TABLESAMPLE - 128)) | (1 << (SqlBaseParser.TEXT - 128)) | (1 << (SqlBaseParser.TIME - 128)) | (1 << (SqlBaseParser.TIMESTAMP - 128)) | (1 << (SqlBaseParser.TINYINT - 128)) | (1 << (SqlBaseParser.TO - 128)) | (1 << (SqlBaseParser.TRANSACTION - 128)) | (1 << (SqlBaseParser.TRY_CAST - 128)) | (1 << (SqlBaseParser.TYPE - 128)) | (1 << (SqlBaseParser.UNBOUNDED - 128)) | (1 << (SqlBaseParser.UNCOMMITTED - 128)) | (1 << (SqlBaseParser.USE - 128)) | (1 << (SqlBaseParser.VALIDATE - 128)) | (1 << (SqlBaseParser.VERBOSE - 128)) | (1 << (SqlBaseParser.VIEW - 128)) | (1 << (SqlBaseParser.WORK - 128)) | (1 << (SqlBaseParser.WRITE - 128)) | (1 << (SqlBaseParser.YEAR - 128)) | (1 << (SqlBaseParser.ZONE - 128)))) != 0) or ((((_la - 209)) & ~0x3f) == 0 and ((1 << (_la - 209)) & ((1 << (SqlBaseParser.IDENTIFIER - 209)) | (1 << (SqlBaseParser.DIGIT_IDENTIFIER - 209)) | (1 << (SqlBaseParser.QUOTED_IDENTIFIER - 209)) | (1 << (SqlBaseParser.BACKQUOTED_IDENTIFIER - 209)))) != 0):
                    self.state = 1246
                    self.qualifiedName()
                    self.state = 1251
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)
                    while _la==SqlBaseParser.T__3:
                        self.state = 1247
                        self.match(SqlBaseParser.T__3)
                        self.state = 1248
                        self.qualifiedName()
                        self.state = 1253
                        self._errHandler.sync(self)
                        _la = self._input.LA(1)



                self.state = 1256
                self.match(SqlBaseParser.T__2)
                pass


            self._ctx.stop = self._input.LT(-1)
            self.state = 1269
            self._errHandler.sync(self)
            _alt = self._interp.adaptivePredict(self._input,159,self._ctx)
            while _alt!=2 and _alt!=ATN.INVALID_ALT_NUMBER:
                if _alt==1:
                    if self._parseListeners is not None:
                        self.triggerExitRuleEvent()
                    _prevctx = localctx
                    self.state = 1267
                    self._errHandler.sync(self)
                    la_ = self._interp.adaptivePredict(self._input,158,self._ctx)
                    if la_ == 1:
                        localctx = SqlBaseParser.SubscriptContext(self, SqlBaseParser.PrimaryExpressionContext(self, _parentctx, _parentState))
                        localctx.value = _prevctx
                        self.pushNewRecursionContext(localctx, _startState, self.RULE_primaryExpression)
                        self.state = 1259
                        if not self.precpred(self._ctx, 14):
                            from antlr4.error.Errors import FailedPredicateException
                            raise FailedPredicateException(self, "self.precpred(self._ctx, 14)")
                        self.state = 1260
                        self.match(SqlBaseParser.T__6)
                        self.state = 1261
                        localctx.index = self.valueExpression(0)
                        self.state = 1262
                        self.match(SqlBaseParser.T__7)
                        pass

                    elif la_ == 2:
                        localctx = SqlBaseParser.DereferenceContext(self, SqlBaseParser.PrimaryExpressionContext(self, _parentctx, _parentState))
                        localctx.base = _prevctx
                        self.pushNewRecursionContext(localctx, _startState, self.RULE_primaryExpression)
                        self.state = 1264
                        if not self.precpred(self._ctx, 12):
                            from antlr4.error.Errors import FailedPredicateException
                            raise FailedPredicateException(self, "self.precpred(self._ctx, 12)")
                        self.state = 1265
                        self.match(SqlBaseParser.T__0)
                        self.state = 1266
                        localctx.fieldName = self.identifier()
                        pass

             
                self.state = 1271
                self._errHandler.sync(self)
                _alt = self._interp.adaptivePredict(self._input,159,self._ctx)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.unrollRecursionContexts(_parentctx)
        return localctx

    class StringContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.StringContext, self).__init__(parent, invokingState)
            self.parser = parser


        def getRuleIndex(self):
            return SqlBaseParser.RULE_string

     
        def copyFrom(self, ctx):
            super(SqlBaseParser.StringContext, self).copyFrom(ctx)



    class UnicodeStringLiteralContext(StringContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StringContext)
            super(SqlBaseParser.UnicodeStringLiteralContext, self).__init__(parser)
            self.copyFrom(ctx)

        def UNICODE_STRING(self):
            return self.getToken(SqlBaseParser.UNICODE_STRING, 0)
        def UESCAPE(self):
            return self.getToken(SqlBaseParser.UESCAPE, 0)
        def STRING(self):
            return self.getToken(SqlBaseParser.STRING, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterUnicodeStringLiteral"):
                listener.enterUnicodeStringLiteral(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitUnicodeStringLiteral"):
                listener.exitUnicodeStringLiteral(self)


    class BasicStringLiteralContext(StringContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.StringContext)
            super(SqlBaseParser.BasicStringLiteralContext, self).__init__(parser)
            self.copyFrom(ctx)

        def STRING(self):
            return self.getToken(SqlBaseParser.STRING, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterBasicStringLiteral"):
                listener.enterBasicStringLiteral(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitBasicStringLiteral"):
                listener.exitBasicStringLiteral(self)



    def string(self):

        localctx = SqlBaseParser.StringContext(self, self._ctx, self.state)
        self.enterRule(localctx, 72, self.RULE_string)
        try:
            self.state = 1278
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [SqlBaseParser.STRING]:
                localctx = SqlBaseParser.BasicStringLiteralContext(self, localctx)
                self.enterOuterAlt(localctx, 1)
                self.state = 1272
                self.match(SqlBaseParser.STRING)
                pass
            elif token in [SqlBaseParser.UNICODE_STRING]:
                localctx = SqlBaseParser.UnicodeStringLiteralContext(self, localctx)
                self.enterOuterAlt(localctx, 2)
                self.state = 1273
                self.match(SqlBaseParser.UNICODE_STRING)
                self.state = 1276
                self._errHandler.sync(self)
                la_ = self._interp.adaptivePredict(self._input,160,self._ctx)
                if la_ == 1:
                    self.state = 1274
                    self.match(SqlBaseParser.UESCAPE)
                    self.state = 1275
                    self.match(SqlBaseParser.STRING)


                pass
            else:
                raise NoViableAltException(self)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class TimeZoneSpecifierContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.TimeZoneSpecifierContext, self).__init__(parent, invokingState)
            self.parser = parser


        def getRuleIndex(self):
            return SqlBaseParser.RULE_timeZoneSpecifier

     
        def copyFrom(self, ctx):
            super(SqlBaseParser.TimeZoneSpecifierContext, self).copyFrom(ctx)



    class TimeZoneIntervalContext(TimeZoneSpecifierContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.TimeZoneSpecifierContext)
            super(SqlBaseParser.TimeZoneIntervalContext, self).__init__(parser)
            self.copyFrom(ctx)

        def TIME(self):
            return self.getToken(SqlBaseParser.TIME, 0)
        def ZONE(self):
            return self.getToken(SqlBaseParser.ZONE, 0)
        def interval(self):
            return self.getTypedRuleContext(SqlBaseParser.IntervalContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterTimeZoneInterval"):
                listener.enterTimeZoneInterval(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitTimeZoneInterval"):
                listener.exitTimeZoneInterval(self)


    class TimeZoneStringContext(TimeZoneSpecifierContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.TimeZoneSpecifierContext)
            super(SqlBaseParser.TimeZoneStringContext, self).__init__(parser)
            self.copyFrom(ctx)

        def TIME(self):
            return self.getToken(SqlBaseParser.TIME, 0)
        def ZONE(self):
            return self.getToken(SqlBaseParser.ZONE, 0)
        def string(self):
            return self.getTypedRuleContext(SqlBaseParser.StringContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterTimeZoneString"):
                listener.enterTimeZoneString(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitTimeZoneString"):
                listener.exitTimeZoneString(self)



    def timeZoneSpecifier(self):

        localctx = SqlBaseParser.TimeZoneSpecifierContext(self, self._ctx, self.state)
        self.enterRule(localctx, 74, self.RULE_timeZoneSpecifier)
        try:
            self.state = 1286
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,162,self._ctx)
            if la_ == 1:
                localctx = SqlBaseParser.TimeZoneIntervalContext(self, localctx)
                self.enterOuterAlt(localctx, 1)
                self.state = 1280
                self.match(SqlBaseParser.TIME)
                self.state = 1281
                self.match(SqlBaseParser.ZONE)
                self.state = 1282
                self.interval()
                pass

            elif la_ == 2:
                localctx = SqlBaseParser.TimeZoneStringContext(self, localctx)
                self.enterOuterAlt(localctx, 2)
                self.state = 1283
                self.match(SqlBaseParser.TIME)
                self.state = 1284
                self.match(SqlBaseParser.ZONE)
                self.state = 1285
                self.string()
                pass


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class ComparisonOperatorContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.ComparisonOperatorContext, self).__init__(parent, invokingState)
            self.parser = parser

        def EQ(self):
            return self.getToken(SqlBaseParser.EQ, 0)

        def NEQ(self):
            return self.getToken(SqlBaseParser.NEQ, 0)

        def LT(self):
            return self.getToken(SqlBaseParser.LT, 0)

        def LTE(self):
            return self.getToken(SqlBaseParser.LTE, 0)

        def GT(self):
            return self.getToken(SqlBaseParser.GT, 0)

        def GTE(self):
            return self.getToken(SqlBaseParser.GTE, 0)

        def getRuleIndex(self):
            return SqlBaseParser.RULE_comparisonOperator

        def enterRule(self, listener):
            if hasattr(listener, "enterComparisonOperator"):
                listener.enterComparisonOperator(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitComparisonOperator"):
                listener.exitComparisonOperator(self)




    def comparisonOperator(self):

        localctx = SqlBaseParser.ComparisonOperatorContext(self, self._ctx, self.state)
        self.enterRule(localctx, 76, self.RULE_comparisonOperator)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 1288
            _la = self._input.LA(1)
            if not(((((_la - 191)) & ~0x3f) == 0 and ((1 << (_la - 191)) & ((1 << (SqlBaseParser.EQ - 191)) | (1 << (SqlBaseParser.NEQ - 191)) | (1 << (SqlBaseParser.LT - 191)) | (1 << (SqlBaseParser.LTE - 191)) | (1 << (SqlBaseParser.GT - 191)) | (1 << (SqlBaseParser.GTE - 191)))) != 0)):
                self._errHandler.recoverInline(self)
            else:
                self._errHandler.reportMatch(self)
                self.consume()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class ComparisonQuantifierContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.ComparisonQuantifierContext, self).__init__(parent, invokingState)
            self.parser = parser

        def ALL(self):
            return self.getToken(SqlBaseParser.ALL, 0)

        def SOME(self):
            return self.getToken(SqlBaseParser.SOME, 0)

        def ANY(self):
            return self.getToken(SqlBaseParser.ANY, 0)

        def getRuleIndex(self):
            return SqlBaseParser.RULE_comparisonQuantifier

        def enterRule(self, listener):
            if hasattr(listener, "enterComparisonQuantifier"):
                listener.enterComparisonQuantifier(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitComparisonQuantifier"):
                listener.exitComparisonQuantifier(self)




    def comparisonQuantifier(self):

        localctx = SqlBaseParser.ComparisonQuantifierContext(self, self._ctx, self.state)
        self.enterRule(localctx, 78, self.RULE_comparisonQuantifier)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 1290
            _la = self._input.LA(1)
            if not(_la==SqlBaseParser.ALL or _la==SqlBaseParser.ANY or _la==SqlBaseParser.SOME):
                self._errHandler.recoverInline(self)
            else:
                self._errHandler.reportMatch(self)
                self.consume()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class BooleanValueContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.BooleanValueContext, self).__init__(parent, invokingState)
            self.parser = parser

        def TRUE(self):
            return self.getToken(SqlBaseParser.TRUE, 0)

        def FALSE(self):
            return self.getToken(SqlBaseParser.FALSE, 0)

        def getRuleIndex(self):
            return SqlBaseParser.RULE_booleanValue

        def enterRule(self, listener):
            if hasattr(listener, "enterBooleanValue"):
                listener.enterBooleanValue(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitBooleanValue"):
                listener.exitBooleanValue(self)




    def booleanValue(self):

        localctx = SqlBaseParser.BooleanValueContext(self, self._ctx, self.state)
        self.enterRule(localctx, 80, self.RULE_booleanValue)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 1292
            _la = self._input.LA(1)
            if not(_la==SqlBaseParser.FALSE or _la==SqlBaseParser.TRUE):
                self._errHandler.recoverInline(self)
            else:
                self._errHandler.reportMatch(self)
                self.consume()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class IntervalContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.IntervalContext, self).__init__(parent, invokingState)
            self.parser = parser
            self.sign = None # Token
            self._from = None # IntervalFieldContext
            self.to = None # IntervalFieldContext

        def INTERVAL(self):
            return self.getToken(SqlBaseParser.INTERVAL, 0)

        def string(self):
            return self.getTypedRuleContext(SqlBaseParser.StringContext,0)


        def intervalField(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.IntervalFieldContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.IntervalFieldContext,i)


        def TO(self):
            return self.getToken(SqlBaseParser.TO, 0)

        def PLUS(self):
            return self.getToken(SqlBaseParser.PLUS, 0)

        def MINUS(self):
            return self.getToken(SqlBaseParser.MINUS, 0)

        def getRuleIndex(self):
            return SqlBaseParser.RULE_interval

        def enterRule(self, listener):
            if hasattr(listener, "enterInterval"):
                listener.enterInterval(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitInterval"):
                listener.exitInterval(self)




    def interval(self):

        localctx = SqlBaseParser.IntervalContext(self, self._ctx, self.state)
        self.enterRule(localctx, 82, self.RULE_interval)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 1294
            self.match(SqlBaseParser.INTERVAL)
            self.state = 1296
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==SqlBaseParser.PLUS or _la==SqlBaseParser.MINUS:
                self.state = 1295
                localctx.sign = self._input.LT(1)
                _la = self._input.LA(1)
                if not(_la==SqlBaseParser.PLUS or _la==SqlBaseParser.MINUS):
                    localctx.sign = self._errHandler.recoverInline(self)
                else:
                    self._errHandler.reportMatch(self)
                    self.consume()


            self.state = 1298
            self.string()
            self.state = 1299
            localctx._from = self.intervalField()
            self.state = 1302
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,164,self._ctx)
            if la_ == 1:
                self.state = 1300
                self.match(SqlBaseParser.TO)
                self.state = 1301
                localctx.to = self.intervalField()


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class IntervalFieldContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.IntervalFieldContext, self).__init__(parent, invokingState)
            self.parser = parser

        def YEAR(self):
            return self.getToken(SqlBaseParser.YEAR, 0)

        def MONTH(self):
            return self.getToken(SqlBaseParser.MONTH, 0)

        def DAY(self):
            return self.getToken(SqlBaseParser.DAY, 0)

        def HOUR(self):
            return self.getToken(SqlBaseParser.HOUR, 0)

        def MINUTE(self):
            return self.getToken(SqlBaseParser.MINUTE, 0)

        def SECOND(self):
            return self.getToken(SqlBaseParser.SECOND, 0)

        def getRuleIndex(self):
            return SqlBaseParser.RULE_intervalField

        def enterRule(self, listener):
            if hasattr(listener, "enterIntervalField"):
                listener.enterIntervalField(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitIntervalField"):
                listener.exitIntervalField(self)




    def intervalField(self):

        localctx = SqlBaseParser.IntervalFieldContext(self, self._ctx, self.state)
        self.enterRule(localctx, 84, self.RULE_intervalField)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 1304
            _la = self._input.LA(1)
            if not(((((_la - 45)) & ~0x3f) == 0 and ((1 << (_la - 45)) & ((1 << (SqlBaseParser.DAY - 45)) | (1 << (SqlBaseParser.HOUR - 45)) | (1 << (SqlBaseParser.MINUTE - 45)) | (1 << (SqlBaseParser.MONTH - 45)))) != 0) or _la==SqlBaseParser.SECOND or _la==SqlBaseParser.YEAR):
                self._errHandler.recoverInline(self)
            else:
                self._errHandler.reportMatch(self)
                self.consume()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class NormalFormContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.NormalFormContext, self).__init__(parent, invokingState)
            self.parser = parser

        def NFD(self):
            return self.getToken(SqlBaseParser.NFD, 0)

        def NFC(self):
            return self.getToken(SqlBaseParser.NFC, 0)

        def NFKD(self):
            return self.getToken(SqlBaseParser.NFKD, 0)

        def NFKC(self):
            return self.getToken(SqlBaseParser.NFKC, 0)

        def getRuleIndex(self):
            return SqlBaseParser.RULE_normalForm

        def enterRule(self, listener):
            if hasattr(listener, "enterNormalForm"):
                listener.enterNormalForm(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitNormalForm"):
                listener.exitNormalForm(self)




    def normalForm(self):

        localctx = SqlBaseParser.NormalFormContext(self, self._ctx, self.state)
        self.enterRule(localctx, 86, self.RULE_normalForm)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 1306
            _la = self._input.LA(1)
            if not(((((_la - 104)) & ~0x3f) == 0 and ((1 << (_la - 104)) & ((1 << (SqlBaseParser.NFC - 104)) | (1 << (SqlBaseParser.NFD - 104)) | (1 << (SqlBaseParser.NFKC - 104)) | (1 << (SqlBaseParser.NFKD - 104)))) != 0)):
                self._errHandler.recoverInline(self)
            else:
                self._errHandler.reportMatch(self)
                self.consume()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class TypeContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.TypeContext, self).__init__(parent, invokingState)
            self.parser = parser
            self._from = None # IntervalFieldContext
            self.to = None # IntervalFieldContext

        def ARRAY(self):
            return self.getToken(SqlBaseParser.ARRAY, 0)

        def type(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.TypeContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.TypeContext,i)


        def MAP(self):
            return self.getToken(SqlBaseParser.MAP, 0)

        def ROW(self):
            return self.getToken(SqlBaseParser.ROW, 0)

        def identifier(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.IdentifierContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,i)


        def baseType(self):
            return self.getTypedRuleContext(SqlBaseParser.BaseTypeContext,0)


        def typeParameter(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.TypeParameterContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.TypeParameterContext,i)


        def INTERVAL(self):
            return self.getToken(SqlBaseParser.INTERVAL, 0)

        def TO(self):
            return self.getToken(SqlBaseParser.TO, 0)

        def intervalField(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.IntervalFieldContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.IntervalFieldContext,i)


        def getRuleIndex(self):
            return SqlBaseParser.RULE_type

        def enterRule(self, listener):
            if hasattr(listener, "enterType"):
                listener.enterType(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitType"):
                listener.exitType(self)



    def type(self, _p=0):
        _parentctx = self._ctx
        _parentState = self.state
        localctx = SqlBaseParser.TypeContext(self, self._ctx, _parentState)
        _prevctx = localctx
        _startState = 88
        self.enterRecursionRule(localctx, 88, self.RULE_type, _p)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 1355
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,168,self._ctx)
            if la_ == 1:
                self.state = 1309
                self.match(SqlBaseParser.ARRAY)
                self.state = 1310
                self.match(SqlBaseParser.LT)
                self.state = 1311
                self.type(0)
                self.state = 1312
                self.match(SqlBaseParser.GT)
                pass

            elif la_ == 2:
                self.state = 1314
                self.match(SqlBaseParser.MAP)
                self.state = 1315
                self.match(SqlBaseParser.LT)
                self.state = 1316
                self.type(0)
                self.state = 1317
                self.match(SqlBaseParser.T__3)
                self.state = 1318
                self.type(0)
                self.state = 1319
                self.match(SqlBaseParser.GT)
                pass

            elif la_ == 3:
                self.state = 1321
                self.match(SqlBaseParser.ROW)
                self.state = 1322
                self.match(SqlBaseParser.T__1)
                self.state = 1323
                self.identifier()
                self.state = 1324
                self.type(0)
                self.state = 1331
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                while _la==SqlBaseParser.T__3:
                    self.state = 1325
                    self.match(SqlBaseParser.T__3)
                    self.state = 1326
                    self.identifier()
                    self.state = 1327
                    self.type(0)
                    self.state = 1333
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)

                self.state = 1334
                self.match(SqlBaseParser.T__2)
                pass

            elif la_ == 4:
                self.state = 1336
                self.baseType()
                self.state = 1348
                self._errHandler.sync(self)
                la_ = self._interp.adaptivePredict(self._input,167,self._ctx)
                if la_ == 1:
                    self.state = 1337
                    self.match(SqlBaseParser.T__1)
                    self.state = 1338
                    self.typeParameter()
                    self.state = 1343
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)
                    while _la==SqlBaseParser.T__3:
                        self.state = 1339
                        self.match(SqlBaseParser.T__3)
                        self.state = 1340
                        self.typeParameter()
                        self.state = 1345
                        self._errHandler.sync(self)
                        _la = self._input.LA(1)

                    self.state = 1346
                    self.match(SqlBaseParser.T__2)


                pass

            elif la_ == 5:
                self.state = 1350
                self.match(SqlBaseParser.INTERVAL)
                self.state = 1351
                localctx._from = self.intervalField()
                self.state = 1352
                self.match(SqlBaseParser.TO)
                self.state = 1353
                localctx.to = self.intervalField()
                pass


            self._ctx.stop = self._input.LT(-1)
            self.state = 1361
            self._errHandler.sync(self)
            _alt = self._interp.adaptivePredict(self._input,169,self._ctx)
            while _alt!=2 and _alt!=ATN.INVALID_ALT_NUMBER:
                if _alt==1:
                    if self._parseListeners is not None:
                        self.triggerExitRuleEvent()
                    _prevctx = localctx
                    localctx = SqlBaseParser.TypeContext(self, _parentctx, _parentState)
                    self.pushNewRecursionContext(localctx, _startState, self.RULE_type)
                    self.state = 1357
                    if not self.precpred(self._ctx, 6):
                        from antlr4.error.Errors import FailedPredicateException
                        raise FailedPredicateException(self, "self.precpred(self._ctx, 6)")
                    self.state = 1358
                    self.match(SqlBaseParser.ARRAY) 
                self.state = 1363
                self._errHandler.sync(self)
                _alt = self._interp.adaptivePredict(self._input,169,self._ctx)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.unrollRecursionContexts(_parentctx)
        return localctx

    class TypeParameterContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.TypeParameterContext, self).__init__(parent, invokingState)
            self.parser = parser

        def INTEGER_VALUE(self):
            return self.getToken(SqlBaseParser.INTEGER_VALUE, 0)

        def type(self):
            return self.getTypedRuleContext(SqlBaseParser.TypeContext,0)


        def getRuleIndex(self):
            return SqlBaseParser.RULE_typeParameter

        def enterRule(self, listener):
            if hasattr(listener, "enterTypeParameter"):
                listener.enterTypeParameter(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitTypeParameter"):
                listener.exitTypeParameter(self)




    def typeParameter(self):

        localctx = SqlBaseParser.TypeParameterContext(self, self._ctx, self.state)
        self.enterRule(localctx, 90, self.RULE_typeParameter)
        try:
            self.state = 1366
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [SqlBaseParser.INTEGER_VALUE]:
                self.enterOuterAlt(localctx, 1)
                self.state = 1364
                self.match(SqlBaseParser.INTEGER_VALUE)
                pass
            elif token in [SqlBaseParser.ADD, SqlBaseParser.ALL, SqlBaseParser.ANALYZE, SqlBaseParser.ANY, SqlBaseParser.ARRAY, SqlBaseParser.ASC, SqlBaseParser.AT, SqlBaseParser.BERNOULLI, SqlBaseParser.CALL, SqlBaseParser.CASCADE, SqlBaseParser.CATALOGS, SqlBaseParser.COALESCE, SqlBaseParser.COLUMN, SqlBaseParser.COLUMNS, SqlBaseParser.COMMENT, SqlBaseParser.COMMIT, SqlBaseParser.COMMITTED, SqlBaseParser.CURRENT, SqlBaseParser.DATA, SqlBaseParser.DATE, SqlBaseParser.DAY, SqlBaseParser.DESC, SqlBaseParser.DISTRIBUTED, SqlBaseParser.EXCLUDING, SqlBaseParser.EXPLAIN, SqlBaseParser.FILTER, SqlBaseParser.FIRST, SqlBaseParser.FOLLOWING, SqlBaseParser.FORMAT, SqlBaseParser.FUNCTIONS, SqlBaseParser.GRANT, SqlBaseParser.GRANTS, SqlBaseParser.GRAPHVIZ, SqlBaseParser.HOUR, SqlBaseParser.IF, SqlBaseParser.INCLUDING, SqlBaseParser.INPUT, SqlBaseParser.INTEGER, SqlBaseParser.INTERVAL, SqlBaseParser.ISOLATION, SqlBaseParser.LAST, SqlBaseParser.LATERAL, SqlBaseParser.LEVEL, SqlBaseParser.LIMIT, SqlBaseParser.LOGICAL, SqlBaseParser.MAP, SqlBaseParser.MINUTE, SqlBaseParser.MONTH, SqlBaseParser.NFC, SqlBaseParser.NFD, SqlBaseParser.NFKC, SqlBaseParser.NFKD, SqlBaseParser.NO, SqlBaseParser.NULLIF, SqlBaseParser.NULLS, SqlBaseParser.ONLY, SqlBaseParser.OPTION, SqlBaseParser.ORDINALITY, SqlBaseParser.OUTPUT, SqlBaseParser.OVER, SqlBaseParser.PARTITION, SqlBaseParser.PARTITIONS, SqlBaseParser.POSITION, SqlBaseParser.PRECEDING, SqlBaseParser.PRIVILEGES, SqlBaseParser.PROPERTIES, SqlBaseParser.PUBLIC, SqlBaseParser.RANGE, SqlBaseParser.READ, SqlBaseParser.RENAME, SqlBaseParser.REPEATABLE, SqlBaseParser.REPLACE, SqlBaseParser.RESET, SqlBaseParser.RESTRICT, SqlBaseParser.REVOKE, SqlBaseParser.ROLLBACK, SqlBaseParser.ROW, SqlBaseParser.ROWS, SqlBaseParser.SCHEMA, SqlBaseParser.SCHEMAS, SqlBaseParser.SECOND, SqlBaseParser.SERIALIZABLE, SqlBaseParser.SESSION, SqlBaseParser.SET, SqlBaseParser.SETS, SqlBaseParser.SHOW, SqlBaseParser.SMALLINT, SqlBaseParser.SOME, SqlBaseParser.START, SqlBaseParser.STATS, SqlBaseParser.SUBSTRING, SqlBaseParser.SYSTEM, SqlBaseParser.TABLES, SqlBaseParser.TABLESAMPLE, SqlBaseParser.TEXT, SqlBaseParser.TIME, SqlBaseParser.TIMESTAMP, SqlBaseParser.TINYINT, SqlBaseParser.TO, SqlBaseParser.TRANSACTION, SqlBaseParser.TRY_CAST, SqlBaseParser.TYPE, SqlBaseParser.UNBOUNDED, SqlBaseParser.UNCOMMITTED, SqlBaseParser.USE, SqlBaseParser.VALIDATE, SqlBaseParser.VERBOSE, SqlBaseParser.VIEW, SqlBaseParser.WORK, SqlBaseParser.WRITE, SqlBaseParser.YEAR, SqlBaseParser.ZONE, SqlBaseParser.IDENTIFIER, SqlBaseParser.DIGIT_IDENTIFIER, SqlBaseParser.QUOTED_IDENTIFIER, SqlBaseParser.BACKQUOTED_IDENTIFIER, SqlBaseParser.TIME_WITH_TIME_ZONE, SqlBaseParser.TIMESTAMP_WITH_TIME_ZONE, SqlBaseParser.DOUBLE_PRECISION]:
                self.enterOuterAlt(localctx, 2)
                self.state = 1365
                self.type(0)
                pass
            else:
                raise NoViableAltException(self)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class BaseTypeContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.BaseTypeContext, self).__init__(parent, invokingState)
            self.parser = parser

        def TIME_WITH_TIME_ZONE(self):
            return self.getToken(SqlBaseParser.TIME_WITH_TIME_ZONE, 0)

        def TIMESTAMP_WITH_TIME_ZONE(self):
            return self.getToken(SqlBaseParser.TIMESTAMP_WITH_TIME_ZONE, 0)

        def DOUBLE_PRECISION(self):
            return self.getToken(SqlBaseParser.DOUBLE_PRECISION, 0)

        def identifier(self):
            return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,0)


        def getRuleIndex(self):
            return SqlBaseParser.RULE_baseType

        def enterRule(self, listener):
            if hasattr(listener, "enterBaseType"):
                listener.enterBaseType(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitBaseType"):
                listener.exitBaseType(self)




    def baseType(self):

        localctx = SqlBaseParser.BaseTypeContext(self, self._ctx, self.state)
        self.enterRule(localctx, 92, self.RULE_baseType)
        try:
            self.state = 1372
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [SqlBaseParser.TIME_WITH_TIME_ZONE]:
                self.enterOuterAlt(localctx, 1)
                self.state = 1368
                self.match(SqlBaseParser.TIME_WITH_TIME_ZONE)
                pass
            elif token in [SqlBaseParser.TIMESTAMP_WITH_TIME_ZONE]:
                self.enterOuterAlt(localctx, 2)
                self.state = 1369
                self.match(SqlBaseParser.TIMESTAMP_WITH_TIME_ZONE)
                pass
            elif token in [SqlBaseParser.DOUBLE_PRECISION]:
                self.enterOuterAlt(localctx, 3)
                self.state = 1370
                self.match(SqlBaseParser.DOUBLE_PRECISION)
                pass
            elif token in [SqlBaseParser.ADD, SqlBaseParser.ALL, SqlBaseParser.ANALYZE, SqlBaseParser.ANY, SqlBaseParser.ARRAY, SqlBaseParser.ASC, SqlBaseParser.AT, SqlBaseParser.BERNOULLI, SqlBaseParser.CALL, SqlBaseParser.CASCADE, SqlBaseParser.CATALOGS, SqlBaseParser.COALESCE, SqlBaseParser.COLUMN, SqlBaseParser.COLUMNS, SqlBaseParser.COMMENT, SqlBaseParser.COMMIT, SqlBaseParser.COMMITTED, SqlBaseParser.CURRENT, SqlBaseParser.DATA, SqlBaseParser.DATE, SqlBaseParser.DAY, SqlBaseParser.DESC, SqlBaseParser.DISTRIBUTED, SqlBaseParser.EXCLUDING, SqlBaseParser.EXPLAIN, SqlBaseParser.FILTER, SqlBaseParser.FIRST, SqlBaseParser.FOLLOWING, SqlBaseParser.FORMAT, SqlBaseParser.FUNCTIONS, SqlBaseParser.GRANT, SqlBaseParser.GRANTS, SqlBaseParser.GRAPHVIZ, SqlBaseParser.HOUR, SqlBaseParser.IF, SqlBaseParser.INCLUDING, SqlBaseParser.INPUT, SqlBaseParser.INTEGER, SqlBaseParser.INTERVAL, SqlBaseParser.ISOLATION, SqlBaseParser.LAST, SqlBaseParser.LATERAL, SqlBaseParser.LEVEL, SqlBaseParser.LIMIT, SqlBaseParser.LOGICAL, SqlBaseParser.MAP, SqlBaseParser.MINUTE, SqlBaseParser.MONTH, SqlBaseParser.NFC, SqlBaseParser.NFD, SqlBaseParser.NFKC, SqlBaseParser.NFKD, SqlBaseParser.NO, SqlBaseParser.NULLIF, SqlBaseParser.NULLS, SqlBaseParser.ONLY, SqlBaseParser.OPTION, SqlBaseParser.ORDINALITY, SqlBaseParser.OUTPUT, SqlBaseParser.OVER, SqlBaseParser.PARTITION, SqlBaseParser.PARTITIONS, SqlBaseParser.POSITION, SqlBaseParser.PRECEDING, SqlBaseParser.PRIVILEGES, SqlBaseParser.PROPERTIES, SqlBaseParser.PUBLIC, SqlBaseParser.RANGE, SqlBaseParser.READ, SqlBaseParser.RENAME, SqlBaseParser.REPEATABLE, SqlBaseParser.REPLACE, SqlBaseParser.RESET, SqlBaseParser.RESTRICT, SqlBaseParser.REVOKE, SqlBaseParser.ROLLBACK, SqlBaseParser.ROW, SqlBaseParser.ROWS, SqlBaseParser.SCHEMA, SqlBaseParser.SCHEMAS, SqlBaseParser.SECOND, SqlBaseParser.SERIALIZABLE, SqlBaseParser.SESSION, SqlBaseParser.SET, SqlBaseParser.SETS, SqlBaseParser.SHOW, SqlBaseParser.SMALLINT, SqlBaseParser.SOME, SqlBaseParser.START, SqlBaseParser.STATS, SqlBaseParser.SUBSTRING, SqlBaseParser.SYSTEM, SqlBaseParser.TABLES, SqlBaseParser.TABLESAMPLE, SqlBaseParser.TEXT, SqlBaseParser.TIME, SqlBaseParser.TIMESTAMP, SqlBaseParser.TINYINT, SqlBaseParser.TO, SqlBaseParser.TRANSACTION, SqlBaseParser.TRY_CAST, SqlBaseParser.TYPE, SqlBaseParser.UNBOUNDED, SqlBaseParser.UNCOMMITTED, SqlBaseParser.USE, SqlBaseParser.VALIDATE, SqlBaseParser.VERBOSE, SqlBaseParser.VIEW, SqlBaseParser.WORK, SqlBaseParser.WRITE, SqlBaseParser.YEAR, SqlBaseParser.ZONE, SqlBaseParser.IDENTIFIER, SqlBaseParser.DIGIT_IDENTIFIER, SqlBaseParser.QUOTED_IDENTIFIER, SqlBaseParser.BACKQUOTED_IDENTIFIER]:
                self.enterOuterAlt(localctx, 4)
                self.state = 1371
                self.identifier()
                pass
            else:
                raise NoViableAltException(self)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class WhenClauseContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.WhenClauseContext, self).__init__(parent, invokingState)
            self.parser = parser
            self.condition = None # ExpressionContext
            self.result = None # ExpressionContext

        def WHEN(self):
            return self.getToken(SqlBaseParser.WHEN, 0)

        def THEN(self):
            return self.getToken(SqlBaseParser.THEN, 0)

        def expression(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.ExpressionContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.ExpressionContext,i)


        def getRuleIndex(self):
            return SqlBaseParser.RULE_whenClause

        def enterRule(self, listener):
            if hasattr(listener, "enterWhenClause"):
                listener.enterWhenClause(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitWhenClause"):
                listener.exitWhenClause(self)




    def whenClause(self):

        localctx = SqlBaseParser.WhenClauseContext(self, self._ctx, self.state)
        self.enterRule(localctx, 94, self.RULE_whenClause)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 1374
            self.match(SqlBaseParser.WHEN)
            self.state = 1375
            localctx.condition = self.expression()
            self.state = 1376
            self.match(SqlBaseParser.THEN)
            self.state = 1377
            localctx.result = self.expression()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class FilterContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.FilterContext, self).__init__(parent, invokingState)
            self.parser = parser

        def FILTER(self):
            return self.getToken(SqlBaseParser.FILTER, 0)

        def WHERE(self):
            return self.getToken(SqlBaseParser.WHERE, 0)

        def booleanExpression(self):
            return self.getTypedRuleContext(SqlBaseParser.BooleanExpressionContext,0)


        def getRuleIndex(self):
            return SqlBaseParser.RULE_filter

        def enterRule(self, listener):
            if hasattr(listener, "enterFilter"):
                listener.enterFilter(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitFilter"):
                listener.exitFilter(self)




    def filter(self):

        localctx = SqlBaseParser.FilterContext(self, self._ctx, self.state)
        self.enterRule(localctx, 96, self.RULE_filter)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 1379
            self.match(SqlBaseParser.FILTER)
            self.state = 1380
            self.match(SqlBaseParser.T__1)
            self.state = 1381
            self.match(SqlBaseParser.WHERE)
            self.state = 1382
            self.booleanExpression(0)
            self.state = 1383
            self.match(SqlBaseParser.T__2)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class OverContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.OverContext, self).__init__(parent, invokingState)
            self.parser = parser
            self._expression = None # ExpressionContext
            self.partition = list() # of ExpressionContexts

        def OVER(self):
            return self.getToken(SqlBaseParser.OVER, 0)

        def PARTITION(self):
            return self.getToken(SqlBaseParser.PARTITION, 0)

        def BY(self, i=None):
            if i is None:
                return self.getTokens(SqlBaseParser.BY)
            else:
                return self.getToken(SqlBaseParser.BY, i)

        def ORDER(self):
            return self.getToken(SqlBaseParser.ORDER, 0)

        def sortItem(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.SortItemContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.SortItemContext,i)


        def windowFrame(self):
            return self.getTypedRuleContext(SqlBaseParser.WindowFrameContext,0)


        def expression(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.ExpressionContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.ExpressionContext,i)


        def getRuleIndex(self):
            return SqlBaseParser.RULE_over

        def enterRule(self, listener):
            if hasattr(listener, "enterOver"):
                listener.enterOver(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitOver"):
                listener.exitOver(self)




    def over(self):

        localctx = SqlBaseParser.OverContext(self, self._ctx, self.state)
        self.enterRule(localctx, 98, self.RULE_over)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 1385
            self.match(SqlBaseParser.OVER)
            self.state = 1386
            self.match(SqlBaseParser.T__1)
            self.state = 1397
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==SqlBaseParser.PARTITION:
                self.state = 1387
                self.match(SqlBaseParser.PARTITION)
                self.state = 1388
                self.match(SqlBaseParser.BY)
                self.state = 1389
                localctx._expression = self.expression()
                localctx.partition.append(localctx._expression)
                self.state = 1394
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                while _la==SqlBaseParser.T__3:
                    self.state = 1390
                    self.match(SqlBaseParser.T__3)
                    self.state = 1391
                    localctx._expression = self.expression()
                    localctx.partition.append(localctx._expression)
                    self.state = 1396
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)



            self.state = 1409
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==SqlBaseParser.ORDER:
                self.state = 1399
                self.match(SqlBaseParser.ORDER)
                self.state = 1400
                self.match(SqlBaseParser.BY)
                self.state = 1401
                self.sortItem()
                self.state = 1406
                self._errHandler.sync(self)
                _la = self._input.LA(1)
                while _la==SqlBaseParser.T__3:
                    self.state = 1402
                    self.match(SqlBaseParser.T__3)
                    self.state = 1403
                    self.sortItem()
                    self.state = 1408
                    self._errHandler.sync(self)
                    _la = self._input.LA(1)



            self.state = 1412
            self._errHandler.sync(self)
            _la = self._input.LA(1)
            if _la==SqlBaseParser.RANGE or _la==SqlBaseParser.ROWS:
                self.state = 1411
                self.windowFrame()


            self.state = 1414
            self.match(SqlBaseParser.T__2)
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class WindowFrameContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.WindowFrameContext, self).__init__(parent, invokingState)
            self.parser = parser
            self.frameType = None # Token
            self.start = None # FrameBoundContext
            self.end = None # FrameBoundContext

        def RANGE(self):
            return self.getToken(SqlBaseParser.RANGE, 0)

        def frameBound(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.FrameBoundContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.FrameBoundContext,i)


        def ROWS(self):
            return self.getToken(SqlBaseParser.ROWS, 0)

        def BETWEEN(self):
            return self.getToken(SqlBaseParser.BETWEEN, 0)

        def AND(self):
            return self.getToken(SqlBaseParser.AND, 0)

        def getRuleIndex(self):
            return SqlBaseParser.RULE_windowFrame

        def enterRule(self, listener):
            if hasattr(listener, "enterWindowFrame"):
                listener.enterWindowFrame(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitWindowFrame"):
                listener.exitWindowFrame(self)




    def windowFrame(self):

        localctx = SqlBaseParser.WindowFrameContext(self, self._ctx, self.state)
        self.enterRule(localctx, 100, self.RULE_windowFrame)
        try:
            self.state = 1432
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,177,self._ctx)
            if la_ == 1:
                self.enterOuterAlt(localctx, 1)
                self.state = 1416
                localctx.frameType = self.match(SqlBaseParser.RANGE)
                self.state = 1417
                localctx.start = self.frameBound()
                pass

            elif la_ == 2:
                self.enterOuterAlt(localctx, 2)
                self.state = 1418
                localctx.frameType = self.match(SqlBaseParser.ROWS)
                self.state = 1419
                localctx.start = self.frameBound()
                pass

            elif la_ == 3:
                self.enterOuterAlt(localctx, 3)
                self.state = 1420
                localctx.frameType = self.match(SqlBaseParser.RANGE)
                self.state = 1421
                self.match(SqlBaseParser.BETWEEN)
                self.state = 1422
                localctx.start = self.frameBound()
                self.state = 1423
                self.match(SqlBaseParser.AND)
                self.state = 1424
                localctx.end = self.frameBound()
                pass

            elif la_ == 4:
                self.enterOuterAlt(localctx, 4)
                self.state = 1426
                localctx.frameType = self.match(SqlBaseParser.ROWS)
                self.state = 1427
                self.match(SqlBaseParser.BETWEEN)
                self.state = 1428
                localctx.start = self.frameBound()
                self.state = 1429
                self.match(SqlBaseParser.AND)
                self.state = 1430
                localctx.end = self.frameBound()
                pass


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class FrameBoundContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.FrameBoundContext, self).__init__(parent, invokingState)
            self.parser = parser


        def getRuleIndex(self):
            return SqlBaseParser.RULE_frameBound

     
        def copyFrom(self, ctx):
            super(SqlBaseParser.FrameBoundContext, self).copyFrom(ctx)



    class BoundedFrameContext(FrameBoundContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.FrameBoundContext)
            super(SqlBaseParser.BoundedFrameContext, self).__init__(parser)
            self.boundType = None # Token
            self.copyFrom(ctx)

        def expression(self):
            return self.getTypedRuleContext(SqlBaseParser.ExpressionContext,0)

        def PRECEDING(self):
            return self.getToken(SqlBaseParser.PRECEDING, 0)
        def FOLLOWING(self):
            return self.getToken(SqlBaseParser.FOLLOWING, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterBoundedFrame"):
                listener.enterBoundedFrame(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitBoundedFrame"):
                listener.exitBoundedFrame(self)


    class UnboundedFrameContext(FrameBoundContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.FrameBoundContext)
            super(SqlBaseParser.UnboundedFrameContext, self).__init__(parser)
            self.boundType = None # Token
            self.copyFrom(ctx)

        def UNBOUNDED(self):
            return self.getToken(SqlBaseParser.UNBOUNDED, 0)
        def PRECEDING(self):
            return self.getToken(SqlBaseParser.PRECEDING, 0)
        def FOLLOWING(self):
            return self.getToken(SqlBaseParser.FOLLOWING, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterUnboundedFrame"):
                listener.enterUnboundedFrame(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitUnboundedFrame"):
                listener.exitUnboundedFrame(self)


    class CurrentRowBoundContext(FrameBoundContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.FrameBoundContext)
            super(SqlBaseParser.CurrentRowBoundContext, self).__init__(parser)
            self.copyFrom(ctx)

        def CURRENT(self):
            return self.getToken(SqlBaseParser.CURRENT, 0)
        def ROW(self):
            return self.getToken(SqlBaseParser.ROW, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterCurrentRowBound"):
                listener.enterCurrentRowBound(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitCurrentRowBound"):
                listener.exitCurrentRowBound(self)



    def frameBound(self):

        localctx = SqlBaseParser.FrameBoundContext(self, self._ctx, self.state)
        self.enterRule(localctx, 102, self.RULE_frameBound)
        self._la = 0 # Token type
        try:
            self.state = 1443
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,178,self._ctx)
            if la_ == 1:
                localctx = SqlBaseParser.UnboundedFrameContext(self, localctx)
                self.enterOuterAlt(localctx, 1)
                self.state = 1434
                self.match(SqlBaseParser.UNBOUNDED)
                self.state = 1435
                localctx.boundType = self.match(SqlBaseParser.PRECEDING)
                pass

            elif la_ == 2:
                localctx = SqlBaseParser.UnboundedFrameContext(self, localctx)
                self.enterOuterAlt(localctx, 2)
                self.state = 1436
                self.match(SqlBaseParser.UNBOUNDED)
                self.state = 1437
                localctx.boundType = self.match(SqlBaseParser.FOLLOWING)
                pass

            elif la_ == 3:
                localctx = SqlBaseParser.CurrentRowBoundContext(self, localctx)
                self.enterOuterAlt(localctx, 3)
                self.state = 1438
                self.match(SqlBaseParser.CURRENT)
                self.state = 1439
                self.match(SqlBaseParser.ROW)
                pass

            elif la_ == 4:
                localctx = SqlBaseParser.BoundedFrameContext(self, localctx)
                self.enterOuterAlt(localctx, 4)
                self.state = 1440
                self.expression()
                self.state = 1441
                localctx.boundType = self._input.LT(1)
                _la = self._input.LA(1)
                if not(_la==SqlBaseParser.FOLLOWING or _la==SqlBaseParser.PRECEDING):
                    localctx.boundType = self._errHandler.recoverInline(self)
                else:
                    self._errHandler.reportMatch(self)
                    self.consume()
                pass


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class ExplainOptionContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.ExplainOptionContext, self).__init__(parent, invokingState)
            self.parser = parser


        def getRuleIndex(self):
            return SqlBaseParser.RULE_explainOption

     
        def copyFrom(self, ctx):
            super(SqlBaseParser.ExplainOptionContext, self).copyFrom(ctx)



    class ExplainFormatContext(ExplainOptionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.ExplainOptionContext)
            super(SqlBaseParser.ExplainFormatContext, self).__init__(parser)
            self.value = None # Token
            self.copyFrom(ctx)

        def FORMAT(self):
            return self.getToken(SqlBaseParser.FORMAT, 0)
        def TEXT(self):
            return self.getToken(SqlBaseParser.TEXT, 0)
        def GRAPHVIZ(self):
            return self.getToken(SqlBaseParser.GRAPHVIZ, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterExplainFormat"):
                listener.enterExplainFormat(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitExplainFormat"):
                listener.exitExplainFormat(self)


    class ExplainTypeContext(ExplainOptionContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.ExplainOptionContext)
            super(SqlBaseParser.ExplainTypeContext, self).__init__(parser)
            self.value = None # Token
            self.copyFrom(ctx)

        def TYPE(self):
            return self.getToken(SqlBaseParser.TYPE, 0)
        def LOGICAL(self):
            return self.getToken(SqlBaseParser.LOGICAL, 0)
        def DISTRIBUTED(self):
            return self.getToken(SqlBaseParser.DISTRIBUTED, 0)
        def VALIDATE(self):
            return self.getToken(SqlBaseParser.VALIDATE, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterExplainType"):
                listener.enterExplainType(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitExplainType"):
                listener.exitExplainType(self)



    def explainOption(self):

        localctx = SqlBaseParser.ExplainOptionContext(self, self._ctx, self.state)
        self.enterRule(localctx, 104, self.RULE_explainOption)
        self._la = 0 # Token type
        try:
            self.state = 1449
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [SqlBaseParser.FORMAT]:
                localctx = SqlBaseParser.ExplainFormatContext(self, localctx)
                self.enterOuterAlt(localctx, 1)
                self.state = 1445
                self.match(SqlBaseParser.FORMAT)
                self.state = 1446
                localctx.value = self._input.LT(1)
                _la = self._input.LA(1)
                if not(_la==SqlBaseParser.GRAPHVIZ or _la==SqlBaseParser.TEXT):
                    localctx.value = self._errHandler.recoverInline(self)
                else:
                    self._errHandler.reportMatch(self)
                    self.consume()
                pass
            elif token in [SqlBaseParser.TYPE]:
                localctx = SqlBaseParser.ExplainTypeContext(self, localctx)
                self.enterOuterAlt(localctx, 2)
                self.state = 1447
                self.match(SqlBaseParser.TYPE)
                self.state = 1448
                localctx.value = self._input.LT(1)
                _la = self._input.LA(1)
                if not(_la==SqlBaseParser.DISTRIBUTED or _la==SqlBaseParser.LOGICAL or _la==SqlBaseParser.VALIDATE):
                    localctx.value = self._errHandler.recoverInline(self)
                else:
                    self._errHandler.reportMatch(self)
                    self.consume()
                pass
            else:
                raise NoViableAltException(self)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class TransactionModeContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.TransactionModeContext, self).__init__(parent, invokingState)
            self.parser = parser


        def getRuleIndex(self):
            return SqlBaseParser.RULE_transactionMode

     
        def copyFrom(self, ctx):
            super(SqlBaseParser.TransactionModeContext, self).copyFrom(ctx)



    class TransactionAccessModeContext(TransactionModeContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.TransactionModeContext)
            super(SqlBaseParser.TransactionAccessModeContext, self).__init__(parser)
            self.accessMode = None # Token
            self.copyFrom(ctx)

        def READ(self):
            return self.getToken(SqlBaseParser.READ, 0)
        def ONLY(self):
            return self.getToken(SqlBaseParser.ONLY, 0)
        def WRITE(self):
            return self.getToken(SqlBaseParser.WRITE, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterTransactionAccessMode"):
                listener.enterTransactionAccessMode(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitTransactionAccessMode"):
                listener.exitTransactionAccessMode(self)


    class IsolationLevelContext(TransactionModeContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.TransactionModeContext)
            super(SqlBaseParser.IsolationLevelContext, self).__init__(parser)
            self.copyFrom(ctx)

        def ISOLATION(self):
            return self.getToken(SqlBaseParser.ISOLATION, 0)
        def LEVEL(self):
            return self.getToken(SqlBaseParser.LEVEL, 0)
        def levelOfIsolation(self):
            return self.getTypedRuleContext(SqlBaseParser.LevelOfIsolationContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterIsolationLevel"):
                listener.enterIsolationLevel(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitIsolationLevel"):
                listener.exitIsolationLevel(self)



    def transactionMode(self):

        localctx = SqlBaseParser.TransactionModeContext(self, self._ctx, self.state)
        self.enterRule(localctx, 106, self.RULE_transactionMode)
        self._la = 0 # Token type
        try:
            self.state = 1456
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [SqlBaseParser.ISOLATION]:
                localctx = SqlBaseParser.IsolationLevelContext(self, localctx)
                self.enterOuterAlt(localctx, 1)
                self.state = 1451
                self.match(SqlBaseParser.ISOLATION)
                self.state = 1452
                self.match(SqlBaseParser.LEVEL)
                self.state = 1453
                self.levelOfIsolation()
                pass
            elif token in [SqlBaseParser.READ]:
                localctx = SqlBaseParser.TransactionAccessModeContext(self, localctx)
                self.enterOuterAlt(localctx, 2)
                self.state = 1454
                self.match(SqlBaseParser.READ)
                self.state = 1455
                localctx.accessMode = self._input.LT(1)
                _la = self._input.LA(1)
                if not(_la==SqlBaseParser.ONLY or _la==SqlBaseParser.WRITE):
                    localctx.accessMode = self._errHandler.recoverInline(self)
                else:
                    self._errHandler.reportMatch(self)
                    self.consume()
                pass
            else:
                raise NoViableAltException(self)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class LevelOfIsolationContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.LevelOfIsolationContext, self).__init__(parent, invokingState)
            self.parser = parser


        def getRuleIndex(self):
            return SqlBaseParser.RULE_levelOfIsolation

     
        def copyFrom(self, ctx):
            super(SqlBaseParser.LevelOfIsolationContext, self).copyFrom(ctx)



    class ReadUncommittedContext(LevelOfIsolationContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.LevelOfIsolationContext)
            super(SqlBaseParser.ReadUncommittedContext, self).__init__(parser)
            self.copyFrom(ctx)

        def READ(self):
            return self.getToken(SqlBaseParser.READ, 0)
        def UNCOMMITTED(self):
            return self.getToken(SqlBaseParser.UNCOMMITTED, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterReadUncommitted"):
                listener.enterReadUncommitted(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitReadUncommitted"):
                listener.exitReadUncommitted(self)


    class SerializableContext(LevelOfIsolationContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.LevelOfIsolationContext)
            super(SqlBaseParser.SerializableContext, self).__init__(parser)
            self.copyFrom(ctx)

        def SERIALIZABLE(self):
            return self.getToken(SqlBaseParser.SERIALIZABLE, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterSerializable"):
                listener.enterSerializable(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitSerializable"):
                listener.exitSerializable(self)


    class ReadCommittedContext(LevelOfIsolationContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.LevelOfIsolationContext)
            super(SqlBaseParser.ReadCommittedContext, self).__init__(parser)
            self.copyFrom(ctx)

        def READ(self):
            return self.getToken(SqlBaseParser.READ, 0)
        def COMMITTED(self):
            return self.getToken(SqlBaseParser.COMMITTED, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterReadCommitted"):
                listener.enterReadCommitted(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitReadCommitted"):
                listener.exitReadCommitted(self)


    class RepeatableReadContext(LevelOfIsolationContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.LevelOfIsolationContext)
            super(SqlBaseParser.RepeatableReadContext, self).__init__(parser)
            self.copyFrom(ctx)

        def REPEATABLE(self):
            return self.getToken(SqlBaseParser.REPEATABLE, 0)
        def READ(self):
            return self.getToken(SqlBaseParser.READ, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterRepeatableRead"):
                listener.enterRepeatableRead(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitRepeatableRead"):
                listener.exitRepeatableRead(self)



    def levelOfIsolation(self):

        localctx = SqlBaseParser.LevelOfIsolationContext(self, self._ctx, self.state)
        self.enterRule(localctx, 108, self.RULE_levelOfIsolation)
        try:
            self.state = 1465
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,181,self._ctx)
            if la_ == 1:
                localctx = SqlBaseParser.ReadUncommittedContext(self, localctx)
                self.enterOuterAlt(localctx, 1)
                self.state = 1458
                self.match(SqlBaseParser.READ)
                self.state = 1459
                self.match(SqlBaseParser.UNCOMMITTED)
                pass

            elif la_ == 2:
                localctx = SqlBaseParser.ReadCommittedContext(self, localctx)
                self.enterOuterAlt(localctx, 2)
                self.state = 1460
                self.match(SqlBaseParser.READ)
                self.state = 1461
                self.match(SqlBaseParser.COMMITTED)
                pass

            elif la_ == 3:
                localctx = SqlBaseParser.RepeatableReadContext(self, localctx)
                self.enterOuterAlt(localctx, 3)
                self.state = 1462
                self.match(SqlBaseParser.REPEATABLE)
                self.state = 1463
                self.match(SqlBaseParser.READ)
                pass

            elif la_ == 4:
                localctx = SqlBaseParser.SerializableContext(self, localctx)
                self.enterOuterAlt(localctx, 4)
                self.state = 1464
                self.match(SqlBaseParser.SERIALIZABLE)
                pass


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class CallArgumentContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.CallArgumentContext, self).__init__(parent, invokingState)
            self.parser = parser


        def getRuleIndex(self):
            return SqlBaseParser.RULE_callArgument

     
        def copyFrom(self, ctx):
            super(SqlBaseParser.CallArgumentContext, self).copyFrom(ctx)



    class PositionalArgumentContext(CallArgumentContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.CallArgumentContext)
            super(SqlBaseParser.PositionalArgumentContext, self).__init__(parser)
            self.copyFrom(ctx)

        def expression(self):
            return self.getTypedRuleContext(SqlBaseParser.ExpressionContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterPositionalArgument"):
                listener.enterPositionalArgument(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitPositionalArgument"):
                listener.exitPositionalArgument(self)


    class NamedArgumentContext(CallArgumentContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.CallArgumentContext)
            super(SqlBaseParser.NamedArgumentContext, self).__init__(parser)
            self.copyFrom(ctx)

        def identifier(self):
            return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,0)

        def expression(self):
            return self.getTypedRuleContext(SqlBaseParser.ExpressionContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterNamedArgument"):
                listener.enterNamedArgument(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitNamedArgument"):
                listener.exitNamedArgument(self)



    def callArgument(self):

        localctx = SqlBaseParser.CallArgumentContext(self, self._ctx, self.state)
        self.enterRule(localctx, 110, self.RULE_callArgument)
        try:
            self.state = 1472
            self._errHandler.sync(self)
            la_ = self._interp.adaptivePredict(self._input,182,self._ctx)
            if la_ == 1:
                localctx = SqlBaseParser.PositionalArgumentContext(self, localctx)
                self.enterOuterAlt(localctx, 1)
                self.state = 1467
                self.expression()
                pass

            elif la_ == 2:
                localctx = SqlBaseParser.NamedArgumentContext(self, localctx)
                self.enterOuterAlt(localctx, 2)
                self.state = 1468
                self.identifier()
                self.state = 1469
                self.match(SqlBaseParser.T__8)
                self.state = 1470
                self.expression()
                pass


        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class PrivilegeContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.PrivilegeContext, self).__init__(parent, invokingState)
            self.parser = parser

        def SELECT(self):
            return self.getToken(SqlBaseParser.SELECT, 0)

        def DELETE(self):
            return self.getToken(SqlBaseParser.DELETE, 0)

        def INSERT(self):
            return self.getToken(SqlBaseParser.INSERT, 0)

        def identifier(self):
            return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,0)


        def getRuleIndex(self):
            return SqlBaseParser.RULE_privilege

        def enterRule(self, listener):
            if hasattr(listener, "enterPrivilege"):
                listener.enterPrivilege(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitPrivilege"):
                listener.exitPrivilege(self)




    def privilege(self):

        localctx = SqlBaseParser.PrivilegeContext(self, self._ctx, self.state)
        self.enterRule(localctx, 112, self.RULE_privilege)
        try:
            self.state = 1478
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [SqlBaseParser.SELECT]:
                self.enterOuterAlt(localctx, 1)
                self.state = 1474
                self.match(SqlBaseParser.SELECT)
                pass
            elif token in [SqlBaseParser.DELETE]:
                self.enterOuterAlt(localctx, 2)
                self.state = 1475
                self.match(SqlBaseParser.DELETE)
                pass
            elif token in [SqlBaseParser.INSERT]:
                self.enterOuterAlt(localctx, 3)
                self.state = 1476
                self.match(SqlBaseParser.INSERT)
                pass
            elif token in [SqlBaseParser.ADD, SqlBaseParser.ALL, SqlBaseParser.ANALYZE, SqlBaseParser.ANY, SqlBaseParser.ARRAY, SqlBaseParser.ASC, SqlBaseParser.AT, SqlBaseParser.BERNOULLI, SqlBaseParser.CALL, SqlBaseParser.CASCADE, SqlBaseParser.CATALOGS, SqlBaseParser.COALESCE, SqlBaseParser.COLUMN, SqlBaseParser.COLUMNS, SqlBaseParser.COMMENT, SqlBaseParser.COMMIT, SqlBaseParser.COMMITTED, SqlBaseParser.CURRENT, SqlBaseParser.DATA, SqlBaseParser.DATE, SqlBaseParser.DAY, SqlBaseParser.DESC, SqlBaseParser.DISTRIBUTED, SqlBaseParser.EXCLUDING, SqlBaseParser.EXPLAIN, SqlBaseParser.FILTER, SqlBaseParser.FIRST, SqlBaseParser.FOLLOWING, SqlBaseParser.FORMAT, SqlBaseParser.FUNCTIONS, SqlBaseParser.GRANT, SqlBaseParser.GRANTS, SqlBaseParser.GRAPHVIZ, SqlBaseParser.HOUR, SqlBaseParser.IF, SqlBaseParser.INCLUDING, SqlBaseParser.INPUT, SqlBaseParser.INTEGER, SqlBaseParser.INTERVAL, SqlBaseParser.ISOLATION, SqlBaseParser.LAST, SqlBaseParser.LATERAL, SqlBaseParser.LEVEL, SqlBaseParser.LIMIT, SqlBaseParser.LOGICAL, SqlBaseParser.MAP, SqlBaseParser.MINUTE, SqlBaseParser.MONTH, SqlBaseParser.NFC, SqlBaseParser.NFD, SqlBaseParser.NFKC, SqlBaseParser.NFKD, SqlBaseParser.NO, SqlBaseParser.NULLIF, SqlBaseParser.NULLS, SqlBaseParser.ONLY, SqlBaseParser.OPTION, SqlBaseParser.ORDINALITY, SqlBaseParser.OUTPUT, SqlBaseParser.OVER, SqlBaseParser.PARTITION, SqlBaseParser.PARTITIONS, SqlBaseParser.POSITION, SqlBaseParser.PRECEDING, SqlBaseParser.PRIVILEGES, SqlBaseParser.PROPERTIES, SqlBaseParser.PUBLIC, SqlBaseParser.RANGE, SqlBaseParser.READ, SqlBaseParser.RENAME, SqlBaseParser.REPEATABLE, SqlBaseParser.REPLACE, SqlBaseParser.RESET, SqlBaseParser.RESTRICT, SqlBaseParser.REVOKE, SqlBaseParser.ROLLBACK, SqlBaseParser.ROW, SqlBaseParser.ROWS, SqlBaseParser.SCHEMA, SqlBaseParser.SCHEMAS, SqlBaseParser.SECOND, SqlBaseParser.SERIALIZABLE, SqlBaseParser.SESSION, SqlBaseParser.SET, SqlBaseParser.SETS, SqlBaseParser.SHOW, SqlBaseParser.SMALLINT, SqlBaseParser.SOME, SqlBaseParser.START, SqlBaseParser.STATS, SqlBaseParser.SUBSTRING, SqlBaseParser.SYSTEM, SqlBaseParser.TABLES, SqlBaseParser.TABLESAMPLE, SqlBaseParser.TEXT, SqlBaseParser.TIME, SqlBaseParser.TIMESTAMP, SqlBaseParser.TINYINT, SqlBaseParser.TO, SqlBaseParser.TRANSACTION, SqlBaseParser.TRY_CAST, SqlBaseParser.TYPE, SqlBaseParser.UNBOUNDED, SqlBaseParser.UNCOMMITTED, SqlBaseParser.USE, SqlBaseParser.VALIDATE, SqlBaseParser.VERBOSE, SqlBaseParser.VIEW, SqlBaseParser.WORK, SqlBaseParser.WRITE, SqlBaseParser.YEAR, SqlBaseParser.ZONE, SqlBaseParser.IDENTIFIER, SqlBaseParser.DIGIT_IDENTIFIER, SqlBaseParser.QUOTED_IDENTIFIER, SqlBaseParser.BACKQUOTED_IDENTIFIER]:
                self.enterOuterAlt(localctx, 4)
                self.state = 1477
                self.identifier()
                pass
            else:
                raise NoViableAltException(self)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class QualifiedNameContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.QualifiedNameContext, self).__init__(parent, invokingState)
            self.parser = parser

        def identifier(self, i=None):
            if i is None:
                return self.getTypedRuleContexts(SqlBaseParser.IdentifierContext)
            else:
                return self.getTypedRuleContext(SqlBaseParser.IdentifierContext,i)


        def getRuleIndex(self):
            return SqlBaseParser.RULE_qualifiedName

        def enterRule(self, listener):
            if hasattr(listener, "enterQualifiedName"):
                listener.enterQualifiedName(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitQualifiedName"):
                listener.exitQualifiedName(self)




    def qualifiedName(self):

        localctx = SqlBaseParser.QualifiedNameContext(self, self._ctx, self.state)
        self.enterRule(localctx, 114, self.RULE_qualifiedName)
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 1480
            self.identifier()
            self.state = 1485
            self._errHandler.sync(self)
            _alt = self._interp.adaptivePredict(self._input,184,self._ctx)
            while _alt!=2 and _alt!=ATN.INVALID_ALT_NUMBER:
                if _alt==1:
                    self.state = 1481
                    self.match(SqlBaseParser.T__0)
                    self.state = 1482
                    self.identifier() 
                self.state = 1487
                self._errHandler.sync(self)
                _alt = self._interp.adaptivePredict(self._input,184,self._ctx)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class IdentifierContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.IdentifierContext, self).__init__(parent, invokingState)
            self.parser = parser


        def getRuleIndex(self):
            return SqlBaseParser.RULE_identifier

     
        def copyFrom(self, ctx):
            super(SqlBaseParser.IdentifierContext, self).copyFrom(ctx)



    class BackQuotedIdentifierContext(IdentifierContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.IdentifierContext)
            super(SqlBaseParser.BackQuotedIdentifierContext, self).__init__(parser)
            self.copyFrom(ctx)

        def BACKQUOTED_IDENTIFIER(self):
            return self.getToken(SqlBaseParser.BACKQUOTED_IDENTIFIER, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterBackQuotedIdentifier"):
                listener.enterBackQuotedIdentifier(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitBackQuotedIdentifier"):
                listener.exitBackQuotedIdentifier(self)


    class QuotedIdentifierContext(IdentifierContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.IdentifierContext)
            super(SqlBaseParser.QuotedIdentifierContext, self).__init__(parser)
            self.copyFrom(ctx)

        def QUOTED_IDENTIFIER(self):
            return self.getToken(SqlBaseParser.QUOTED_IDENTIFIER, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterQuotedIdentifier"):
                listener.enterQuotedIdentifier(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitQuotedIdentifier"):
                listener.exitQuotedIdentifier(self)


    class DigitIdentifierContext(IdentifierContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.IdentifierContext)
            super(SqlBaseParser.DigitIdentifierContext, self).__init__(parser)
            self.copyFrom(ctx)

        def DIGIT_IDENTIFIER(self):
            return self.getToken(SqlBaseParser.DIGIT_IDENTIFIER, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterDigitIdentifier"):
                listener.enterDigitIdentifier(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitDigitIdentifier"):
                listener.exitDigitIdentifier(self)


    class UnquotedIdentifierContext(IdentifierContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.IdentifierContext)
            super(SqlBaseParser.UnquotedIdentifierContext, self).__init__(parser)
            self.copyFrom(ctx)

        def IDENTIFIER(self):
            return self.getToken(SqlBaseParser.IDENTIFIER, 0)
        def nonReserved(self):
            return self.getTypedRuleContext(SqlBaseParser.NonReservedContext,0)


        def enterRule(self, listener):
            if hasattr(listener, "enterUnquotedIdentifier"):
                listener.enterUnquotedIdentifier(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitUnquotedIdentifier"):
                listener.exitUnquotedIdentifier(self)



    def identifier(self):

        localctx = SqlBaseParser.IdentifierContext(self, self._ctx, self.state)
        self.enterRule(localctx, 116, self.RULE_identifier)
        try:
            self.state = 1493
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [SqlBaseParser.IDENTIFIER]:
                localctx = SqlBaseParser.UnquotedIdentifierContext(self, localctx)
                self.enterOuterAlt(localctx, 1)
                self.state = 1488
                self.match(SqlBaseParser.IDENTIFIER)
                pass
            elif token in [SqlBaseParser.QUOTED_IDENTIFIER]:
                localctx = SqlBaseParser.QuotedIdentifierContext(self, localctx)
                self.enterOuterAlt(localctx, 2)
                self.state = 1489
                self.match(SqlBaseParser.QUOTED_IDENTIFIER)
                pass
            elif token in [SqlBaseParser.ADD, SqlBaseParser.ALL, SqlBaseParser.ANALYZE, SqlBaseParser.ANY, SqlBaseParser.ARRAY, SqlBaseParser.ASC, SqlBaseParser.AT, SqlBaseParser.BERNOULLI, SqlBaseParser.CALL, SqlBaseParser.CASCADE, SqlBaseParser.CATALOGS, SqlBaseParser.COALESCE, SqlBaseParser.COLUMN, SqlBaseParser.COLUMNS, SqlBaseParser.COMMENT, SqlBaseParser.COMMIT, SqlBaseParser.COMMITTED, SqlBaseParser.CURRENT, SqlBaseParser.DATA, SqlBaseParser.DATE, SqlBaseParser.DAY, SqlBaseParser.DESC, SqlBaseParser.DISTRIBUTED, SqlBaseParser.EXCLUDING, SqlBaseParser.EXPLAIN, SqlBaseParser.FILTER, SqlBaseParser.FIRST, SqlBaseParser.FOLLOWING, SqlBaseParser.FORMAT, SqlBaseParser.FUNCTIONS, SqlBaseParser.GRANT, SqlBaseParser.GRANTS, SqlBaseParser.GRAPHVIZ, SqlBaseParser.HOUR, SqlBaseParser.IF, SqlBaseParser.INCLUDING, SqlBaseParser.INPUT, SqlBaseParser.INTEGER, SqlBaseParser.INTERVAL, SqlBaseParser.ISOLATION, SqlBaseParser.LAST, SqlBaseParser.LATERAL, SqlBaseParser.LEVEL, SqlBaseParser.LIMIT, SqlBaseParser.LOGICAL, SqlBaseParser.MAP, SqlBaseParser.MINUTE, SqlBaseParser.MONTH, SqlBaseParser.NFC, SqlBaseParser.NFD, SqlBaseParser.NFKC, SqlBaseParser.NFKD, SqlBaseParser.NO, SqlBaseParser.NULLIF, SqlBaseParser.NULLS, SqlBaseParser.ONLY, SqlBaseParser.OPTION, SqlBaseParser.ORDINALITY, SqlBaseParser.OUTPUT, SqlBaseParser.OVER, SqlBaseParser.PARTITION, SqlBaseParser.PARTITIONS, SqlBaseParser.POSITION, SqlBaseParser.PRECEDING, SqlBaseParser.PRIVILEGES, SqlBaseParser.PROPERTIES, SqlBaseParser.PUBLIC, SqlBaseParser.RANGE, SqlBaseParser.READ, SqlBaseParser.RENAME, SqlBaseParser.REPEATABLE, SqlBaseParser.REPLACE, SqlBaseParser.RESET, SqlBaseParser.RESTRICT, SqlBaseParser.REVOKE, SqlBaseParser.ROLLBACK, SqlBaseParser.ROW, SqlBaseParser.ROWS, SqlBaseParser.SCHEMA, SqlBaseParser.SCHEMAS, SqlBaseParser.SECOND, SqlBaseParser.SERIALIZABLE, SqlBaseParser.SESSION, SqlBaseParser.SET, SqlBaseParser.SETS, SqlBaseParser.SHOW, SqlBaseParser.SMALLINT, SqlBaseParser.SOME, SqlBaseParser.START, SqlBaseParser.STATS, SqlBaseParser.SUBSTRING, SqlBaseParser.SYSTEM, SqlBaseParser.TABLES, SqlBaseParser.TABLESAMPLE, SqlBaseParser.TEXT, SqlBaseParser.TIME, SqlBaseParser.TIMESTAMP, SqlBaseParser.TINYINT, SqlBaseParser.TO, SqlBaseParser.TRANSACTION, SqlBaseParser.TRY_CAST, SqlBaseParser.TYPE, SqlBaseParser.UNBOUNDED, SqlBaseParser.UNCOMMITTED, SqlBaseParser.USE, SqlBaseParser.VALIDATE, SqlBaseParser.VERBOSE, SqlBaseParser.VIEW, SqlBaseParser.WORK, SqlBaseParser.WRITE, SqlBaseParser.YEAR, SqlBaseParser.ZONE]:
                localctx = SqlBaseParser.UnquotedIdentifierContext(self, localctx)
                self.enterOuterAlt(localctx, 3)
                self.state = 1490
                self.nonReserved()
                pass
            elif token in [SqlBaseParser.BACKQUOTED_IDENTIFIER]:
                localctx = SqlBaseParser.BackQuotedIdentifierContext(self, localctx)
                self.enterOuterAlt(localctx, 4)
                self.state = 1491
                self.match(SqlBaseParser.BACKQUOTED_IDENTIFIER)
                pass
            elif token in [SqlBaseParser.DIGIT_IDENTIFIER]:
                localctx = SqlBaseParser.DigitIdentifierContext(self, localctx)
                self.enterOuterAlt(localctx, 5)
                self.state = 1492
                self.match(SqlBaseParser.DIGIT_IDENTIFIER)
                pass
            else:
                raise NoViableAltException(self)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class NumberContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.NumberContext, self).__init__(parent, invokingState)
            self.parser = parser


        def getRuleIndex(self):
            return SqlBaseParser.RULE_number

     
        def copyFrom(self, ctx):
            super(SqlBaseParser.NumberContext, self).copyFrom(ctx)



    class DecimalLiteralContext(NumberContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.NumberContext)
            super(SqlBaseParser.DecimalLiteralContext, self).__init__(parser)
            self.copyFrom(ctx)

        def DECIMAL_VALUE(self):
            return self.getToken(SqlBaseParser.DECIMAL_VALUE, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterDecimalLiteral"):
                listener.enterDecimalLiteral(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitDecimalLiteral"):
                listener.exitDecimalLiteral(self)


    class DoubleLiteralContext(NumberContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.NumberContext)
            super(SqlBaseParser.DoubleLiteralContext, self).__init__(parser)
            self.copyFrom(ctx)

        def DOUBLE_VALUE(self):
            return self.getToken(SqlBaseParser.DOUBLE_VALUE, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterDoubleLiteral"):
                listener.enterDoubleLiteral(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitDoubleLiteral"):
                listener.exitDoubleLiteral(self)


    class IntegerLiteralContext(NumberContext):

        def __init__(self, parser, ctx): # actually a SqlBaseParser.NumberContext)
            super(SqlBaseParser.IntegerLiteralContext, self).__init__(parser)
            self.copyFrom(ctx)

        def INTEGER_VALUE(self):
            return self.getToken(SqlBaseParser.INTEGER_VALUE, 0)

        def enterRule(self, listener):
            if hasattr(listener, "enterIntegerLiteral"):
                listener.enterIntegerLiteral(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitIntegerLiteral"):
                listener.exitIntegerLiteral(self)



    def number(self):

        localctx = SqlBaseParser.NumberContext(self, self._ctx, self.state)
        self.enterRule(localctx, 118, self.RULE_number)
        try:
            self.state = 1498
            self._errHandler.sync(self)
            token = self._input.LA(1)
            if token in [SqlBaseParser.DECIMAL_VALUE]:
                localctx = SqlBaseParser.DecimalLiteralContext(self, localctx)
                self.enterOuterAlt(localctx, 1)
                self.state = 1495
                self.match(SqlBaseParser.DECIMAL_VALUE)
                pass
            elif token in [SqlBaseParser.DOUBLE_VALUE]:
                localctx = SqlBaseParser.DoubleLiteralContext(self, localctx)
                self.enterOuterAlt(localctx, 2)
                self.state = 1496
                self.match(SqlBaseParser.DOUBLE_VALUE)
                pass
            elif token in [SqlBaseParser.INTEGER_VALUE]:
                localctx = SqlBaseParser.IntegerLiteralContext(self, localctx)
                self.enterOuterAlt(localctx, 3)
                self.state = 1497
                self.match(SqlBaseParser.INTEGER_VALUE)
                pass
            else:
                raise NoViableAltException(self)

        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx

    class NonReservedContext(ParserRuleContext):

        def __init__(self, parser, parent=None, invokingState=-1):
            super(SqlBaseParser.NonReservedContext, self).__init__(parent, invokingState)
            self.parser = parser

        def ADD(self):
            return self.getToken(SqlBaseParser.ADD, 0)

        def ALL(self):
            return self.getToken(SqlBaseParser.ALL, 0)

        def ANALYZE(self):
            return self.getToken(SqlBaseParser.ANALYZE, 0)

        def ANY(self):
            return self.getToken(SqlBaseParser.ANY, 0)

        def ARRAY(self):
            return self.getToken(SqlBaseParser.ARRAY, 0)

        def ASC(self):
            return self.getToken(SqlBaseParser.ASC, 0)

        def AT(self):
            return self.getToken(SqlBaseParser.AT, 0)

        def BERNOULLI(self):
            return self.getToken(SqlBaseParser.BERNOULLI, 0)

        def CALL(self):
            return self.getToken(SqlBaseParser.CALL, 0)

        def CASCADE(self):
            return self.getToken(SqlBaseParser.CASCADE, 0)

        def CATALOGS(self):
            return self.getToken(SqlBaseParser.CATALOGS, 0)

        def COALESCE(self):
            return self.getToken(SqlBaseParser.COALESCE, 0)

        def COLUMN(self):
            return self.getToken(SqlBaseParser.COLUMN, 0)

        def COLUMNS(self):
            return self.getToken(SqlBaseParser.COLUMNS, 0)

        def COMMENT(self):
            return self.getToken(SqlBaseParser.COMMENT, 0)

        def COMMIT(self):
            return self.getToken(SqlBaseParser.COMMIT, 0)

        def COMMITTED(self):
            return self.getToken(SqlBaseParser.COMMITTED, 0)

        def CURRENT(self):
            return self.getToken(SqlBaseParser.CURRENT, 0)

        def DATA(self):
            return self.getToken(SqlBaseParser.DATA, 0)

        def DATE(self):
            return self.getToken(SqlBaseParser.DATE, 0)

        def DAY(self):
            return self.getToken(SqlBaseParser.DAY, 0)

        def DESC(self):
            return self.getToken(SqlBaseParser.DESC, 0)

        def DISTRIBUTED(self):
            return self.getToken(SqlBaseParser.DISTRIBUTED, 0)

        def EXCLUDING(self):
            return self.getToken(SqlBaseParser.EXCLUDING, 0)

        def EXPLAIN(self):
            return self.getToken(SqlBaseParser.EXPLAIN, 0)

        def FILTER(self):
            return self.getToken(SqlBaseParser.FILTER, 0)

        def FIRST(self):
            return self.getToken(SqlBaseParser.FIRST, 0)

        def FOLLOWING(self):
            return self.getToken(SqlBaseParser.FOLLOWING, 0)

        def FORMAT(self):
            return self.getToken(SqlBaseParser.FORMAT, 0)

        def FUNCTIONS(self):
            return self.getToken(SqlBaseParser.FUNCTIONS, 0)

        def GRANT(self):
            return self.getToken(SqlBaseParser.GRANT, 0)

        def GRANTS(self):
            return self.getToken(SqlBaseParser.GRANTS, 0)

        def GRAPHVIZ(self):
            return self.getToken(SqlBaseParser.GRAPHVIZ, 0)

        def HOUR(self):
            return self.getToken(SqlBaseParser.HOUR, 0)

        def IF(self):
            return self.getToken(SqlBaseParser.IF, 0)

        def INCLUDING(self):
            return self.getToken(SqlBaseParser.INCLUDING, 0)

        def INPUT(self):
            return self.getToken(SqlBaseParser.INPUT, 0)

        def INTEGER(self):
            return self.getToken(SqlBaseParser.INTEGER, 0)

        def INTERVAL(self):
            return self.getToken(SqlBaseParser.INTERVAL, 0)

        def ISOLATION(self):
            return self.getToken(SqlBaseParser.ISOLATION, 0)

        def LAST(self):
            return self.getToken(SqlBaseParser.LAST, 0)

        def LATERAL(self):
            return self.getToken(SqlBaseParser.LATERAL, 0)

        def LEVEL(self):
            return self.getToken(SqlBaseParser.LEVEL, 0)

        def LIMIT(self):
            return self.getToken(SqlBaseParser.LIMIT, 0)

        def LOGICAL(self):
            return self.getToken(SqlBaseParser.LOGICAL, 0)

        def MAP(self):
            return self.getToken(SqlBaseParser.MAP, 0)

        def MINUTE(self):
            return self.getToken(SqlBaseParser.MINUTE, 0)

        def MONTH(self):
            return self.getToken(SqlBaseParser.MONTH, 0)

        def NFC(self):
            return self.getToken(SqlBaseParser.NFC, 0)

        def NFD(self):
            return self.getToken(SqlBaseParser.NFD, 0)

        def NFKC(self):
            return self.getToken(SqlBaseParser.NFKC, 0)

        def NFKD(self):
            return self.getToken(SqlBaseParser.NFKD, 0)

        def NO(self):
            return self.getToken(SqlBaseParser.NO, 0)

        def NULLIF(self):
            return self.getToken(SqlBaseParser.NULLIF, 0)

        def NULLS(self):
            return self.getToken(SqlBaseParser.NULLS, 0)

        def ONLY(self):
            return self.getToken(SqlBaseParser.ONLY, 0)

        def OPTION(self):
            return self.getToken(SqlBaseParser.OPTION, 0)

        def ORDINALITY(self):
            return self.getToken(SqlBaseParser.ORDINALITY, 0)

        def OUTPUT(self):
            return self.getToken(SqlBaseParser.OUTPUT, 0)

        def OVER(self):
            return self.getToken(SqlBaseParser.OVER, 0)

        def PARTITION(self):
            return self.getToken(SqlBaseParser.PARTITION, 0)

        def PARTITIONS(self):
            return self.getToken(SqlBaseParser.PARTITIONS, 0)

        def POSITION(self):
            return self.getToken(SqlBaseParser.POSITION, 0)

        def PRECEDING(self):
            return self.getToken(SqlBaseParser.PRECEDING, 0)

        def PRIVILEGES(self):
            return self.getToken(SqlBaseParser.PRIVILEGES, 0)

        def PROPERTIES(self):
            return self.getToken(SqlBaseParser.PROPERTIES, 0)

        def PUBLIC(self):
            return self.getToken(SqlBaseParser.PUBLIC, 0)

        def RANGE(self):
            return self.getToken(SqlBaseParser.RANGE, 0)

        def READ(self):
            return self.getToken(SqlBaseParser.READ, 0)

        def RENAME(self):
            return self.getToken(SqlBaseParser.RENAME, 0)

        def REPEATABLE(self):
            return self.getToken(SqlBaseParser.REPEATABLE, 0)

        def REPLACE(self):
            return self.getToken(SqlBaseParser.REPLACE, 0)

        def RESET(self):
            return self.getToken(SqlBaseParser.RESET, 0)

        def RESTRICT(self):
            return self.getToken(SqlBaseParser.RESTRICT, 0)

        def REVOKE(self):
            return self.getToken(SqlBaseParser.REVOKE, 0)

        def ROLLBACK(self):
            return self.getToken(SqlBaseParser.ROLLBACK, 0)

        def ROW(self):
            return self.getToken(SqlBaseParser.ROW, 0)

        def ROWS(self):
            return self.getToken(SqlBaseParser.ROWS, 0)

        def SCHEMA(self):
            return self.getToken(SqlBaseParser.SCHEMA, 0)

        def SCHEMAS(self):
            return self.getToken(SqlBaseParser.SCHEMAS, 0)

        def SECOND(self):
            return self.getToken(SqlBaseParser.SECOND, 0)

        def SERIALIZABLE(self):
            return self.getToken(SqlBaseParser.SERIALIZABLE, 0)

        def SESSION(self):
            return self.getToken(SqlBaseParser.SESSION, 0)

        def SET(self):
            return self.getToken(SqlBaseParser.SET, 0)

        def SETS(self):
            return self.getToken(SqlBaseParser.SETS, 0)

        def SHOW(self):
            return self.getToken(SqlBaseParser.SHOW, 0)

        def SMALLINT(self):
            return self.getToken(SqlBaseParser.SMALLINT, 0)

        def SOME(self):
            return self.getToken(SqlBaseParser.SOME, 0)

        def START(self):
            return self.getToken(SqlBaseParser.START, 0)

        def STATS(self):
            return self.getToken(SqlBaseParser.STATS, 0)

        def SUBSTRING(self):
            return self.getToken(SqlBaseParser.SUBSTRING, 0)

        def SYSTEM(self):
            return self.getToken(SqlBaseParser.SYSTEM, 0)

        def TABLES(self):
            return self.getToken(SqlBaseParser.TABLES, 0)

        def TABLESAMPLE(self):
            return self.getToken(SqlBaseParser.TABLESAMPLE, 0)

        def TEXT(self):
            return self.getToken(SqlBaseParser.TEXT, 0)

        def TIME(self):
            return self.getToken(SqlBaseParser.TIME, 0)

        def TIMESTAMP(self):
            return self.getToken(SqlBaseParser.TIMESTAMP, 0)

        def TINYINT(self):
            return self.getToken(SqlBaseParser.TINYINT, 0)

        def TO(self):
            return self.getToken(SqlBaseParser.TO, 0)

        def TRANSACTION(self):
            return self.getToken(SqlBaseParser.TRANSACTION, 0)

        def TRY_CAST(self):
            return self.getToken(SqlBaseParser.TRY_CAST, 0)

        def TYPE(self):
            return self.getToken(SqlBaseParser.TYPE, 0)

        def UNBOUNDED(self):
            return self.getToken(SqlBaseParser.UNBOUNDED, 0)

        def UNCOMMITTED(self):
            return self.getToken(SqlBaseParser.UNCOMMITTED, 0)

        def USE(self):
            return self.getToken(SqlBaseParser.USE, 0)

        def VALIDATE(self):
            return self.getToken(SqlBaseParser.VALIDATE, 0)

        def VERBOSE(self):
            return self.getToken(SqlBaseParser.VERBOSE, 0)

        def VIEW(self):
            return self.getToken(SqlBaseParser.VIEW, 0)

        def WORK(self):
            return self.getToken(SqlBaseParser.WORK, 0)

        def WRITE(self):
            return self.getToken(SqlBaseParser.WRITE, 0)

        def YEAR(self):
            return self.getToken(SqlBaseParser.YEAR, 0)

        def ZONE(self):
            return self.getToken(SqlBaseParser.ZONE, 0)

        def getRuleIndex(self):
            return SqlBaseParser.RULE_nonReserved

        def enterRule(self, listener):
            if hasattr(listener, "enterNonReserved"):
                listener.enterNonReserved(self)

        def exitRule(self, listener):
            if hasattr(listener, "exitNonReserved"):
                listener.exitNonReserved(self)




    def nonReserved(self):

        localctx = SqlBaseParser.NonReservedContext(self, self._ctx, self.state)
        self.enterRule(localctx, 120, self.RULE_nonReserved)
        self._la = 0 # Token type
        try:
            self.enterOuterAlt(localctx, 1)
            self.state = 1500
            _la = self._input.LA(1)
            if not((((_la) & ~0x3f) == 0 and ((1 << _la) & ((1 << SqlBaseParser.ADD) | (1 << SqlBaseParser.ALL) | (1 << SqlBaseParser.ANALYZE) | (1 << SqlBaseParser.ANY) | (1 << SqlBaseParser.ARRAY) | (1 << SqlBaseParser.ASC) | (1 << SqlBaseParser.AT) | (1 << SqlBaseParser.BERNOULLI) | (1 << SqlBaseParser.CALL) | (1 << SqlBaseParser.CASCADE) | (1 << SqlBaseParser.CATALOGS) | (1 << SqlBaseParser.COALESCE) | (1 << SqlBaseParser.COLUMN) | (1 << SqlBaseParser.COLUMNS) | (1 << SqlBaseParser.COMMENT) | (1 << SqlBaseParser.COMMIT) | (1 << SqlBaseParser.COMMITTED) | (1 << SqlBaseParser.CURRENT) | (1 << SqlBaseParser.DATA) | (1 << SqlBaseParser.DATE) | (1 << SqlBaseParser.DAY) | (1 << SqlBaseParser.DESC) | (1 << SqlBaseParser.DISTRIBUTED) | (1 << SqlBaseParser.EXCLUDING) | (1 << SqlBaseParser.EXPLAIN) | (1 << SqlBaseParser.FILTER))) != 0) or ((((_la - 64)) & ~0x3f) == 0 and ((1 << (_la - 64)) & ((1 << (SqlBaseParser.FIRST - 64)) | (1 << (SqlBaseParser.FOLLOWING - 64)) | (1 << (SqlBaseParser.FORMAT - 64)) | (1 << (SqlBaseParser.FUNCTIONS - 64)) | (1 << (SqlBaseParser.GRANT - 64)) | (1 << (SqlBaseParser.GRANTS - 64)) | (1 << (SqlBaseParser.GRAPHVIZ - 64)) | (1 << (SqlBaseParser.HOUR - 64)) | (1 << (SqlBaseParser.IF - 64)) | (1 << (SqlBaseParser.INCLUDING - 64)) | (1 << (SqlBaseParser.INPUT - 64)) | (1 << (SqlBaseParser.INTEGER - 64)) | (1 << (SqlBaseParser.INTERVAL - 64)) | (1 << (SqlBaseParser.ISOLATION - 64)) | (1 << (SqlBaseParser.LAST - 64)) | (1 << (SqlBaseParser.LATERAL - 64)) | (1 << (SqlBaseParser.LEVEL - 64)) | (1 << (SqlBaseParser.LIMIT - 64)) | (1 << (SqlBaseParser.LOGICAL - 64)) | (1 << (SqlBaseParser.MAP - 64)) | (1 << (SqlBaseParser.MINUTE - 64)) | (1 << (SqlBaseParser.MONTH - 64)) | (1 << (SqlBaseParser.NFC - 64)) | (1 << (SqlBaseParser.NFD - 64)) | (1 << (SqlBaseParser.NFKC - 64)) | (1 << (SqlBaseParser.NFKD - 64)) | (1 << (SqlBaseParser.NO - 64)) | (1 << (SqlBaseParser.NULLIF - 64)) | (1 << (SqlBaseParser.NULLS - 64)) | (1 << (SqlBaseParser.ONLY - 64)) | (1 << (SqlBaseParser.OPTION - 64)) | (1 << (SqlBaseParser.ORDINALITY - 64)) | (1 << (SqlBaseParser.OUTPUT - 64)) | (1 << (SqlBaseParser.OVER - 64)) | (1 << (SqlBaseParser.PARTITION - 64)) | (1 << (SqlBaseParser.PARTITIONS - 64)) | (1 << (SqlBaseParser.POSITION - 64)) | (1 << (SqlBaseParser.PRECEDING - 64)))) != 0) or ((((_la - 128)) & ~0x3f) == 0 and ((1 << (_la - 128)) & ((1 << (SqlBaseParser.PRIVILEGES - 128)) | (1 << (SqlBaseParser.PROPERTIES - 128)) | (1 << (SqlBaseParser.PUBLIC - 128)) | (1 << (SqlBaseParser.RANGE - 128)) | (1 << (SqlBaseParser.READ - 128)) | (1 << (SqlBaseParser.RENAME - 128)) | (1 << (SqlBaseParser.REPEATABLE - 128)) | (1 << (SqlBaseParser.REPLACE - 128)) | (1 << (SqlBaseParser.RESET - 128)) | (1 << (SqlBaseParser.RESTRICT - 128)) | (1 << (SqlBaseParser.REVOKE - 128)) | (1 << (SqlBaseParser.ROLLBACK - 128)) | (1 << (SqlBaseParser.ROW - 128)) | (1 << (SqlBaseParser.ROWS - 128)) | (1 << (SqlBaseParser.SCHEMA - 128)) | (1 << (SqlBaseParser.SCHEMAS - 128)) | (1 << (SqlBaseParser.SECOND - 128)) | (1 << (SqlBaseParser.SERIALIZABLE - 128)) | (1 << (SqlBaseParser.SESSION - 128)) | (1 << (SqlBaseParser.SET - 128)) | (1 << (SqlBaseParser.SETS - 128)) | (1 << (SqlBaseParser.SHOW - 128)) | (1 << (SqlBaseParser.SMALLINT - 128)) | (1 << (SqlBaseParser.SOME - 128)) | (1 << (SqlBaseParser.START - 128)) | (1 << (SqlBaseParser.STATS - 128)) | (1 << (SqlBaseParser.SUBSTRING - 128)) | (1 << (SqlBaseParser.SYSTEM - 128)) | (1 << (SqlBaseParser.TABLES - 128)) | (1 << (SqlBaseParser.TABLESAMPLE - 128)) | (1 << (SqlBaseParser.TEXT - 128)) | (1 << (SqlBaseParser.TIME - 128)) | (1 << (SqlBaseParser.TIMESTAMP - 128)) | (1 << (SqlBaseParser.TINYINT - 128)) | (1 << (SqlBaseParser.TO - 128)) | (1 << (SqlBaseParser.TRANSACTION - 128)) | (1 << (SqlBaseParser.TRY_CAST - 128)) | (1 << (SqlBaseParser.TYPE - 128)) | (1 << (SqlBaseParser.UNBOUNDED - 128)) | (1 << (SqlBaseParser.UNCOMMITTED - 128)) | (1 << (SqlBaseParser.USE - 128)) | (1 << (SqlBaseParser.VALIDATE - 128)) | (1 << (SqlBaseParser.VERBOSE - 128)) | (1 << (SqlBaseParser.VIEW - 128)) | (1 << (SqlBaseParser.WORK - 128)) | (1 << (SqlBaseParser.WRITE - 128)) | (1 << (SqlBaseParser.YEAR - 128)) | (1 << (SqlBaseParser.ZONE - 128)))) != 0)):
                self._errHandler.recoverInline(self)
            else:
                self._errHandler.reportMatch(self)
                self.consume()
        except RecognitionException as re:
            localctx.exception = re
            self._errHandler.reportError(self, re)
            self._errHandler.recover(self, re)
        finally:
            self.exitRule()
        return localctx



    def sempred(self, localctx, ruleIndex, predIndex):
        if self._predicates == None:
            self._predicates = dict()
        self._predicates[11] = self.queryTerm_sempred
        self._predicates[22] = self.relation_sempred
        self._predicates[31] = self.booleanExpression_sempred
        self._predicates[34] = self.valueExpression_sempred
        self._predicates[35] = self.primaryExpression_sempred
        self._predicates[44] = self.type_sempred
        pred = self._predicates.get(ruleIndex, None)
        if pred is None:
            raise Exception("No predicate with index:" + str(ruleIndex))
        else:
            return pred(localctx, predIndex)

    def queryTerm_sempred(self, localctx, predIndex):
            if predIndex == 0:
                return self.precpred(self._ctx, 2)
         

            if predIndex == 1:
                return self.precpred(self._ctx, 1)
         

    def relation_sempred(self, localctx, predIndex):
            if predIndex == 2:
                return self.precpred(self._ctx, 2)
         

    def booleanExpression_sempred(self, localctx, predIndex):
            if predIndex == 3:
                return self.precpred(self._ctx, 2)
         

            if predIndex == 4:
                return self.precpred(self._ctx, 1)
         

    def valueExpression_sempred(self, localctx, predIndex):
            if predIndex == 5:
                return self.precpred(self._ctx, 3)
         

            if predIndex == 6:
                return self.precpred(self._ctx, 2)
         

            if predIndex == 7:
                return self.precpred(self._ctx, 1)
         

            if predIndex == 8:
                return self.precpred(self._ctx, 5)
         

    def primaryExpression_sempred(self, localctx, predIndex):
            if predIndex == 9:
                return self.precpred(self._ctx, 14)
         

            if predIndex == 10:
                return self.precpred(self._ctx, 12)
         

    def type_sempred(self, localctx, predIndex):
            if predIndex == 11:
                return self.precpred(self._ctx, 6)
         




