cancel
Showing results for 
Search instead for 
Did you mean: 

PCR Report

Former Member
0 Kudos

Hi,

Question 1:

We are in a process of building a report with the following fields.

Notification Number --Workitem ID

Is there any table / function module , using which i can retrieve the Workitem ids that are relevant for a Notification Number??

and also

Question 2:

We are building a similar report with the following details.

Notification Number -- Raised By -- Approved By -- Approval Date.

and this report will be restricted based on Authorization available for the user to access the "Personnel Number" or "Position" - for which the Notification has been raised.

Is there any function module/report , which will be able to give the following details based on authorization.

Any input for the above two issues are welcome.

Regards,

Raj

Accepted Solutions (1)

Accepted Solutions (1)

0 Kudos

For performance reasons and ease of producing reports from the contents of a PCR form, I created a custom table which acted as a PCR log. This log was used for other reasons (such as validating a person would not submit a new PCR when an unappoved PCR was still active). The PCR log had attributes such as notification number, scenario, object type ('P', 'S', depending on the form), object id (employee or position nr), completion flag (PCR processed fully?), rejection flag (PCR was rejected), company code (in our case we had multiple companies), personnel area, personnel sub area, initiator userid, initiator employee nr.

Any reports to be produced were produced directly from the PCR log.

The PCR workflow we were running was not the standard SAP one. We had a clone loosely based on WS50000042, WS50000042 and WS50000031. This one workflow determined the number of approvers required. (too much of a subject to go into at this time). However in this one workflow, the first step was to register a log entry in the custom PCR log, filling in the fields it could at that time based on the form contents. Then when the workflow completed (whether approved and fully processed or rejected), the very last step updated the log entry.

This approach is quite involved and you need to determine if this is the approach to adopt. I'm not sure how involved or important your PCR reporting requirements are. For reasons other than reporting, we adopted a single workflow for all the PCRs and a custom PCR log. As a result, our reporting of PCRs was easier.

Regards

Branco Marcina

Former Member
0 Kudos

Hi Raj,

First let me clarify my second question

"We are building a similar report with the following details.

Notification Number -- Raised By -- Approved By -- Approval Date.

and this report will be restricted based on Authorization available for the user to access the "Personnel Number" or "Position" - for which the Notification has been raised."

In the above

Raised by - corresponds to the Notification Initiator

Approved by - the Approver of the Notification

Approval Date - the Date on which the Notification was Approved.

As per requirement , we just running these report to send it to the HR Administrator

Hope this makes things clear.

Question:

With respect to your answer, i have the following doubts.

SWWWIHEAD--WI_RH_TASK - contains both Tasks and Workflow template numbers.

Now, how can we differentiate , which the latest work item corresponding to the workflow ??

Hi Branco,

Thanks for the suggestion.

We had actually thought of this method.

But one , problem we have is - we have mutlitple workflow templates.

and this method would involve changing multiple workflow templates.

Whether it is possible to implement the same in the Business Object Methods (Create , Edit) belonging to the delegated object of BUS7051?

Regards,

Raj

Former Member
0 Kudos

Hi Rajasekar,

Well, As such, we can get the Raised by, Approved By and Approval Date from Workflow Header table itself. You can get the emp num from Raised By user id(from COMMUNICATION INFTY-0001 Subty)

Regards

<i><b>Raja Sekhar</b></i>

Former Member
0 Kudos

Hi Raj,

Yes,

Raised by, Approved By and Approval Date are available in the Workflow Header table.

But they are available for a Workitem ID and not for a Notification Number.

That is the reason,we are facing problem in developing this report.

Raj

Former Member
0 Kudos

Hi Rajasekar,

Well, if you want the Notification related data and Adobe form data, you can get it using this FM-<b>ISR_SPECIAL_DATA_GET</b>.

Hope this should solve your problem.

Regards

<i><b>Raja Sekhar</b></i>

Former Member
0 Kudos

Hi Raj,

We are currently using ISR_SPECIAL_DATA_GET - to get the Form details.

But it gives the info - only for a specific "Notification Number"

Hope u now, understand the problem

ISR_SPECIAL_DATA_GET and View - VIQMEL - give me form info - for a specific "Notification Number"

and

SWWWIHEAD gives info for a specific "Workitem ID"

How will we - associate the both of the them??

Raj

Former Member
0 Kudos

Hi Rajasekar,

Well, I think I explained you before, anyways, get all the workitem details which are already processed based on the Standard Task TS50000075/TS50000058. Now, get the Container values using this Workitem number by the above mentioned function module - SAP_WAPI_READ_CONTAINER. Using this,you can get the Notification(BUS7051) Container value which has the Notification number as a key field. I think now, using this key field value, you can retrieve the Adobe form data.

Regards

<i><b>Raja Sekhar</b></i>

Former Member
0 Kudos

Any updates dude?

Former Member
0 Kudos

Hi Raj,

Yes.

U were right.

We checked the SWWWIHEAD table and found the Column - TOP_WI_ID - which can give me the top - Work Item id.

Using this top Work item ID - we would use the container read to read the Notification number for the particular work item id.

and using ISR_SPECIAL_DATA_GET we can access the Notification details.

and using the FM - ISR_SHOW_STATUS - we will be able to read the Status texts for the Notification number - corresponding to the work item.

Anyway, thanks for your solution.

Regards,

Raj

Answers (4)

Answers (4)

0 Kudos

Raj,

Yes, with multiple templates, the steps would have to be included into each one.

With regards to creating the log entry in the 'create' and 'edit' methods on a delegated BUS7051, I'm not sure this would work for fields within the form such as Company Code, Personnel area and subarea (these were fields in our PCR forms). We required the values on the log entry for those fields when the PCR was submitted (i.e. first step in the workflow).

Just another point to keep in mind, with regards to knowing who the approver is, are all your PCR scenarios for one approver, or for multiple approvers? In the case of multiple approvers, is your report looking to list just one or all the approvers?

Regards

Branco

Former Member
0 Kudos

Hello Rajsekar,

Well, here are my inputs.

1) Please get the Workitem number from SWWWIHEAD based on your template number(or use FM-SAP_WAPI_WORKITEMS_BY_TASK) and get the respective container element values using the FM -SAP_WAPI_READ_CONTAINER and get the Container element of type BUS7051 and get its key field which is your NOTIFICATION NUMBER.

2) For your second report, I have few clarifications that needs to be cleared before answering this part. You say, Raised By, Approved By, Approval Date ? Do you mean the fields that are present inside the Adobe form? Or are these Workflow Intiator, Worklow Agent, Workflow Exceution Dates ? Can you make us more clear?

Regards

<i><b>Raja Sekhar</b></i>

Former Member
0 Kudos

Hi Rajasekhar,

I have seen your reply.

But I want the reverse process.

I mean I'll input the notification number and I want the Work item id.

In your answer you said SAP_WAPI_READ_CONTAINER reads the work item id and gives the obj id which is the notification number.

I need the reverse. Is there a function module.

Thanks.

Former Member
0 Kudos

Hi Rajasekar

I have had some success using the function SAP_WAPI_WORKITEMS_TO_OBJECT in similar cases where I can identify the BOR Object instance and need to find what are the effected items.

Regards

Gareth

former_member184112
Active Contributor
0 Kudos

Hi,

Could you please clarify from which module you need all these???

Thanks and Regards,

Prabhakar Dharmala

Former Member
0 Kudos

Hi Prabhakar,

PCR - Personnel Change Requests which are part of the HR module.

Hope now it is clear.

Regards,

Raj

former_member184112
Active Contributor
0 Kudos

Hi,

Ok..yes you already mentioned in subject PCR report..

Please check this Standard one: You can get all informations on this

Workflow template WS50000041

Thanks and Regards,

Prabhakar Dharmala