Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: "identifier must be declared"

Re: "identifier must be declared"

From: Alexey Sergeyev <saefido7_at_devexperts.com>
Date: Tue, 3 May 2005 17:22:13 +0400
Message-ID: <d57tud$1lbi$1@news.rtcomm.ru>

    IMHO, it's impossible. Compiling is the procedure for checking an object for its semantical+logical consistency (with all dependencies etc..). Without undelaying tables you procedure will never be logically  consistent - it will be always INVALID. So you can't COMPILE it. But sure you can CREATE that procedure, because that tables absence doesn't prevent CREATION of a procedure.
SQL> Create or replace function a1 return number   2 as
  3 i number;
  4 begin
  5 select b1 into i from nonexistent_table;   6 return i;
  7 end;
  8 /

Warning: Function created with compilation errors

SQL> show errors
Errors for FUNCTION STRADMIN.A1:

LINE/COL ERROR

-------- -----------------------------------------------
5/25     PL/SQL: ORA-00942: table or view does not exist
5/3      PL/SQL: SQL Statement ignored

Alexey Sergeyev

"Vince .>" <vincent@<remove> wrote in message news:tkte71596cka5rck25cdh8mr32i8vum4ek_at_4ax.com...
>
> Hi there!
>
> I am writing some procedures wich refer to non-existing tables yet..
> so, when I try to compile, it gives me : "PLS-00201: identifier
> 'your_table' must be declared"
>
> How could I prevent this without creating those tables to not stop
> compiling procedure..
>
> thanks a lot
>
> Vince.
Received on Tue May 03 2005 - 08:22:13 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US