Skip to content

Commit e5d75f0

Browse files
Merge pull request #1 from stackql/feature/idempotent-create
idempotent-create
2 parents a772f14 + c72d842 commit e5d75f0

File tree

3 files changed

+682
-655
lines changed

3 files changed

+682
-655
lines changed

go/vt/sqlparser/ast.go

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -198,11 +198,12 @@ type (
198198

199199
// DBDDL represents a CREATE, DROP, or ALTER database statement.
200200
DBDDL struct {
201-
Action string
202-
DBName string
203-
IfExists bool
204-
Collate string
205-
Charset string
201+
Action string
202+
DBName string
203+
IfExists bool
204+
IfNotExists bool
205+
Collate string
206+
Charset string
206207
}
207208

208209
// DDL represents a CREATE, ALTER, DROP, RENAME, TRUNCATE or ANALYZE statement.
@@ -220,8 +221,10 @@ type (
220221

221222
// The following fields are set if a DDL was fully analyzed.
222223
IfExists bool
224+
IfNotExists bool
223225
TableSpec *TableSpec
224226
OptLike *OptLike
227+
OrReplace bool
225228
PartitionSpec *PartitionSpec
226229

227230
// VindexSpec is set for CreateVindexStr, DropVindexStr, AddColVindexStr, DropColVindexStr.

0 commit comments

Comments
 (0)