cancel
Showing results for 
Search instead for 
Did you mean: 

Requirements Date not always getting populated

Former Member
0 Kudos

Hi,

Our requirement is to populate requirements time in an STO based on a custom table.

The following code is written in user-exit EXIT_SAPAPO/SAPLCIF_PU_001.

1. If IT_INPUT-ATPCAT matches with the one maintained in a custom table then

2. Fetch the time from a custom table based on IT_INPUT-PLANT.

3. Convert time stamp in IT_INPUT-REQ_TSTAMP using timezone into date and time

4. Now replace the time from step 3 with the one determined in Step 2.

5. Convert date and time from step 4 into time stamp and pass it to IT_INPUT-REQ_TSTAMP. I also populated IT_INPUT-REQ_TSTAMP with 'X'.

The problem is, it is working for some plants and not for other plants. For example, it is working for an STO with supplying plant A and receiving plant B. But it is not working for an STO with Supplying Plant B and Receiving Plant A. I debugged it and saw that the code inside the USER-EXIT is working fine for any plant but when the STO is viewed in APO Product View (/SAPAPO/RRP3) the requirements time is shown as '00:00:00'. I am not sure where it is going wrong.

Thank you.

Accepted Solutions (0)

Answers (1)

Answers (1)

wilian_segatto
Contributor
0 Kudos

Hi!

Put a breakpoint on statement "exec" or in Function Module /SAPAPO/OM_ORDER_CHANGE and check what's being saved.

If you suspect it is a display issue, type gt_io in the transaction field in /SAPAPO/RRP3, get the INTERNAL_ORDER GUID for the affected order and run FM /SAPAPO/OM_ORDER_GET_DATA in /SE37 for fetching the order details.

Best regards,

Will

wilian_segatto
Contributor
0 Kudos

Did that help?