ORA-32035 considered a good thing?

I used to think that it was a good thing that this error was no longer raised in 11.2.

Now I’m not so sure.

SQL> select * from v$version;

BANNER
-------------------------------------------------------------------------------
Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production
PL/SQL Release 11.2.0.3.0 - Production
CORE    11.2.0.3.0      Production
TNS for Linux: Version 11.2.0.3.0 - Production
NLSRTL Version 11.2.0.3.0 - Production

SQL> with t as
  2  (select 1 col2 from dual)
  3  select * from t1;

COL1
-----
XXXXX

SQL> 

Doh!

Note to self: Clear up old Ts, T1s, T2s, etc straight afterwards.

I used to ALWAYS prefix my factored subqueries as subq_*.

This provides a compelling reason to continue that – not that it changes anything of course, just means I’m less likely to make such a typo.

About these ads

One Response to ORA-32035 considered a good thing?

  1. Dom Brooks says:

    Just to be clear what used to happen:

    SQL> with t as  
      2  (select 1 col2 from dual)  
      3  select * from t1;  
    select * from t1
                  *
    ERROR at line 3:
    ORA-32035: unreferenced query name defined in WITH clause
    
    
    SQL> 
    

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Follow

Get every new post delivered to your Inbox.

Join 75 other followers

%d bloggers like this: