I have 2 queries that need to run one after the other one. the first one returns a single value for work order
and the next one returns all related serial numbers:
--Get the work order
SELECT * FROM WorkOrder w WHERE w.WorkOrderName = 'test wo';
--Get related serial numbers
SELECT * FROM SerialNumber WHERE SerialNumber.WorkOrderId = w.Id;
Is it possible to run both queries in the same context so that I could use the w
variable in the second query and get 2 result sets: