func (m Map) Value() (driver.Value, error) {
	b, err := json.Marshal(m)
	if err != nil {
		return nil, ErrSQLMapMarshalValue(err)
	}
	return string(b), nil
}
Value implements the driver.Valuer interface.
It allows to convert the map to a driver.value.
package database
import (
	"database/sql/driver"
	"encoding/json"
)
type Map map[string]interface{}
func (m Map) Interface() interface{} {
	return map[string]interface{}(m)
}
func (m *Map) Scan(src interface{}) error {
	var b []byte
	switch t := src.(type) {
	case []byte:
		b = t
	case string:
		b = []byte(t)
	default:
		return ErrSQLMapInvalidScan
	}
	if err := json.Unmarshal(b, m); err != nil {
		return ErrSQLMapUnmarshalScanned(err)
	}
	return nil
}