Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.misc -> Re: "order siblings by" problem with Oracle 9.0.1.1
Oleg Paraschenko wrote:
> Hello all,
>
> I'm using hierarchical query in Oracle 9.0.1.1:
>
> SQL> select x from (
> select 1 x from dual
> )
> start with x=1
> connect by prior x = x -1
> order siblings by x;
>
> X
> ----------
> 1
>
> But:
>
> SQL> declare
> v integer;
> begin
> select x into v from (
> select 1 x from dual
> )
> start with x=1
> connect by prior x = x - 1
> order siblings by x;
> dbms_output.put_line ('X is:'||v);
> end;
> /
> ERROR at line 9:
> ORA-06550: line 9, column 8:
> PL/SQL: ORA-30929: ORDER SIBLINGS BY clause not allowed here
> ORA-06550: line 4, column 2:
> PL/SQL: SQL Statement ignored
>
> Is it some problem with my SQL or is it problem with Oracle?
>
> Regards, Oleg
Check this out.
http://download-west.oracle.com/docs/cd/B10501_01/server.920/a96540/queries4a.htm#2054466
it should help.
Daniel Morgan Received on Fri Feb 14 2003 - 10:31:48 CST