-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathalter_table_drop_table_element_statement.go
More file actions
70 lines (55 loc) · 2.59 KB
/
alter_table_drop_table_element_statement.go
File metadata and controls
70 lines (55 loc) · 2.59 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
package ast
// AlterTableDropTableElementStatement represents an ALTER TABLE ... DROP statement.
type AlterTableDropTableElementStatement struct {
SchemaObjectName *SchemaObjectName
AlterTableDropTableElements []*AlterTableDropTableElement
}
func (*AlterTableDropTableElementStatement) node() {}
func (*AlterTableDropTableElementStatement) statement() {}
// AlterTableDropTableElement represents an element being dropped from a table.
type AlterTableDropTableElement struct {
TableElementType string
Name *Identifier
IsIfExists bool
DropClusteredConstraintOptions []DropClusteredConstraintOption
}
func (*AlterTableDropTableElement) node() {}
// DropClusteredConstraintOption is an interface for options when dropping clustered constraints.
type DropClusteredConstraintOption interface {
node()
dropClusteredConstraintOption()
}
// DropClusteredConstraintStateOption represents an ON/OFF option like ONLINE = ON.
type DropClusteredConstraintStateOption struct {
OptionKind string
OptionState string
}
func (*DropClusteredConstraintStateOption) node() {}
func (*DropClusteredConstraintStateOption) dropClusteredConstraintOption() {}
// DropClusteredConstraintMoveOption represents a MOVE TO option.
type DropClusteredConstraintMoveOption struct {
OptionKind string
OptionValue *FileGroupOrPartitionScheme
}
func (*DropClusteredConstraintMoveOption) node() {}
func (*DropClusteredConstraintMoveOption) dropClusteredConstraintOption() {}
// DropClusteredConstraintValueOption represents a value option like MAXDOP = 21.
type DropClusteredConstraintValueOption struct {
OptionKind string
OptionValue ScalarExpression
}
func (*DropClusteredConstraintValueOption) node() {}
func (*DropClusteredConstraintValueOption) dropClusteredConstraintOption() {}
// FileGroupOrPartitionScheme represents a filegroup or partition scheme reference.
type FileGroupOrPartitionScheme struct {
Name *IdentifierOrValueExpression
PartitionSchemeColumns []*Identifier
}
func (*FileGroupOrPartitionScheme) node() {}
// DropClusteredConstraintWaitAtLowPriorityLockOption represents a WAIT_AT_LOW_PRIORITY option.
type DropClusteredConstraintWaitAtLowPriorityLockOption struct {
OptionKind string // Always "MaxDop" based on the expected output
Options []LowPriorityLockWaitOption
}
func (*DropClusteredConstraintWaitAtLowPriorityLockOption) node() {}
func (*DropClusteredConstraintWaitAtLowPriorityLockOption) dropClusteredConstraintOption() {}