skip to Main Content

Postgresql – DIFFERENCE CALC BETWEEN 2 SUBQUERIES

I have 2 subqueries which give me a result consisting of dates. I would like to calculate the difference between them. For example: SELECT DATEDIFF( DAY, (SELECT MAX(invoices.date) FROM invoices WHERE invoices.orderno = odH.orderno), (SELECT min(history.date) FROM history WHERE history.orderno…

VIEW QUESTION
Back To Top
Search