thanks kray - I will run each segment of query and put output of each into a new temp table and select everything from that once done. Pain but'll do the job and avoid the unions.
Hi all,
I have a rather long query selecting items out of various unconnected areas of the DB. I have a working query including 20 UNIONs but when I add the 21st I am presented with a syntax error DB Errorcode=-201 (standard general syntax code)
each statement in isolation runs fine.
Have i...
Hi,
I have a query with two inline views which is returning the error:
Error: Cannot obtain or set serial value. (State:S1000, Native Code: FFFFFD8E)
Statement is being run from WinSql client using IBM Informix ODBC driver.
SQL:
select
ACCT_ID,
TOT_DEP,
LIMIT_VALUE
from
TABLE(MULTISET...
Yep you're absolutely right - I'm making it unnecessarily complicated :-)
SELECT A.ACCT_ID, A.BALANCE, A.SUM_AP, SUM(J.AMOUNT) AS SUMBALANCE
FROM TACCT A, TJRNL J
WHERE A.ACCT_ID=J.ACCT_ID
AND J.CR_DATE=CURRENT
GROUP BY A.ACCT_ID, A.BALANCE, A.SUM_AP
For some reason the simple solution didn't...
Hi,
Thanks for the reply.
Removing the AS keyword still returns the same error, however I think I've cracked it - not seen syntax like this before!
SELECT A.ACCT_ID, A.BALANCE, A.SUM_AP, NEWPAY.SUMBALANCE
FROM TACCT A,
TABLE( MULTISET
(SELECT ACCT_ID, SUM(AMOUNT) AS SUMBALANCE
FROM TJRNL
WHERE...
I'm new to Informix and I'm unable to get a working inline view as per OracleSql. I'm executing the following statement:
SELECT A.ACCT_ID, A.BALANCE, A.SUM_AP, NEWPAY.SUMBALANCE
FROM TACCT A,
(SELECT ACCT_ID, SUM(AMOUNT) AS SUMBALANCE
FROM TJRNL
WHERE CR_DATE=CURRENT
GROUP BY ACCT_ID) AS...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.