Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> Re: Function problem - ORA-00907
Mando schrieb:
Did you try to execute your statement from execute immediate? Runs it without error? If errors occur, did you try to correct them? The problem with execute immediate is , that this statement will be parsed at runtime and nobody disallow you to write there anything you want, and be compiled without errors, they come first by execution...
At least with lines are suspect for me,
> 'SELECT SUM(RM.DURATION) - SUM(DECODE
> SR.DURATION_08,0,AA.DURATION,'',AA.DURATION,SR.DURATION_08))
if i understood correctly, what you want to do, i'd write it like:
SELECT SUM(RM.DURATION) -
SUM(DECODE(SR.DURATION_08,0,AA.DURATION,NULL,AA.DURATION,SR.DURATION_08))
Best regards
Maxim Received on Thu Sep 28 2006 - 05:00:02 CDT