Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

Leave Request Creation and ptreq_header table

partha_kar2
Active Participant
0 Kudos

Hi,

I am creating a leave request using the FMs

'PT_ARQ_REQUEST_PREPARE', 'PT_ARQ_REQUEST_CHECK' and 'PT_ARQ_REQUEST_EXECUTE'.

After that, it is generating a request ID, how do i check that the leave has been created in the system. I am presently cheking in the table ptreq_header, however the request ID is not present there? Am i on the right track? Please guide. How else can i find the request id and have proof that the leave has been created in the system?

Regards

Partha Kar

1 ACCEPTED SOLUTION

Former Member
0 Kudos

Hi Partha,

Please refer the below thread.

[http://help.sap.com/saphelp_erp60/helpdata/en/01/2bec40db328431e10000000a1550b0/content.htm]

[;

[http://www.sapfans.com/forums/viewtopic.php?f=11&t=318572]

For the parameter 'IM_COMMAND' of Function module 'PT_ARQ_REQUEST_EXECUTE' which command you are passing. table PTREQ_HEADER should have your leave request number.

Edited by: Prasath Arivazhagan on Apr 13, 2010 3:15 PM

5 REPLIES 5

Former Member
0 Kudos

Hi Partha,

Please refer the below thread.

[http://help.sap.com/saphelp_erp60/helpdata/en/01/2bec40db328431e10000000a1550b0/content.htm]

[;

[http://www.sapfans.com/forums/viewtopic.php?f=11&t=318572]

For the parameter 'IM_COMMAND' of Function module 'PT_ARQ_REQUEST_EXECUTE' which command you are passing. table PTREQ_HEADER should have your leave request number.

Edited by: Prasath Arivazhagan on Apr 13, 2010 3:15 PM

0 Kudos

Hi prasath,

I am passing the value 'EXECUTE_SEND' in the im_command of FM PT_ARQ_REQUEST_EXECUTE, and i am also passing the request id fetched from the previous FMs 'PT_ARQ_REQUEST_CHECK' and 'PT_ARQ_REQUEST_PREPARE', will that create the leave in the system ? The request ID is geting generated but it is not present in the ptreq_header table, what can be the possible reason?

Regards

Partha

0 Kudos

Hi Partha ,

you are passing the Correct command to the Function module.

-


*Using program RPTARQUIATEST create a request and check whether its updating table PTREQ_HEADER. if it works use the below points to fix your program issue.*

In Program RPTARQUIATEST in the line No 514 a perform request_create_antrag is used ( inside the When 102 statement ). its is used in standard for creating the leave request.

below Function modules are called in a same sequence in that above mentioned perform.

CALL FUNCTION 'PT_ARQ_REQUEST_PREPARE'

CALL FUNCTION 'PT_ARQ_REQUEST_CHECK'

CALL FUNCTION 'PT_ARQ_REQUEST_EXECUTE'

Please check the code of the perform of program RPTARQUIATEST and check whether you are missing something.

Hope it helps.

-


0 Kudos

Hi,

Could you please tell me the FMs for leave request modification?

Regards

Partha

0 Kudos

Hi Partha ,

There is a standard webservice ( ECC_EmpLeaveReqChgRC ) available in ECC side for changing the Employee leave request( TCODE - SPROXY ). Please get help from your PI guys to check whether it could be useful for you. if you need , you can replicate the same for your requirement. given below link will give you the details about the webservice.

[http://help.sap.com/esoa_erp2004/helpdata/en/44/786ebfd62455cee10000000a1553f6/frameset.htm]

Some classes related to Leave request

CL_PT_REQ_HEADER

CL_PT_REQ_ITEMS

CL_PT_REQ_REQUEST

CL_PT_REQUEST

CL_PT_REQUEST_TYPE

if you want to change the status of the leave request. you can refer the below thread.

[;