Class ChCreateView
java.lang.Object
org.pgcodekeeper.core.database.base.parser.statement.ParserAbstract<ChDatabase>
org.pgcodekeeper.core.database.ch.parser.statement.ChParserAbstract
org.pgcodekeeper.core.database.ch.parser.statement.ChCreateView
Parser for ClickHouse CREATE VIEW statements.
Handles creation of simple views, materialized views, and live views with support for
columns, engines, destinations, definers, and SQL security settings.
-
Constructor Summary
ConstructorsConstructorDescriptionChCreateView(CHParser.Create_view_stmtContext ctx, ChDatabase db, org.antlr.v4.runtime.CommonTokenStream stream, ISettings settings) Creates a parser for ClickHouse CREATE VIEW statements. -
Method Summary
Modifier and TypeMethodDescriptionvoidParses a database object from the current context.voidparseObject(ChView view, boolean needFormatSql) Parses view details including query, comments, and view type-specific configurations.Methods inherited from class org.pgcodekeeper.core.database.ch.parser.statement.ChParserAbstract
getIdentifiersMethods inherited from class org.pgcodekeeper.core.database.base.parser.statement.ParserAbstract
getFullCtxText, getFullCtxText, getFullCtxText, getSafe, getSafe, parseArgMode, parseObject
-
Constructor Details
-
ChCreateView
public ChCreateView(CHParser.Create_view_stmtContext ctx, ChDatabase db, org.antlr.v4.runtime.CommonTokenStream stream, ISettings settings) Creates a parser for ClickHouse CREATE VIEW statements.- Parameters:
ctx- the ANTLR parse tree context for the CREATE VIEW statementdb- the ClickHouse database schema being processedstream- the token stream for whitespace normalizationsettings- parsing configuration settings
-
-
Method Details
-
parseObject
public void parseObject()Description copied from class:ParserAbstractParses a database object from the current context. Must be implemented by concrete subclasses to handle specific object types.- Specified by:
parseObjectin classParserAbstract<ChDatabase>
-
parseObject
Parses view details including query, comments, and view type-specific configurations. Handles simple views, materialized views, and live views with their respective options.- Parameters:
view- the view object to populate with parsed informationneedFormatSql- if true format select part.
-