This content has been marked as final. Show 5 replies
Is this not working?
SELECT A.*, B.START_DATE, B.END_DATE FROM A, B WHERE A.LOCATION_CODE = B.LOCATION_CODE (+) AND A.GL_DATE BETWEEN B.START_DATE(+) and B.END_DATE(+)
Ok, I was able to resolve the issue.
I'm in a similar situation,
I have a complex query, everything is working fine, except this part (I will simplify everything, removing other stuffs because I need help only on the following condition)
from transaction t, card c
where c.card_id = t.card_id (+)
and t.trn_date between to_date ('01/01/2012','dd/mm/yy') and ('01/01/2013,'dd/mm/yy')
How could i OUTER JOIN the between condition?
I tried with
and t.trn_date between to_date ('01/01/2012','dd/mm/yy') (+) and ('01/01/2013','dd/mm/yy') (+)
but returns a "missing expression" error.
Surely I'm missing some stupid thing about it, could you help me on this? (probably because I'm talking about parameters and I cannot put the outer join on a value)
How can I rewrite the condition in order to satisfy what I'm trying to accomplish?
Thanks in Advance,
Edited by: 981667 on 14-gen-2013 4.23
Edited by: 981667 on 14-gen-2013 4.24
Just put the OJ symbol on the lhs column, not on the rhs constants
Or just use ANSI syntax...
SELECT * from card c left outer join transaction t on (c.card_id = t.card_id and t.trn_date between to_date('01/01/2012','dd/mm/yy') and ('01/01/2013,'dd/mm/yy') )