Skip to Main Content

SQL & PL/SQL

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!

Inserting rownum

994543Oct 13 2016 — edited Oct 13 2016

Hello,

after upgrade to 12c we have encountered a problem with following sql:

insert into test

(

id,

ruw_number

)

values

(

1,

rownum

);

Above statment will produce:

SQL Error: ORA-00976: Specified pseudocolumn or operator not allowed here.

00976. 00000 -  "Specified pseudocolumn or operator not allowed here."

*Cause:    LEVEL, PRIOR, ROWNUM, CONNECT_BY_ROOT, CONNECT_BY_ISLEAF or

           CONNECT_BY_ISCYCLE was specified at an illegal location.

*Action:   Remove LEVEL, PRIOR, ROWNUM, CONNECT_BY_ROOT, CONNECT_BY_ISLEAF or

           CONNECT_BY_ISCYCLE.

I have a bunch of old SQLs that are using same method and i was wondering if there is a work-around?

Thank you!

This post has been answered by Vysakh Suresh - 3035408 on Oct 13 2016
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Nov 10 2016
Added on Oct 13 2016
10 comments
3,410 views