on 11-28-2011 10:53 PM
Hi Gurus,
I am facing an issue with creating an Objects. Below is my code
case when IOWA.SHIPMENT.SHIPMENTTYPE = 'BOOKOUT' then 24+trunc(IOWA.FINDETAIL.BEGTIME, 'MM') -- 25th of Delivery Month
when IOWA.TRADE.TRADETYPE like '%SWAP' then 4+Add_months(trunc(IOWA.FINDETAIL.BEGTIME, 'MM'),1) -- 5th of Month after Delivery Month
when IOWA.TRADE.TRADETYPE = 'PHYSICAL COAL' then
case when IOWA.COUNTERPARTY.MASTERAGREEMENT = 'N' and IOWA.TRADE.INVFREQ = 'BI-MONTHLY'
then IOWA.FINDETAIL.BEGTIME+14 --14 days + Payment Terms
else -1+Add_months(trunc(IOWA.FINDETAIL.BEGTIME, 'MM'),1) -- End of Delivery Month + Payment Terms
end
+ case when IOWA.FINDETAIL.PAYMENTTERMS is not null then 'timecount' else 0 end
else -1+Add_months(trunc(IOWA.FINDETAIL.BEGTIME, 'MM'),1) -- End of Delivery Month
end
ERROR
Parse failed: Exeption: DBD,ORA-00932:inconistent datatypes: expected CHAR got NUMBER
Edited by: S.N... on Nov 28, 2011 5:02 PM
the case statement should get a result datatype as Char, this is was the error message sense..
But, there are some calculations in the code, use to_char to convert them into char. Hope this helps you,
thanks,
Cs
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
95 | |
11 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.