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: pragma RESTRICT_REFERENCES

Re: pragma RESTRICT_REFERENCES

From: Connor McDonald <mcdonald.connor.cs_at_bhp.com.au>
Date: Wed, 10 Jun 1998 18:49:40 -0800
Message-ID: <357F45C4.4D68@bhp.com.au>


Thomas Kyte wrote:
>
[snip]

Thomas,

Thanks for your detailed reply which has been most helpful...

Interestingly, further investigation to yield that the cause of my problem seems to be the use of PL/SQL table attributes...

Consider the following example...



SQL*Plus: Release 3.3.3.0.0 - Production on Wed Jun 10 18:40:32 1998

Copyright (c) Oracle Corporation 1979, 1996. All rights reserved.

Connected to:
Oracle7 Server Release 7.3.3.5.0 - Production Release With the distributed, replication and parallel query options PL/SQL Release 2.3.3.5.0 - Production

SQL> show user
user is "SYSTEM"

SQL> create or replace
  2 package demo as
  3 pragma restrict_references(demo,wnds);   4 function get_plsql_tab_index return binary_integer ;   5 pragma restrict_references(get_plsql_tab_index,wnds);   6 end;
  7 /

Package created.

=

SQL> create or replace
  2 package body demo as
  3 type defn_record_type is record (

  4        varcol varchar2(5),
  5        numcol number);
  6    type defn_tab_type is table of defn_record_type
  7        index by binary_integer;

  8 s_def defn_tab_type;
  9 function get_plsql_tab_index return binary_integer as  10 begin
 11 return s_def.prior(123123);
 12 end;
 13 end;
 14 /

Warning: Package Body created with compilation errors.

SQL> show errors
Errors for PACKAGE BODY DEMO:

LINE/COL
ERROR



0/0      PL/SQL: Compilation unit analysis
terminated                          
8/3      PLS-00452: Subprogram 'GET_PLSQL_TAB_INDEX' violates
its              
         associated
pragma                                                     

=

SQL> create or replace
  2 package body demo as
  3 type defn_record_type is record (

  4        varcol varchar2(5),
  5        numcol number);
  6    type defn_tab_type is table of defn_record_type
  7        index by binary_integer;

  8 s_def defn_tab_type;
  9 function get_plsql_tab_index return binary_integer as  10 begin
 11 return 123123;
 13 end;
 14* end;
SQL> / Package body created.

=

Thoughts anyone ???

Cheers
Connor

--



Connor McDonald
BHP Information Technology
Perth, Western Australia
"These views mine not BHP..etc etc"

"The only difference between me and a madman is that I am not mad." Received on Wed Jun 10 1998 - 21:49:40 CDT

Original text of this message

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