Skip to Main Content

APEX

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

api call for get_user not consistently getting a set_user(value)

gpozApr 18 2013 — edited Apr 25 2013
All, I am having poor luck with another API function (having learned in earlier work that get_authentication_result doesn't provide anything but zero), perhaps I can get a 2nd pair of eyes on apex_custom_auth.get_user? I am trying to get the username of the person who signed into my custom authentication (which of course uses my tables for housing user information)

In my custom authentication function, which appears to do principally what I need, I have the following code:
apex_custom_auth.set_user(p_username);
debug_msg('get_user > '||apex_custom_auth.get_user||
    ' <-- apex_custom_auth.get_user');
which gives me this in the debug log:
0.05118	0.00032	get_user > admin <-- apex_custom_auth.get_user
In a process-after-submit (a Save button on Editing in a report & form page), I have the following code:
begin
    apex_debug_message.enable_debug_messages(p_level => 7);
    apex_debug_message.log_message(p_enabled => true,p_level => 3,
        p_message => 'ds ... <save> auth user='||apex_custom_auth.get_user);
dbms_application_info.set_client_info(apex_custom_auth.get_user);
end;
which gives me this in the debug log:
0.03965	0.00026	ds ... <save> auth user=nobody
I am more than a little puzzled why the function call works in one place, not in another? Perhaps the value is somehow reset? Is there another way I should be doing this?

Edited by: gpoz on Apr 18, 2013 12:13 PM

Edited by: gpoz on Apr 18, 2013 12:15 PM
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on May 23 2013
Added on Apr 18 2013
3 comments
275 views