Subject Re: [IBO] Error in statement?
Author Svein Erling Tysvær
Hi again, Svein Petter.

Just thought that since you found your error, you may not have taken proper
notice of Randal's advice. Your SQL is doing the one thing Jason has
consistently warned us against - using JOIN criteria in the WHERE clause.
If you use this ancient SQL standard, you MUST fill in JoinLinks - but it's
pretty simple to use more modern SQL (which eliminates the need for
JoinLinks), i.e.

Select *
from TRANS
JOIN DETAIL ON TRANS.TRANS_NR = Detail.TRANS_NR
AND TRANS.REC_ID = DETAIL.TRANS_REC_ID
where TRANS.PAY_MODE = 5
AND DETAIL.REC_ID > 0
AND TRANS.OP_MODE = 1

If your program works with the old notation without JoinLinks, you're just
unlucky enough to postphone your problem - it might well bite you when your
selects get more complicated.

JTAFT (Just to avoid future trouble),
Set