diff --git a/migrator/migrator.go b/migrator/migrator.go index 5de820a8..084d430f 100644 --- a/migrator/migrator.go +++ b/migrator/migrator.go @@ -381,7 +381,7 @@ func (m Migrator) MigrateColumn(value interface{}, field *schema.Field, columnTy // check precision if precision, _, ok := columnType.DecimalSize(); ok && int64(field.Precision) != precision { - if strings.Contains(fullDataType, fmt.Sprint(field.Precision)) { + if strings.Contains(m.DataTypeOf(field), fmt.Sprint(field.Precision)) { alterColumn = true } }