dialect/sql/schema: add field collation support for postgres

This commit is contained in:
Ariel Mashraki
2021-05-10 20:18:33 +03:00
committed by Ariel Mashraki
parent 53e885cbff
commit f7db15ccbb
5 changed files with 10 additions and 13 deletions

View File

@@ -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.