Open
Description
The following query inserts a JSON object to a table with a JSONB column.
UPDATE public.property_history
SET attributes = ${sql.jsonb(attributes ?? null)}, status = ${status}
WHERE id = ${id}
When utilizing slonik using
await createPool(pgConnString!, {typeParsers});
it inserts correctly as an object.
However the same query inserts the object as a stringified string when using:
const PgPool = createPostgresBridge(postgres);
await createPool(pgConnString!, {PgPool, typeParsers});
Metadata
Metadata
Assignees
Labels
No labels