Queries Against Tables Protected by OLS Are Erroring Out

(Doc ID 577569.1)

Last updated on OCTOBER 25, 2017

Applies to:

Oracle Server - Enterprise Edition - Version: to
This problem can occur on any platform.


After installing any patch which changes the OLS packages the queries against tables protected by OLS are failing with the following errors:

ORA-06553:PLS-306: wrong number or types of arguments in call to 'TO_TAG'


ORA-04045:errors during recompilation/revalidation of PUBLIC.RECYCLEBIN
ORA-04064:not executed, invalidated
ORA-04064:not executed, invalidated package body "LBACSYS.LBAC_EVENTS"
ORA-06508:PL/SQL:could not find program unit being called: "LBACSYS.LBAC_EVENTS"


This  can happen  in an environment where the OLS component is at version whereas the rest of the database components are at version The DBA_REGISTRY view is wrongly listing the OLS component as being at version so using the output from DBA_REGISTRY as an evidence that OLS is at version is not enough. One can get into this situation if OLS is enabled in a database without re installing the patchset.

It is possible to have the same symptoms in environments which do not fall in the above scenario, however the solution described below will solve those issues as well. 


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