public class ClickHouseSqlParser extends Object implements ClickHouseSqlParserConstants
| Modifier and Type | Field and Description |
|---|---|
Token |
jj_nt
Next token.
|
Token |
token
Current token.
|
ClickHouseSqlParserTokenManager |
token_source
Generated Token Manager.
|
A, ALL, ALTER, AND, APPLY, ARRAY, ARROW, AS, ASOF, ASTERISK, AT, ATTACH, B, BACK_QUOTE, BACK_QUOTED_NAME, BACK_SLASH, BETWEEN, C, CASE, CHECK, CLUSTER, COLON, COMMA, CONCAT, CREATE, D, DASH, DATABASE, DATABASES, DATE, DAY, DEC_DIGIT, DECIMAL_LITERAL, DEFAULT, DELETE, DESC, DESCRIBE, DETACH, DICTIONARIES, DICTIONARY, DISTINCT, DOLLAR, DOT, DOUBLE_QUOTE, DOUBLE_QUOTED_NAME, DROP, E, ELSE, END, EOF, EQ_DOUBLE, EQ_SINGLE, EXCEPT, EXISTS, EXPLAIN, F, FINAL, FLOATING_LITERAL, FORMAT, FROM, FULL, FUNCTION, G, GE, GLOBAL, GRANT, GROUP, GT, H, HASH, HAVING, HEX_DIGIT, HEXADECIMAL_LITERAL, HOUR, I, IDENTIFIER, IF, ILIKE, IN, INF, INNER, INSERT, INTERVAL, INTO, IS, J, JOIN, K, KILL, L, LBRACE, LBRACKET, LE, LEFT, LETTER, LIKE, LIMIT, LIVE, LPAREN, LT, M, MATERIALIZED, MINUTE, MONTH, MULTI_LINE_COMMENT, N, NAN, NOT, NOT_EQ, NULL, O, OFFSET, ON, OPTIMIZE, OR, ORDER, OUTFILE, P, PERCENT, PLUS, POLICY, PREWHERE, PROFILE, Q, QUARTER, QUERY, QUOTA, R, RBRACE, RBRACKET, RENAME, REPLACE, REVOKE, RIGHT, ROLE, ROW, RPAREN, S, SAMPLE, SECOND, SELECT, SEMICOLON, SET, SETTINGS, SHOW, SINGLE_LINE_COMMENT, SINGLE_QUOTE, SLASH, STRING_LITERAL, SYSTEM, T, TABLE, TABLES, TEMPORARY, THEN, TIES, TIMESTAMP, tokenImage, TOP, TOTALS, TRUNCATE, U, UNDERSCORE, UNION, UPDATE, USE, USER, USING, V, VALUES, VIEW, W, WATCH, WEEK, WHEN, WHERE, WHITESPACE, WITH, X, Y, YEAR, Z, ZERO| Constructor and Description |
|---|
ClickHouseSqlParser(ClickHouseSqlParserTokenManager tm)
Constructor with generated Token Manager.
|
ClickHouseSqlParser(InputStream stream)
Constructor with InputStream.
|
ClickHouseSqlParser(InputStream stream,
Charset encoding)
Constructor with InputStream and supplied encoding
|
ClickHouseSqlParser(Reader stream)
Constructor with InputStream.
|
ClickHouseSqlParser(String sql,
ClickHouseProperties properties,
ParseHandler handler) |
public ClickHouseSqlParserTokenManager token_source
public Token token
public Token jj_nt
public ClickHouseSqlParser(String sql, ClickHouseProperties properties, ParseHandler handler)
public ClickHouseSqlParser(InputStream stream)
stream - input streampublic ClickHouseSqlParser(InputStream stream, Charset encoding)
stream - input streamencoding - charset to be usedpublic ClickHouseSqlParser(Reader stream)
stream - char streampublic ClickHouseSqlParser(ClickHouseSqlParserTokenManager tm)
tm - Token manager to usepublic static ClickHouseSqlStatement[] parse(String sql, ClickHouseProperties properties)
public static ClickHouseSqlStatement[] parse(String sql, ClickHouseProperties properties, ParseHandler handler)
public void addStatement()
public final ClickHouseSqlStatement[] sql() throws ParseException
ParseExceptionpublic final void stmts()
throws ParseException
ParseExceptionpublic final void stmt()
throws ParseException
ParseExceptionpublic final void alterStmt()
throws ParseException
ParseExceptionpublic final void clusterClause()
throws ParseException
ParseExceptionpublic final void attachStmt()
throws ParseException
ParseExceptionpublic final void checkStmt()
throws ParseException
ParseExceptionpublic final void createStmt()
throws ParseException
ParseExceptionpublic final void deleteStmt()
throws ParseException
ParseExceptionpublic final void describeStmt()
throws ParseException
ParseExceptionpublic final void detachStmt()
throws ParseException
ParseExceptionpublic final void dropStmt()
throws ParseException
ParseExceptionpublic final void existsStmt()
throws ParseException
ParseExceptionpublic final void explainStmt()
throws ParseException
ParseExceptionpublic final void grantStmt()
throws ParseException
ParseExceptionpublic final void insertStmt()
throws ParseException
ParseExceptionpublic final void dataClause()
throws ParseException
ParseExceptionpublic final void killStmt()
throws ParseException
ParseExceptionpublic final void optimizeStmt()
throws ParseException
ParseExceptionpublic final void renameStmt()
throws ParseException
ParseExceptionpublic final void revokeStmt()
throws ParseException
ParseExceptionpublic final void selectStmt()
throws ParseException
ParseExceptionpublic final void withClause()
throws ParseException
ParseExceptionpublic final void topClause()
throws ParseException
ParseExceptionpublic final void tableClause(boolean record)
throws ParseException
ParseExceptionpublic final void setStmt()
throws ParseException
ParseExceptionpublic final void showStmt()
throws ParseException
ParseExceptionpublic final void systemStmt()
throws ParseException
ParseExceptionpublic final void truncateStmt()
throws ParseException
ParseExceptionpublic final void updateStmt()
throws ParseException
ParseExceptionpublic final void useStmt()
throws ParseException
ParseExceptionpublic final void watchStmt()
throws ParseException
ParseExceptionpublic final void columnExprList()
throws ParseException
ParseExceptionpublic final void withExpr()
throws ParseException
ParseExceptionpublic final void columnsExpr()
throws ParseException
ParseExceptionpublic final void allColumnsExpr()
throws ParseException
ParseExceptionpublic final void nestedExpr()
throws ParseException
ParseExceptionpublic final void calcExpr()
throws ParseException
ParseExceptionpublic final void betweenExpr()
throws ParseException
ParseExceptionpublic final void functionExpr()
throws ParseException
ParseExceptionpublic final void columnExpr()
throws ParseException
ParseExceptionpublic final void formatPart()
throws ParseException
ParseExceptionpublic final void outfilePart()
throws ParseException
ParseExceptionpublic final void withTotalPart()
throws ParseException
ParseExceptionpublic final void anyExprList()
throws ParseException
ParseExceptionpublic final void anyExpr()
throws ParseException
ParseExceptionpublic final void anyNestedExpr()
throws ParseException
ParseExceptionpublic final void anyColumnExpr()
throws ParseException
ParseExceptionpublic final Token aliasExpr() throws ParseException
ParseExceptionpublic final void nestedIdentifier()
throws ParseException
ParseExceptionpublic final void tableIdentifier(boolean record)
throws ParseException
ParseExceptionpublic final void databaseIdentifier(boolean record)
throws ParseException
ParseExceptionpublic final void settingExprList()
throws ParseException
ParseExceptionpublic final void settingExpr()
throws ParseException
ParseExceptionpublic final Token anyIdentifier() throws ParseException
ParseExceptionpublic final Token identifier() throws ParseException
ParseExceptionpublic final void interval()
throws ParseException
ParseExceptionpublic final Token literal() throws ParseException
ParseExceptionpublic final Token dateLiteral() throws ParseException
ParseExceptionpublic final Token numberLiteral() throws ParseException
ParseExceptionpublic final void operator()
throws ParseException
ParseExceptionpublic final void macro()
throws ParseException
ParseExceptionpublic final Token variable() throws ParseException
ParseExceptionpublic final Token anyKeyword() throws ParseException
ParseExceptionpublic final Token keyword() throws ParseException
ParseExceptionpublic void ReInit(InputStream stream)
stream - input streampublic void ReInit(InputStream stream, Charset encoding)
stream - input streamencoding - charset to be usedpublic void ReInit(Reader stream)
stream - char streampublic void ReInit(ClickHouseSqlParserTokenManager tm)
tm - Token manager to usepublic final Token getNextToken()
public final Token getToken(int index)
index - index to be retrievedpublic ParseException generateParseException()
public final boolean trace_enabled()
false.public final void enable_tracing()
public final void disable_tracing()
Copyright © 2015–2021 ClickHouse. All rights reserved.