Skip to Main Content

SQL Developer

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

XMLTable "For Ordinality" Bug

john2718Jun 26 2013 — edited Jun 26 2013

Using Oracle SQL Developer (3.2.20.09),

PL/SQL will compile and run the below code correctly.

However, Oracle SQL Developer incorrectly parses the tokens.

-The connections pane will incorrectly scope the "temp" and "ord" variables in the package's and not the procedure's scope.

-The connections pane will not recognize the procedure "example."

-The code editor pane will not generate "scope expand and collapse" nodes.

If you were to comment line 19 and and uncomment line 21, the engine would correctly parse.

This suggests a SQL Developer bug when parsing the xmltable "for ordinality" keywords.

create or replace

package body oracle_sql_dev_v3_2_20_09_bug as

procedure minimal_example

is

   temp varchar2(200);

   ord varchar2(200);

begin

   select

      text

     , ord

   into

      temp

     , ord

   from

   xmltable(

      'for $i in /somexml return /$i'

      passing xmltype('<somexml>some_text</somexml>')

      columns

         ord for ordinality,

         text varchar2(200) path '/somexml'

        --,ord varchar2(200) path '/somexml'

      );

end minimal_example;

procedure example

is

begin

   null;

end example;

end oracle_sql_dev_v3_2_20_09_bug;

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jul 24 2013
Added on Jun 26 2013
2 comments
754 views