sql writer
This commit is contained in:
4
pkg/writers/pgsql/templates/add_column.tmpl
Normal file
4
pkg/writers/pgsql/templates/add_column.tmpl
Normal file
@@ -0,0 +1,4 @@
|
||||
ALTER TABLE {{.SchemaName}}.{{.TableName}}
|
||||
ADD COLUMN IF NOT EXISTS {{.ColumnName}} {{.ColumnType}}
|
||||
{{- if .Default}} DEFAULT {{.Default}}{{end}}
|
||||
{{- if .NotNull}} NOT NULL{{end}};
|
||||
Reference in New Issue
Block a user