public final class CreateChTable extends ChParserAbstract
Parser for ClickHouse CREATE TABLE statements. Handles table creation including columns, engines, constraints, indexes, and projections. Automatically selects appropriate table type (ChTable or ChTableLog) based on engine type.
  • Constructor Details

    • CreateChTable

      public CreateChTable(CHParser.Create_table_stmtContext ctx, ChDatabase db, ISettings settings)
      Creates a parser for ClickHouse CREATE TABLE statements.
      Parameters:
      ctx - the ANTLR parse tree context for the CREATE TABLE statement
      db - the ClickHouse database schema being processed
      settings - parsing configuration settings
  • Method Details

    • parseObject

      public void parseObject()
      Description copied from class: ParserAbstract
      Parses a database object from the current context. Must be implemented by concrete subclasses to handle specific object types.
      Specified by:
      parseObject in class ParserAbstract<ChDatabase>
    • parseObject

      public void parseObject(ChTable table)
      Parses table details including engine, elements, and comments. Processes all table elements such as columns, constraints, indexes, and projections.
      Parameters:
      table - the table object to populate with parsed information