嗨,我正在尝试将查询转换为序列查询,但我无法做到这一点,
查询为:
SELECT SUM(od."totalValue") AS total FROM "OrderDetails" AS od
LEFT JOIN "Orders" AS o ON od."orderId" = o.id
WHERE o."orderDate" >= '2019-10-17 00:00:00' AND o."orderDate" <= '2019-10-17 23:59:59' AND o."customerId" = 47085 AND (o.status = 'delivered' OR o.status = 'pending')
AND o."queueLastStep" <> 'header/failed' AND o."queueLastStep" <> 'header/retry' AND o."queueLastStep" IS NOT NULL;
如果有人可以帮忙