Download as doc, pdf, or txt
Download as doc, pdf, or txt
You are on page 1of 12

Evaluation Path How to create and use

The objective of this document to give practical scenarios on how Evaluation Paths can be created and used in our
applications. It also helps in understanding how the Evaluation Path fetches data from the backend so that we can
use Evaluation paths effectively in our applications.

Evaluation path is an instruction to the system to fetch the data recursively, according to the relationship between
the objects.

One or more relationships may be used in an evaluation path.


Creating Custom EVALUATION PATH:
We can create evaluation paths with alphanumeric names with a maximum of 8 characters starting with Z.
We will create an Evaluation Path below which will be used to find Org. Unit of a person based on USER ID which is
given as an input.(US -> P -> S -> O)
STEP 1: Go to T. Code SM30/SM31.
STEP 2: Enter Table name as T778a and Click on Maintain.

STEP 3: Click on New Entries.

STEP 4: Enter the name of EvalPath and the Evaluation Path Text. 


               Then Click on Save.

STEP 5: Now enter appropriate Relationships based on which you want to fetch the Data.
STEP 6: There is a Field Skip which has a Checkbox which should not be ticked if you want the Output of that
Relationship to be Included in the Final Result.

e.g.: in the above scenario Output from all the Relationships will be Included in the Final Result.
However, in the Scenario below, only the Output from Relationship “Belongs to” will be included in the Final
Result.

STEP 7: Finally Save the Evaluation Path.


Display Evaluation Path:
STEP1: Go to T. Code SM30/SM31.
STEP 2: Enter Table name as T778a and Click on Display.
STEP 3: Click on the Position Button at the Bottom of the Screen and enter the name of Evaluation Path which you
want to Display. Then Press OK.
STEP 4: Select the Evaluation Path you want to Display and Click on the Evaluation Path

STEP 5: Details of the Evaluation Path will be displayed.


Note: We can also Create/Display Evaluation Path using Transaction Code OOAW.
            It will take directly to Step 3.
How to execute Evaluation Path:
We will execute the Evaluation path created above using the Function Module “RH_STRUC_GET“:
DETAILS OF THE EMPLOYEE WHICH IS TAKEN AS EXAMPLE
Personnel No. 20001848
US(User ID)    RAIN
Position         40004241
Org. Unit        30001028
Example 1: When few Relationships/Lines have the “SKIP” column checked:

  
STEP 1: Go to T. Code SE37. Give the Function Module as RH_STRUC_GET and Execute.
STEP 2: Fill in the Required Entry Fields and press Execute
STEP 3: Results will be displayed.
   We get the Result in 3 tables as follows:

RESULT_TAB

RESULT_OBJEC
RESULT_STRUC

Steps to dry run Evaluation path yourself:


1). We provide the US as RAIN.
2). US is used to Calculate PERNR 20001848.
3). US (RAIN) goes into the Stack.
            PERNR 20001848 becomes current Object.
PERNR 20001848 is used to calculate Position 40004241
4). PERNR 20001848 goes into the Stack.
Position 40004241 becomes current Object.
Position 40004241 is used to search Org. Unit 30001028.
5). Position 40004241 goes into the Stack.
            Org. Unit 30001028 becomes current Object.
No more lines left for Org. Unit 30001028 to execute.
6). Control goes back to the Position 40004241.
No more lines left for Position 40004241to execute.
7). Control goes back to the PERNR 20001848.
            No more lines left for PERNR 20001848 execute.
8). Control goes back to the US (RAIN).
            No more lines left for US (RAIN) execute.
9). Execution of Evaluation path ends.
Current Object Relationship Used Resulting Object Result Current Stack
US -> RAIN 10:   US  A208  P P ->  20001848     ————– A. US -> RAIN

(LEVEL 1) (LEVEL 2)

P -> 20001848 10:   US  A208  P         NA      ————– A. P -> 20001848

(LEVEL 2) 20:   P     B008  S S ->  40004241 B. US -> RAIN


(LEVEL 3)

S -> 40004241 10:   US  A208  P         NA      ————– A. S ->  40004241

(LEVEL 3) 20:   P     B008  S         NA B. P -> 20001848

30:   S     A003  O O -> 30001028


C. US -> RAIN
(LEVEL 4)

O -> 30001028 10:   US  A208  P         NA O -> 30001028 A. S ->  40004241

(LEVEL 4) 20:   P     B008  S         NA B. P -> 20001848

30:   S     A003  O         NA


C. US -> RAIN
S ->  40004241 Nothing Left         NA O  ->  30001028 A. P -> 20001848

(LEVEL 3) B. US -> RAIN

C. P -> 20001848
P -> 20001848 30:   S     A003  O         NA O -> 30001028 A. US -> RAIN
(LEVEL 2)

US -> RAIN 20:   P     B008  S         NA O -> 30001028 ———————–

(LEVEL 1) 30:   S     A003  O         NA

*Levels mentioned above are the values which we will get in the column “Level” in the result table
“RESULT_STRUC”
Example 2:When none of the Relationships/Lines have “SKIP” column checked:

RESULTS will be as below:

RESULT_TAB:

RESULT_OBJEC:
RESULT_STRUC

Steps to dry run Evaluation path yourself:


1). We provide the US as RAIN.
2). US is used to Calculate PERNR 20001848.
            PERNR 20001848 is appended to Results.
3). US (RAIN) goes into the Stack.
            PERNR 20001848 becomes current Object.
PERNR 20001848 is used to calculate Position 40004241
Position 40004241 is appended to Results.
4). PERNR 20001848 goes into the Stack.
Position 40004241 becomes current Object.
Position 40004241 is used to search Org. Unit 30001028.
            Org. Unit 30001028 is appended to Results.
5). Position 40004241 goes into the Stack.
            Org. Unit 30001028 becomes current Object.
No more lines left for Org. Unit 30001028 to execute.
6). Control goes back to the Position 40004241.
No more lines left for Position 40004241to execute.
7). Control goes back to the PERNR 20001848.
            No more lines left for PERNR 20001848 execute.
8). Control goes back to the US (RAIN).
            No more lines left for US (RAIN) execute.
9). Execution of Evaluation path ends.
Current Object Relationship Used Resulting Object Result Current Stack
US  RAIN 10:   US  A208  P A. P ->  P -> 20001848 A. US -> RAIN
20001848
(LEVEL 1)
(LEVEL 2)

P -> 20001848 10:   US  A208  P         NA S ->  40004241 A. P -> 20001848

(LEVEL 2) 20:   P     B008  S S ->  40004241 P ->  20001848 B. US -> RAIN
(LEVEL 3)

S  -> 40004241 10:   US  A208  P         NA O -> 30001028 A. S ->  40004241
S ->  40004241

(LEVEL 3) 20:   P     B008  S         NA P ->  20001848 B. P -> 20001848

30:   S     A003  O O -> 30001028


C. US -> RAIN
(LEVEL 4)

O -> 30001028 10:   US  A208  P         NA A. O -> A. S ->  40004241


30001028
(LEVEL 4) 20:   P     B008  S         NA B. P -> 20001848
B. S   40004241
30:   S     A003  O         NA
C. US -> RAIN
C. P -> 
20001848
S ->  40004241 Nothing Left         NA O -> 30001028 A. P -> 20001848

(LEVEL 3) S ->  40004241 B. US -> RAIN

P ->  20001848
C. P -> 20001848
P  -> 20001848 30:   S     A003  O         NA O -> 30001028 A. US -> RAIN

(LEVEL 2) S ->  40004241

P ->  20001848

US -> RAIN 20:   P     B008  S         NA O -> 30001028 ———————–

(LEVEL 1) 30:   S     A003  O         NA S ->  40004241

P ->  20001848

NOTE:-  We can give any Object as Input which is specified in Obj. Type in the Evaluation Path.
In that scenario the Relationships which are Relevant to that Object will be executed first.

EXECUTE EVALUATION PATH USING T-CODE PPST:


We have a sample Evaluation Path: CACS_GP.
We have a sample Org. Structure:
We will try fetching the records using evaluation path “CACS_GP”:

This Evaluation path will return only Org. Units and Position as the above Org. Structure does not contain object
“S” and “BP”.
To execute go to T-Code PPST:
We can execute and get the Results as below:

We can also alter Display Depth (Default is Zero) and execute the Evaluation Path recursively up to the desired
level.
A. When we specify the Display Depth as ‘1’ then we get the below output:

            

B.   When we specify the Display Depth as ‘2’ then we get the below output:
            

C.   When we specify the Display Depth as ‘3’ then we get the below output:
           

Note: Evaluation paths can be tested and analyzed using the report RHSTRU00.
Note: For evaluating Evaluation Path there are few Function Modules in the Function Group:
“RH_STRUCTURE_GET”.
          Functions modules in this Function Group:
          a) HR_STRUCTURE_GET
          b) RH_STRUC_GET
          c)  RH_STRUC_GET_MULTIPLE_ROOTS
          d) RH_STRUC_SEARCH
    
Another important function group is “HRWPC_TO_DATA_SUPPLIER”.

You might also like