How to use update as a inner subquery in postgresql?
update unit_has_jobcard
set status = 'approval'
where id = (update jobcard_has_approvals
set approve = true
where id = 27
returning id);
I need to update two tables in single query. addBatch helps multiple queries hit a table in single time. But i need to know if is this possible.