-
Notifications
You must be signed in to change notification settings - Fork 268
-
Hi all.
I have an insert query that returns the id of the inserted row:
insert into public.catalogue (c_id,delivery_method,name,code) values ({{frmCatalogueEntry.data.sltC}}::int,{{frmCatalogueEntry.data.sltDeliveryMethod}},
{{frmCatalogueEntry.data.txtName}},{{frmCatalogueEntry.data.txtCode}}) returning id
I try to access this in a query that is run "On Success"
insert into public.cost_price (catalogue_id,provider,active,created)
values({{insertCatalogueEntry.data.id}}, .....
But the {{insertCatalogueEntry.data.id}} is always null?
Also is there a way to wrap this all in a transaction so the queries commit or rollback on failure?
Thanks
Beta Was this translation helpful? Give feedback.
All reactions
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment