amgfredA
Windmill2y ago
6 replies
amgfred

How to insert JSONB parameter in Postgres Action

Hiya folks,
Can't see what I'm missing here. I have a Postgres action as below:
-- $1 data

INSERT INTO table (data)
VALUES (cast($1 as jsonb));

but I get
ExecutionErr: error during execution of the script: db error: ERROR: unsupported jsonb version number 39

VALUES ($1::JSONB)
doesn't work either.
The parameter I'm using (e.g.
'{"some": "data"}'
works directly in the query:
INSERT INTO table (data)
VALUES ('{"some": "data"}');


Windmill expects a
string
type as the parameter.
I've checked the docs but couldn't find anything.
Thaaanks!
image.png
Was this page helpful?