MCPcopy Create free account
hub / github.com/ajitpratap0/GoSQLX / CreateTableStatement

Struct CreateTableStatement

pkg/sql/ast/ast.go:1385–1404  ·  view source on GitHub ↗

CreateTableStatement represents a CREATE TABLE statement

Source from the content-addressed store, hash-verified

1383
1384// CreateTableStatement represents a CREATE TABLE statement
1385type CreateTableStatement struct {
1386 IfNotExists bool
1387 Temporary bool
1388 Name string
1389 Columns []ColumnDef
1390 Constraints []TableConstraint
1391 Inherits []string
1392 PartitionBy *PartitionBy
1393 Partitions []PartitionDefinition // Individual partition definitions
1394 Options []TableOption
1395 WithoutRowID bool // SQLite: CREATE TABLE ... WITHOUT ROWID
1396
1397 // WithSystemVersioning enables system-versioned temporal history (MariaDB 10.3.4+).
1398 // Example: CREATE TABLE t (...) WITH SYSTEM VERSIONING
1399 WithSystemVersioning bool
1400
1401 // PeriodDefinitions holds PERIOD FOR clauses for application-time or system-time periods.
1402 // Example: PERIOD FOR app_time (start_col, end_col)
1403 PeriodDefinitions []*PeriodDefinition
1404}
1405
1406func (c *CreateTableStatement) statementNode() {}
1407func (c CreateTableStatement) TokenLiteral() string { return "CREATE TABLE" }

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected