Re: Asked and answered... ORA-1445

  • From: Saibabu Devabhaktuni <saibabu_d@xxxxxxxxx>
  • To: free <oracle-l@xxxxxxxxxxxxx>
  • Date: Fri, 7 Dec 2012 00:52:35 -0800 (PST)

John,
The reason why you got ORA-1445 is because you didn't use alias for rowid and 
Oracle parser interpreted it as you trying to fetch pseudo rowid from the 
inline view and hence it bis subjected to key preserved table requirement.

In the below query, change "select x.rowid from x_test_a x, x_test_b b" to 
"select x.rowid rid from x_test_a x, x_test_b b", and "where x.rowid = a.rowid" 
to "where x.rowid = a.rid", then it should work just fine.

create table x_test as
with a as (select x.rowid from x_test_a x, x_test_b b where x.bar =
b.bar)
select foo from a, x_test_a x where x.rowid = a.rowid;

Thanks,
Sai
http://sai-oracle.blogspot.com

--
//www.freelists.org/webpage/oracle-l


Other related posts: