Need help with sql
From: xmy <xmy009_at_163.net>
Date: 6 Dec 2001 06:36:06 -0800
Message-ID: <440264b2.0112060636.4d11f04f_at_posting.google.com>
)
GROUP BY input_date;
Date: 6 Dec 2001 06:36:06 -0800
Message-ID: <440264b2.0112060636.4d11f04f_at_posting.google.com>
Hi folks,
I have another question for
here is my query :
SELECT input_date, SUM(totbo) as USCO_TOTBO, SUM (xci_count) as
XCI_TOTBO
UNION
you. I have written a query using UNION operator. I have tested these
two
queries seprately and they work well, but when I use the UNION an
error
appears telling me that UNION is an unknown command.. strange!
FROM
(SELECT input_date, totbo, 0 as xci_count
FROM uscobosum
WHERE input_date >= ADD_MONTHS(sysdate,-24) and
(TO_CHAR(input_date,'DAY') like 'M%')
FROM xci_bo WHERE input_date >=ADD_MONTHS(sysdate,-24) GROUP BY input_date
)
GROUP BY input_date;
think you help me. Received on Thu Dec 06 2001 - 15:36:06 CET