SQL Language (MOSC)

MOSC Banner

ora-918 during select for update using alias in 11.2

edited Apr 1, 2010 9:46PM in SQL Language (MOSC) 3 commentsAnswered

Hello all,
the following statement is using aliasing in a select for update query:

select ....
from table1 alias1
 inner join table2 alias2 on alias1.t2_id=alias2.id
 inner join table3 alias3 on alias2.t3_id=alias3.id
where ...
order by ...
for update of alias1.id;

In pre-11.2 versions this was working.
In 11.2 the select fails with ora-00918.


When changing the statement manually to

select ....
from table1 alias1
 inner join table2 alias2 on alias1.t2_id=alias2.id
 inner join table3 alias3 on alias2.t3_id=alias3.id
where ...
order by ...
for update of table1.id;

it works in 11.2 as well.

Howdy, Stranger!

Log In

To view full details, sign in to My Oracle Support Community.

Register

Don't have a My Oracle Support Community account? Click here to get started.

Category Leaderboard

Top contributors this month

New to My Oracle Support Community? Visit our Welcome Center

MOSC Help Center