My Oracle Support Banner

ORA-28113 When A Policy Predicate Is Fetched From A Context (Doc ID 331862.1)

Last updated on FEBRUARY 03, 2019

Applies to:

Oracle Server - Enterprise Edition - Version: 8.1.7.4 to 11.2.0.1.0 - Release: 8.1.7 to 11.2
Information in this document applies to any platform.
Checked for relevance on 27-Aug-2010

Symptoms

ORA-28113 is returned intermittently from your application. You follow the diagnostic steps in note 250094.1

and you discover from the trace file the predicate is truncated at about 256 characters. For example you get the error

ORA-01756: quoted string not properly terminated

Or any other SQL syntax error resulting from the truncate of the predicate string.

Changes

In the design of your policy function, you derive the value of the predicate string directly from a namespace (context) with a construct similar to the following:

 
FUNCTION F_PREDICATE (obj_schema VARCHAR2, obj_name VARCHAR2) RETURN
VARCHAR2
IS
iGetSTRING VARCHAR2(4000);
BEGIN
iGetSTRING := SYS_CONTEXT('SECURITY_CONTEXT','SECURITY_ATTRIBUTE');

RETURN iGetSTRING;
EXCEPTION
WHEN OTHERS THEN
RAISE_APPLICATION_ERROR (SQLCODE, SQLERRM);
END F_PREDICATE;


Cause

To view full details, sign in with your My Oracle Support account.

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


In this Document
  Symptoms
  Changes
  Cause
  Solution
  References

My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.