RFC: Use provided type to create the dstTable rather than inferring from the SQL types #1872

Merged
lunny merged 18 commits from zeripath/xorm:dump-infer-from-type into master 2021-05-07 01:19:04 +00:00
Showing only changes of commit 3d4da2bea2 - Show all commits

View File

@ -353,6 +353,8 @@ func (db *mysql) GetColumns(queryer core.Queryer, ctx context.Context, tableName
cts := strings.Split(colType, "(")
colName := cts[0]
// Remove the /* mariadb-5.3 */ suffix from coltypes
colName = strings.TrimSuffix(colName, "/* mariadb-5.3 */")
colType = strings.ToUpper(colName)
var len1, len2 int
if len(cts) == 2 {