title: java.sql.SQLException: ORA-06550: line 1, column 13: After granting user permission to EXECUTE package
body: <p>I've spent months developing a JAVA application with a Oracle db back-end.  I am using Netbeans as my IDE and Oracle 12c on a laptop as my database. All PL/SQL has been compiled with no errors.</p>
  
  <p>After extensive testing (logged in as the schema owner), I attempted to add a user.  I created the user, logged in as SYS_DBA, using <code>CREATE USER E566299 IDENTIFIED BY tempPswrd</code>, then granted permission using <code>GRANT CREATE SESSION</code> and <code>GRANT EXECUTE ON C##FAI_CODE.FAI_ADMIN_PKG TO E566299</code> and received <code>Grant succeeded</code> confirmation.</p>
  
  <p>I login to my application, as this new user, with no errors using the following:</p>
  
  <pre><code>private static Connection getDbConn(String user, String password) throws SQLException{
          OracleDataSource ods = null;
          Connection dbConn = null;
          user = "c##" + user;
              ods = new OracleDataSource();
              ods.setURL("jdbc:oracle:thin:@//localhost:1522/orcl.global.ds.XXXXXXXX.com");
              ods.setUser(user);
              ods.setPassword(password);
              dbConn = ods.getConnection();
          return dbConn;
      }
  </code></pre>
  
  <p>Then it throws an error on the first package procedure call:</p>
  
  <blockquote>
    <p>java.sql.SQLException: ORA-06550: line 1, column 13:
        PLS-00201: identifier 'FAI_ADMIN_PKG.CHECK_USER_FOLLOWED' must be declared
        ORA-06550: line 1, column 7:
        PL/SQL: Statement ignored</p>
    
    <p>at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:450)
            at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:399)
            at oracle.jdbc.driver.T4C8Oall.processError(T4C8Oall.java:1017)
            at oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:655)
            at oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:249)
            at oracle.jdbc.driver.T4C8Oall.doOALL(T4C8Oall.java:566)
            at oracle.jdbc.driver.T4CCallableStatement.doOall8(T4CCallableStatement.java:210)
            at oracle.jdbc.driver.T4CCallableStatement.doOall8(T4CCallableStatement.java:53)
            at oracle.jdbc.driver.T4CCallableStatement.executeForRows(T4CCallableStatement.java:938)
            at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1075)
            at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:3820)
            at oracle.jdbc.driver.OraclePreparedStatement.execute(OraclePreparedStatement.java:3923)
            at oracle.jdbc.driver.OracleCallableStatement.execute(OracleCallableStatement.java:5617)
            at oracle.jdbc.driver.OraclePreparedStatementWrapper.execute(OraclePreparedStatementWrapper.java:1385)
            at faidb.FAIdb.checkSubscription(FAIdb.java:549)
            at faidb.faidbUI.run(faidbUI.java:186)
            at faidb.faidbLogin$3.run(faidbLogin.java:133)
            at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:311)</p>
  </blockquote>
  
  <p>I'm at a loss, I've tried every possible combination of grant wording, all caps, all lowercase, single quotes, double quotes, with the schema owner name prefix <code>C##FAI_CODE.FAI_ADMIN_PKG</code>, without <code>FAI_ADMIN_PKG</code>, nothing will allow this new user to execute the package.</p>
  
  <p>I've spent considerable time on this project and am near panic that no one will be able to use it.</p>
  
  <p>Question:</p>
  
  <p>Why can't my newly created user execute a package after being granted permission?</p>
  
  <p>Edit:</p>
  
  <p>I get a <code>NullPointerException</code> on the last line with the call to <code>rset.close();</code>, the result set is never initialized but it doesn't throw a <code>SQLException</code></p>
  
  <pre><code>public Vector&lt;String&gt; fillBox() throws SQLException, NullPointerException{
          CallableStatement callStatement = null;
          ResultSet rset = null;
          String fillBox = "{call fai_admin_pkg.get_end_item_pn(?)}";
          Vector&lt;String&gt; boxFill = new Vector&lt;&gt;();
          try{
              callStatement = conn.prepareCall(fillBox); 
              callStatement.registerOutParameter(1, OracleTypes.CURSOR);
              callStatement.execute();
              rset = (ResultSet) callStatement.getObject(1); 
              boxFill = buildRsVector(rset);
          }
          finally{
              callStatement.close();
              rset.close();
          }
          return boxFill;
      }
  </code></pre>
  
  <p>That is called here:</p>
  
  <pre><code>Vector&lt;String&gt; boxFill = new Vector&lt;&gt;();
              try{
                  boxFill = uiInst.fillBox();
              }catch(SQLException e){
                  JOptionPane.showMessageDialog(frame, e.getMessage());
              }catch(NullPointerException e){
                  JOptionPane.showMessageDialog(frame, e.getMessage());
                  e.printStackTrace();
              }
  </code></pre>
  
  <p>Here are my permissions as the new user...which do not include execute on the package??  I'm not understanding
  <img src="https://i.stack.imgur.com/9sstE.png" alt="no permission after granted"></p>