1. I have simplified this query for this forum, I tried union it does not work... Is there any way to do this query in Oracle 8.0.6 ?


SELECT mwebMatrix.Mat_Work_ID, mwebMatrix.Mat_Date, Currency.FX_Start_Date,
Currency.FX_Finish_Date, Null_Curr_Date.FX_Currency_ID,Currency.FX_Currency_ID
FROM mwebMatrix , mwebFXRate Currency, mwebWork Work_Link ,
mwebFXRate Null_Curr_Date
WHERE mwebMatrix.Mat_Work_ID = Work_Link.Work_ID
AND Work_Link.Work_Currency = Currency.FX_Currency_ID (+)
AND mwebMatrix.Mat_Date >= Currency.FX_Start_Date (+)
AND mwebMatrix.Mat_Date <= Currency.FX_Finish_Date (+)
AND Work_Link.Work_Currency = Null_Curr_Date.FX_Currency_ID (+)
AND Null_Curr_Date.FX_Start_Date IS NULL
AND Null_Curr_Date.FX_Finish_Date IS NULL
AND mwebMatrix.Mat_Category < 4000;


2. Also, in the following query I am trying to get that DECODE to work -

SELECT DECODE(1, (sign(mwebRes.Res_Entity_Type - 3) and sign(mwebRes.Res_Int_Ext7-10)), ('Mgr ' + Manager.Res_Name), ' ') Manager_Name
........
........

Just like this case statement -

Select
CASE WHEN mwebRes.Res_Entity_Type = 3
AND mwebRes.Res_Int_Ext7 <> 10 THEN ('Mgr ' + Manager.Res_Name)
ELSE ' ' END as Manager_Name


Any help please...

Thanks
Sonali

[Edited by sonaliak on 01-15-2002 at 02:10 PM]