I have a DBD::Oracle script which needs some help.

I have other DBD::Oracle scripts working ok, so I think
my installation is fine.  

This particular script attempts to integrate into a larger
application's job security features.

The application vendor supplied me with some wrapped procedures
and an outline for how to make this work.  And I used
it in the past.  But we recently moved to Oracle 11
and the script no longer works.

The tricky part uses a PL/SQL block to run a stored
procedure which figures out what "role" should be in play
for this particular user when running this particular job.
It then does a dbms_session.set_role, and away we go.

That all seems to work, as far as I can tell.  But
I am failing on a later prepared select of a table
for which I need that role's permissions.

The prepare statement occurs in the file after the
role setting statement.

My question is:  is there some forward-in-time
action going on which causes the prepare to happen
before my role is properly set?  And if so, how
do I defeat that feature?

Chris

Reply via email to