Ansicht
Dokumentation

OIJP_PLANNING_TR - IS-OIL TSW - Planning proposal routine TR (Tgt. inventory Reorder )

OIJP_PLANNING_TR - IS-OIL TSW - Planning proposal routine TR (Tgt. inventory Reorder )

TXBHW - Original Tax Base Amount in Local Currency   TXBHW - Original Tax Base Amount in Local Currency  
This documentation is copyright by SAP AG.
SAP E-Book

Functionality

This routine tries to make proposals for the demand object as close as possible to the target inventory level for the dates determined by the re-order point being reached.

Once the internal tables have been filled by the pre-routine process and calculations, only columns RMRP and IMRP should be empty at this stage (IMRP may contain values from previous runs though).

The spreadsheet example in Appendix TR shows how the table would be be built for this particular routine.

The steps for the demand object are:

1. Check that the planning run flag (PLANFLAG) is not set.

2. Set variable Back_Date as day 0 or refresh BACK_DATE

3. Find the first incidence in the future after BACK_DATE in column column IBASE where the inventory is less than or equal to RE-ORDER point. Record the inventory figure in RMENG (local variable) Record the date in RDATE (local variable).

4. Check RDATE is less than or equal to END_DATE (calculated from SY-DATUM plus PLHOZ). If yes, continue. If no, then End.

5. Find the highest inventory in IBASE on or after RDATE. Record the inventory figure in HMENG (local variable) Record the date in HDATE (local variable)

6. Calculate MAXINV - HMENG > record result in PMAX (local variable). This will be the maximum allowed proposal for RDATE.

7. Calculate TARGET - RMENG = PTGT - this is what we would prefer to propose to meet target level.

8. Calculate lesser of PTGT and PMAX - put result in PRES.

9. Check that PRES is greater than or equal to 0,5 * INCLOT - this ensures that we have at least the minimum space for a proposal. If check OK, continue. If check fails, goto step 17.

10. Check RDATE record for an SFLAG setting > if marked, step 11. If not marked, step 13.

11. Incremental proposal to be made.

12. Calculate the incremental batch size for the proposal - PRES * INCLOT / INCLOT, round to the nearest INCLOT (e.g. req. 17, INCLOT 10, 17 * 10 / 10 = 17, round to the nearest 10 gives 20). Record value in PMRP (local variable).
If PMRP is greater than PMAX, PMRP = PMRP - INCLOT. If resulting PMRP is less than or equal to zero, skip to step 17. Else Skip to step 16.

13. New batch proposal to be made.

14. Is PRES greater then or equal to minimum batch size (MINLOT) ? ? If yes, step 15 If no, skip to step 17.

15. Calculate the batch size for this proposal- PRES - MINLOT = = remainder, then remainder * INCLOT / INCLOT, round to the nearest INCLOT, gives partial result, then MINLOT + partial result gives proposal (e.g. requirement 42, MINLOT 25, INCLOT 10 >> remainder = 42 - 25 = 17 >> partial result as before in step 6. = 10, then proposal = 25 + 10 = 35).


Record this value in PMRP. If PMRP is greater than PMAX, PMRP = PMRP - INCLOT. If resulting PMRP is less than MININV, skip to step 17. Else goto step16.

16. Place PMRP in RMRP on the RDATE, refresh values in IBASE.

17. Set BACK_DATE = HDATE.

18. Check BACK_DATE is equal to or less than END_DATE. If yes, loop around from step 3. If not, then End.

This routine is then looped around (steps 3 to 18) until the whole planning horizon has been covered, when one of the Back_Date versus END_DATE checks fails.

This is then the routine for planning using target inventory as the target and the re-order point method.

At the end of the planning routine above, the values in RMRP should be be added to the values in BASE and then both columns returned to OIJRD for the demand object, thereby overwriting the previous values.

Example

Notes

Further information





Parameters

I_PTYPEFLAG
T_OIJDOPL_TAB
T_OIJLOCMAT_WA
T_OIJTSMAT_WA

Exceptions

Function Group

OIJP

TXBHW - Original Tax Base Amount in Local Currency   CL_GUI_FRONTEND_SERVICES - Frontend Services  
This documentation is copyright by SAP AG.

Length: 4098 Date: 20240605 Time: 201437     sap01-206 ( 73 ms )