You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
The Collate in types.FieldType in ColumnDef seems to be always empty #1309
Is your feature request related to a problem? Please describe:
When using pingcap/parser to parse SQL statement, the Collate in types.FieldType in ColumnDef seems to be always empty even if with collate specified in SQL statement.
Consider the following SQL statement: CREATE TABLE contacts (col1 char(10) CHARACTER SET ascii COLLATE ascii_bin, col2 varbinary(7), col3 varchar(20));
After parsing, the collate in types.FieldType in ColumnDef seems to be always empty and collate option can only be found in Options Array.
Describe the feature you'd like:
If a COLLATE of a column is found then set the COLLATE type to the collate in types.FieldType.
Describe alternatives you've considered:
Users can always get the collate value in options array, but since there's a collate field in types.FieldType, I think the parser should take the responsibility of setting the collate option.
Activity