• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 721
  • Last Modified:

Assigning "HR:Query Only mode" profile in Oracle Apps

Hi All,

My requirement is to assign HR : Query Only mode profile to a user programmatically. I am using JAVA as programming language. Here are some details based on my investigation-

1. Information about the profiles is stored in the FND_PROFILE_OPTIONS table
and the association of a profile with a user is stored in the
FND_PROFILE_OPTION_VALUES table.
2. The FND_PROFILE package contains function("Save") for assigning a profile
to a user.
3. The "Save" function does not seem to work for profile
"PER_QUERY_ONLY_MODE" i.e the Query Only mode profile.

Save function however, works fine for profiles like ENABLE_SECURITY_GROUPS and few others. I am still unable to figure out why is the behaviour this way?
When the "HR : Query Only Mode" Profile is added from the UI, an entry
appears in the FND_PROFILE_OPTION_VALUES table. But the Save function of the FND_PROFILE package does not allow to add this entry!

Please help. Here is the code that is being used for the purpose-

declare
b boolean;
begin
FND_GLOBAL.APPS_INITIALIZE(0, 20420, 1);
//Initialize the flobal parameters : set the environment
b := FND_PROFILE.SAVE('per_query_only_mode', 'Y' , 'USER',1008682);
//Save profile inf
if b = TRUE then
dbms_output.put_line('success');
else
dbms_output.put_line('some error occured');
end if;
end;

Thanks,
Smita Raut
0
smita_raut
Asked:
smita_raut
  • 2
1 Solution
 
cj_1969Commented:
If it is working for other and just not this one profile, it might have some built in logic ... are there any other profiles associated to this user?  If so, then assigning a read-only profile wouldn't be an acceptable addition, the other profiles over ride it.  
Is this the only profile assigned to thsi user?

Another question ... are any other users using this profile?  Take a look at one of those IDs and see if there is something else that needs to be added to the account to make this work.

Any additional info you can provide would be helpful in figuring this out.
0
 
smita_rautAuthor Commented:
Yes. This is the only profile assigned to the user.
Also, I created a new user without any profiles and responsibilities assigned. Then  I tried assigning the profile(per_query_only_mode) to the user. This failed.

Note that "HR : Query Only Mode" Profile can be successfully added through the UI.

Here are some more observations :
1) The profile ENABLE_SECURITY_PROFILE has the application ID as 0 i.e FND(Oracle Application Library) and we are using the FND_PROFILE.Save method for assigning profile.
The profile PER_QUERY_ONLY_MODE has application id as 800 i.e PER(Human Resources)
Whether this can make a differnce??
ENABLE_SECURITY_GROUPS is listed in the document for "Profile Options For Oracle Applications Library) : (Link :http://demo.publicsoft.nl/pls/DEMO/fndgfm/fnd_help.get/US/FND/AUG00009365.HTM)  
 
 I tried to find out if there is a listing of Profile Options for HR application but could not find much in that respect.
 
Also I tried to check if there appears an entry in the PER_SECURITY_PROFILES_V and PER_SECURITY_USERS_V views, but could not find any.
I doubt that the FND_profile package may not work for PER profiles. But am not sure about this.

Thanks,
Smita
0
 
smita_rautAuthor Commented:
It was a stupid thing I realized. I was using per_query_only_mode instead of PER_QUERY_ONLY_MODE. Its case sensitive.

Since cj_1969 is the only user who responded to this query, I am rewarding the points to him.

Thanks,
Smita
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now