Unfortunately there is another bug with Maps

Signed-off-by: Andrew Thornton <art27@cantab.net>
This commit is contained in:
Andrew Thornton 2021-05-08 21:38:52 +01:00
parent a23bc6e5d9
commit 6bfa2972d4
No known key found for this signature in database
GPG Key ID: 3CDE74631F13A748
1 changed files with 1 additions and 1 deletions

View File

@ -460,7 +460,7 @@ func formatColumnValue(dstDialect dialects.Dialect, d interface{}, col *schemas.
if col.SQLType.IsText() {
var v string
switch reflect.TypeOf(d).Kind() {
case reflect.Struct, reflect.Array, reflect.Slice:
case reflect.Struct, reflect.Array, reflect.Slice, reflect.Map:
bytes, err := json.DefaultJSONHandler.Marshal(d)
if err != nil {
v = fmt.Sprintf("%s", d)