mirror of
https://github.com/ent/ent.git
synced 2026-05-24 09:31:56 +03:00
dialect/sql/schema: add field collation support for postgres
This commit is contained in:
committed by
Ariel Mashraki
parent
53e885cbff
commit
f7db15ccbb
@@ -308,13 +308,6 @@ func (c Column) supportDefault() bool {
|
||||
}
|
||||
}
|
||||
|
||||
// collation adds `COLLATE collation_name`.
|
||||
func (c *Column) collation(b *sql.ColumnBuilder) {
|
||||
if c.Collation != "" {
|
||||
b.Attr("COLLATE " + c.Collation)
|
||||
}
|
||||
}
|
||||
|
||||
// unique adds the `UNIQUE` attribute if the column is a unique type.
|
||||
// it is exist in a different function to share the common declaration
|
||||
// between the two dialects.
|
||||
|
||||
Reference in New Issue
Block a user