Thursday, October 25, 2018

Value Set: Security Type In Oracle Apps

Value Set: Security Type

Enabling security on value sets helps us to restrict values on concurrent program parameters.
Business Scenario:
Let’s say that we would like define Apple products with their codes in a independent value set which will be attached to a concurrent program as a parameter.
100: iPod Product Family             (Note: This is not a product but a product family)
101: iPod Classic
102: iPod Nano
200: iPhone Product Family      (Note: This is not a product but a product family)
201: iPhone 5S
202: iPhone 5C
203: iPhone 4S

Business Requirements:
1. Hide Single product from Concurrent Program parameter list of values  (Note: we will use Non-Hierarchical Security here)
2. Hide complete Product Family from Concurrent Program parameter list of values  (Note: we will use Hierarchical Security here)

Let’s start..
Define Value Set:
Navigation: Application Developer > Application > Validation > Sets
Enter information as shown below. First we will see how Non-Hierarchical Security feature will work.
4147_value set security type 1
Enter values for the above value set.
Navigation: Application Developer > Application > Validation > Values
Enter Value set name and click Find button
4147_value set security type 2
Enter Products information as shown below
4147_value set security type 3
Save it. click on “Values, Hierarchy, Qualifiers” tab
Select 100 (iPod Family)  and  200 (iPhone Family) as Parents.
Enter Level information as shown below. Here we are defining two levels of data. Level 1 is Product Family and Level 2 is Products.
4147_value set security type 4
Save it.
Ensure 100 (iPod Family) record is selected and then Click on “Define Child Ranges” button
4147_value set security type 5
Enter iPod products range here.
4147_value set security type 6
Save it. Close Child Ranges Window.
Select 200 (iPhone Family) and Go to Child Ranges again as shown below
4147_value set security type 7
Enter iPhone products range here and Save it.
Hmm. We are done with defining Value set and it’s values.

Define Security Rules:
Here, we will define security rules for the value set we have created.
Navigation: System Administrator > Security > Responsibility > Value Set > Define
4147_sec rule 1
Enter our value set name and click Find button to move on to next screen
4147_sec rule 2
Create a Security Rule as “iPhone 5S sold out” as shown below.
In “Security Rule Elements” Add a record of type “Include” and leave it blank. When we leave the From and To values blank it will include ALL values available in value set.
Add section row with type “Exclude” and enter iPhone 5S product code.
4147_sec rule 3
Save it. Click Assign button to link this rule with certain responsibility.
Link this rule to “System Administrator” responsibility as shown below.
4147_sec rule 4
Save it. Close it.
We will come back to this screen again later and define another rule to demonstrate Hierarchical security.
Currently we would like to test Non-Hierarchical security requirement.

Define Concurrent Program
Note: If you need detailed explanation about defining concurrent program and adding it to request group follow the below link
Navigation: Application Developer > Concurrent > Executable
4147_Conc execu
Navigation: Application Developer > Concurrent > Program
4147_Conc Prog
Click Parameters button and enter information as below
Make sure to check “Enable Security” option. Otherwise our security rules will not applied.
4147_Conc Prog Parameter
Add concurrent program to a request group.
Navigation: System Administrator > Security > Responsibility > Request
4147_conc prog req grp
Go to Submit Request screen and pull up our concurrent program
You can observe that iPhone 52 (202) is missing in the list of values. That is because of our security rule.
It’s working. :)
4147_conc prog subm 1

Let’s add one more security rule to test “Hierarchical Security” type.
Navigation: System Administrator > Security > Responsibility > Value Set > Define
Add new Rule “All iPods”. Now we would like to exlude all iPod products from the list.
Add one “Include” record with blanks and one “Exclude” record with 100 (iPod Family) in Security Rule Elements
4147_sec rule 5
Click Assign button and add this rule to a Responsibility as shown below.
4147_sec rule 6
We are not done yet but let’s go and check how our concurrent program parameter will behave.
4147_conc prog subm 2
In the above screen shot you can observe that only one record 100 (iPod Family) is missing but it still includes 102 and 103 which are iPod products.
Remember, initially we set security type on our value set to “Non-Hierarchical Security” ?
Now change it to “Hierarchical Security”
Navigation: Application Developer > Application > Validation > Sets
Query our value set and change security type as shown below.
4147_value set security type 8
That’s it.
Go to Submit Request screen and see how List of values will appear.
All iPods products are gone.
Here, We didn’t exclude each iPod product separately but instead we enable Hierarchical security and excluded parent itself there by removing child values also.
4147_conc prog subm 1
Done.

No comments:

Post a Comment

SQL Important Queries

  How to delete rows with no where clause The following example deletes  all rows  from the  Person.Person  the table in the AdventureWork...