Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: Altering the ORDER BY clause based on a parameter
In article <4740a498$0$19197$426a74cc_at_news.free.fr>, says...
>
Hi Michel, this is what I thought but it runs into problems where the p_order_by param's data type differs from that of the column on which the order by is to be performed. Get runtime errors such as
ERROR at line 1:
ORA-01722: invalid number ORA-06512: at "WD.MYPROC", line 4 ORA-06512: at line 1
Any ideas? Also I would need to be able to specify the direction ASC or DESC of the query results.
Dynamic SQL the way to go?
-- jeremyReceived on Mon Nov 19 2007 - 03:00:47 CST
![]() |
![]() |