The following mapping is causing some concern:
ifthenelse((DARR_SRC.COL1 = ‘0’), null , ‘B’)
If we look at the generated SQL for this mapping it is simply returning the column, not actually performing the ifthenelse logic.
If we tweak the mapping slightly to this:
ifthenelse((DARR_SRC.COL1 = ‘0’), ‘A’ , ‘B’)
then we generate the following SQL
SELECT ( DECODE( “DARR_SRC”.“COL1” , ‘0’, ‘A’, ‘B’) )
FROM “xxx”.“DARR_SRC” “DARR_SRC”
If looks as if the ifthenelse function will no longer be pushed down to the database (as a decode on Oracle) if the true condition resolves to NULL.
This is on 11.7.3.3
We have checked on 6.5 and this is pushed-down to Oracle. It seems like 6.5 seems to handle this much better than 11.7.3.3
Anybody have any idea why this was changed, or can you think of any situations where null was causing problems that would have made BO force this on to the engine?
dcstevenson (BOB member since 2006-09-06)