title: How do I execute a procedure in a package I just created in another schema?
body: <p><strong>Setup:</strong>  I have two trees of scripts that run on Oracle 11g - one set ensures the correct instance configuration and that all of the DBA proxy accounts are there to connect to the dbadmin account, and the other set builds and modify our database environments.</p>
  
  <p><strong>Problem:</strong>  Proxied in to the DBADMIN account, the second set of scripts runs just fine, <em>except</em> for one piece:  the data pre-population.  The procedures that allow loading of the data create under the appropriate schema just fine, and the script that loads the data runs just fine if ran as SYS AS SYSDBA, but when I try to run it as DBADMIN <em>immediately after creating the procedure it calls</em> I get <code>PLS-00904: insufficient privilege to access object schema.package</code> for every call.  I can't even have the script <code>GRANT EXECUTE ON schema.package TO DBADMIN</code> because that (of course) generates the expected <code>ORA-01749: you may not GRANT/REVOKE privileges to/from yourself</code> error.</p>
  
  <p><strong>To put it more simply:</strong></p>
  
  <p>(as DBADMIN:)</p>
  
  <pre><code> ...
  CREATE OR REPLACE PACKAGE BODY other_schema.package_name IS
   ...
  PROCEDURE add_data(...)
   ...
  </code></pre>
  
  <p>(succeeds, and is testably working)
  (later, in another script called by the same parent script, still as DBADMIN:)</p>
  
  <pre><code>BEGIN
     other_schema.package_name.add_data(...);
     ...
  </code></pre>
  
  <p>(raises the PLS-00904 given above - Insufficient privilege)</p>
  
  <p>Any ideas on how I can give the DBADMIN account EXECUTE access to a package that it hasn't created yet, or how DBADMIN can get access itself without stopping the whole script stream, log out and back in as SYS AS SYSDBA to GRANT it?  (The whole point here is to have ZERO manual steps beyond the initial "run this script tree", and to only have one time ever up front when the SYS AS SYSDBA is ever used.)</p>