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

Struct InsertStatement

pkg/sql/ast/ast.go:1245–1256  ·  view source on GitHub ↗

InsertStatement represents an INSERT SQL statement

Source from the content-addressed store, hash-verified

1243
1244// InsertStatement represents an INSERT SQL statement
1245type InsertStatement struct {
1246 With *WithClause
1247 TableName string
1248 Columns []Expression
1249 Output []Expression // SQL Server OUTPUT clause columns
1250 Values [][]Expression // Multi-row support: each inner slice is one row of values
1251 Query QueryExpression // For INSERT ... SELECT (SelectStatement or SetOperation)
1252 Returning []Expression
1253 OnConflict *OnConflict
1254 OnDuplicateKey *UpsertClause // MySQL: ON DUPLICATE KEY UPDATE
1255 Pos models.Location // Source position of the INSERT keyword (1-based line and column)
1256}
1257
1258func (i *InsertStatement) statementNode() {}
1259func (i InsertStatement) TokenLiteral() string { return "INSERT" }

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected