Precompiling With Oracle10g Fails With PLS-S-00801, INTERNAL ERROR [HSHUID:LU INVALID] (Doc ID 577830.1)

Last updated on JULY 05, 2017

Applies to:

Precompilers - Version: 10.1.0.2 to 10.2.0.2 - Release: 10.1 to 10.2
Information in this document applies to any platform.

Symptoms

  In the customer application there are 3 users, say USER1,USER2, USER3  in the same database.

USER2 creates a procedure which refers to USER3's table.  USER2 has been granted access to the table directly (i.e. not through a role).

USER2 grants execute on the procedure to a role to which  USER 1 belongs and USER1 is able to successfully execute the procedure through SQL*plus.

However if USER1 attempts to precompile a program that refers to the package (using SQLCHECK=SEMANTICS since they are making a pl/sql call), they receive an error:
e.g.

Error at line 109, column 2 in file invdb.pc
EXEC SQL CALL PG_INV_LOAD.FLIGHT_INS(:pcFlight, :RecStatus, :OraErr);
.1
PLS-S-00801, internal error [hshuid:LU invalid]
Error at line 109, column 2 in file invdb.pc
EXEC SQL CALL PG_INV_LOAD.FLIGHT_INS(:pcFlight, :RecStatus, :OraErr);
.1
PLS-S-00000, Statement ignored
Semantic error at line 109, column 2, file invdb.pc:
EXEC SQL CALL PG_INV_LOAD.FLIGHT_INS(:pcFlight, :RecStatus, :OraErr);
.1
PCC-S-02346, PL/SQL found semantic errors

Even though the errors are thrown, the precompiler does produce a file that can be successfully compiled and executed.
 
The issue can be replicated using the testcase.

Steps to reproduce the issue:

1. Login as sys user.
2. @drop_user_10g.sql
3. @cre_user_10g.sql
4. invdb.pc is the sample program and OraProc.cfg contains the precompiler options.
5. proc config=OraProC.cfg include=$ORACLE_HOME/precomp/public include=/usr/include include=$ORACLE_HOME/rdbms/public invdb.pc

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms