jsonbAssignment registers all assignment casts. This comprises only the source types.
(builtInCasts map[id.Cast]casts.Cast)
| 354 | |
| 355 | // jsonbAssignment registers all assignment casts. This comprises only the source types. |
| 356 | func jsonbAssignment(builtInCasts map[id.Cast]casts.Cast) { |
| 357 | framework.MustAddAssignmentTypeCast(builtInCasts, framework.TypeCast{ |
| 358 | FromType: pgtypes.JsonB, |
| 359 | ToType: pgtypes.Json, |
| 360 | Function: func(ctx *sql.Context, val any, _, targetType *pgtypes.DoltgresType) (any, error) { |
| 361 | return pgtypes.JsonB.IoOutput(ctx, val) |
| 362 | }, |
| 363 | }) |
| 364 | } |
no test coverage detected