Does anyone have a javascript example to group employees by process level and then push the information to a file?
ProcessLevel 100
Employee 1
Employee 2
Employee 3
ProcessLevel 200
Employee 4
Employee 5
Employee 6
I am not sure where the process level field is for employee; couldn't find it on my employee business class. But before going javascript route I would look and see if I can push it to a columnar table via replication set. Because then you could simply add an aggregate table and have the data built out the way you want it. IPA can just make a restful webservice call against the list you create.
Hey Russel,
Process Level is a S3 Field on the EMPLOYEE table and it's information is in the PRSYSTEM table. In GHR the HROrganization is basically the equivalent to a Process Level, where you're looking for HROrganizations one level down from the Company level.
You can shred this next part to pieces if you like, but off the top of my head I can think of 2 of many ways Jose could aggregate that data via Process Level / HROrganization
Use a Query node (Lawson S3) on the PRSYSTEM table, and inside the data loop, use another query that would then query the Employee table based on the node_ProcessLevel field data. This would step through each Process Level and query it's Employees in order.
Otherwise Jose can find an Employee set (S3) or List (GHR) that sorts on Process Level / HROrganization and base their query off of that.
We get PL from [PFIXREFVALUE]
[PFIXREFVALUE] C ON C.XRCCODE = 'ProcessLevelDepartment' AND C.XRCSOURCE = 'LTM' AND C.XRCDESTINATION = 'HRM'
If you are querying GHR and not S3, rather than using the employee business class you can use the workassignment business class and use a _filterstring=IsPrimary=true to get only the data attached to the primary workassignment. There is a field you can access called MappedProcessLevelDepartment that provides you with the S3 process level number^^S3 department number which you can parse using a substring.
As Russel mentioned you may want to explore using a replication set or possibly the file creation utility in GHR. Both I believe will allow you to drill farther into related business classes in GHR than IPA will and both can trigger an IPA flow after extracting the initial data. Russel has some very good KB articles on using IPA with replication sets.
@RusselThe data is from GHR and using PFIXREFVALUE to obtain the PL. I haven't used columnar table via replication set so that's something i'll need to explore. @jreese By any chance, do you have the KB articles on IPA w/Rep Sets?
KB 2059784