Creation of SNP planned order based on PDS
Hi,
I'm a APO developer and I have the following problem:
I would like to create a SNP planned order based on a PDS (like e. g. in the planning book when you input a number into a cell in the "Production (Planned)" line).
Up to now I've only managed to create such an order without using the PDS.
Can you name me a function module which allowes me to do that?
Thanks in advance.
Hi,
I've now managed to create this kind of order.
I set a breakpoint at the function module /SAPAPO/DM_PROD_ORDER_CHANGE and checked how it was filled in the planning book.
For those who want to know:
INCLUDE /sapapo/constants_om.
CONSTANTS:
lc_order_type_1f TYPE /sapapo/om_order_type VALUE '1F'.
DATA:
ls_prod TYPE /sapapo/msnp_prod,
lt_prod TYPE /sapapo/msnp_prod_tab,
ls_sources TYPE /sapapo/sources,
lt_sources TYPE /sapapo/sources_tab,
lv_matid TYPE /sapapo/matid,
lv_locid TYPE /sapapo/locid,
lv_vrsioid TYPE /sapapo/vrsioid,
lv_tstfr TYPE /sapapo/timestamp,
lv_tstto TYPE /sapapo/timestamp,
lv_simsession TYPE /sapapo/om_simsession.
lv_vrsioid = '000'.
* Create SimSession
CALL FUNCTION '/SAPAPO/TSIM_SIMULATION_CONTRL'
EXPORTING
iv_simversion = lv_vrsioid
iv_simsession = lv_simsession
iv_simsession_method = 'N'
iv_perform_commit = space
EXCEPTIONS
lc_connect_failed = 1
lc_com_error = 2
lc_appl_error = 3
multi_tasim_registration = 4.
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
* Get PDS
CALL FUNCTION '/SAPAPO/MSDP_SNP_PPM_VALIDITY'
EXPORTING
iv_vrsioid = lv_vrsioid
iv_matid = lv_matid
iv_locid = lv_locid
iv_tstfr = lv_tstfr
iv_tstto = lv_tstto
iv_planstart = lv_tstfr
iv_planend = lv_tstto
CHANGING
ct_sources = lt_sources
EXCEPTIONS
wrong_interface = 1
error_occured = 2
OTHERS = 3.
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
READ TABLE lt_sources INTO ls_sources INDEX 1.
ls_prod-version = lv_vrsioid.
ls_prod-matid = lv_matid.
ls_prod-locid = lv_locid.
ls_prod-plobid = '9AMALO'.
ls_prod-tstmp = lv_tstfr.
ls_prod-catgr = 'PP1'.
ls_prod-categ = 'EE'.
ls_prod-categ_prku = 'EE'.
ls_prod-categ_prse = 'EL'.
ls_prod-kz_prod = '9APPROD'.
ls_prod-kz_prku = '9APPROD'.
ls_prod-kz_prse = '9ADMDSE'.
ls_prod-produ = '1000'.
ls_prod-proid = ls_sources-trpid.
ls_prod-mosta = gc_new.
ls_prod-order_type = lc_order_type_1f.
ls_prod-is_fixed = 'X'.
ls_prod-snp_is_header = 'X'.
APPEND ls_prod TO lt_prod.
CALL FUNCTION '/SAPAPO/DM_PROD_ORDER_CHANGE'
EXPORTING
ic_database = 'LC'
ic_application = '4'
iv_simsession = lv_simsession
it_prod = lt_prod
iv_netch = 'X'
EXCEPTIONS
material_not_supplied = 1
location_not_supplied = 2
OTHERS = 3.
* Merge simulation version (to commit order changes)
CALL FUNCTION '/SAPAPO/TSIM_SIMULATION_CONTRL'
EXPORTING
iv_simversion = lv_vrsioid
iv_simsession = lv_simsession
iv_simsession_method = 'M'
EXCEPTIONS
lc_connect_failed = 1
lc_com_error = 2
lc_appl_error = 3
multi_tasim_registration = 4
target_deleted_saveas_failed = 5
OTHERS = 6.
IF sy-subrc <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
Similar Messages
-
BAPI to create SNP planned order based on start date
Hi,
I am looking for a BAPI to create SNP planned order based on the order start date. There is BAPI BAPI_MOSRVAPS_CREATESNPORDER which can be used to create SNP planned order based on the end date but not based on the start date.
Also would be great if some one can share how do they create SNP Planned orders using BAPI BAPI_MOSRVAPS_CREATESNPORDER in case if GR processing time is defined in the product master and workdays for GR to be respected according to the calendar.
Regards,
VenkatHello Mr.Venkat,
Hope you recognize me.
Please check out the BAdi below.
BAdi - APO_BAPI_BUS10503 (this is the BAdi for ManufactOrderAPS BAPI which contains the SNPorder BAPI)
Method - CHANGE_SAVEMULTIPLE2
In this method parameter IT_ORDER_HEAD contains Order start date input option.
For GR time please check this (not sure if it will help).
Same BAdi/ same method
Parameter IV_PLANNING_MODE_USAGE contains field PLANNING_MODE.
Value 1 for PLANNING_MODE corresponds to "Observance of parameters from the product master".
This may make it respect the GR time in product master
Good luck with the above
Regards,
Ashok -
Creation of SNP Planned Orders using Optimizer
Dear Experts .....
I am facing some problems while creating SNP Planned orders using Optmizer ( Discret Optimization).....
For eg.
I am using 3 months horizon ... the first two months is daily buckets with 12 hours capacity each one and the last month is weekly buckets.
The product minimun lot size exceed the daily capacity .... this way planned order have been created in the weekly buckets at the end of the horizon.
I need the system to create orders in the correct date avoiding use of safety stock .....
Regards
MauricioThose other 2 settings was already done .....
It is still not working .... iI am receiving the following message ...
Production process model/PDS 00000000000001011301001 S: Cannot be executed
Message no. /SAPAPO/SNPOPT159
Diagnosis
Production process model 00000000000001011301001 S at location 0100 is intended for cross-period lot size planning. It can be started in bucket 20110404->20110404. However, it does not then end in the same bucket.
Thanks for your effort trying to help me with this issue. -
Creation of SNP planned order in Monthly Bucket though CTM plan
Hi,
Can anyone advise how to aggregate the SNP planned order generated after CTM run in Monthly bucket.
Can it be done through customizing?
Regards.
Punitsystem switches over to external procurement in place of in house production only when you use optimizer.
Heuristic will do this only if there is a SNP PPM/PDS and the resource calendar prevents timely production.
Regards
Nitin Thatte -
Deletion and creation of SNP Planned order
Hi,
I need to delete the SNP Planned order i.e ATP category of type 'EE' and I have to create the orders of ATP category EE through programetically. Please let me know if any BAPI's or Function modules are existed for the same.
Appriciate your help.
Regards,
RatnaHi Ratna.
To delete orders in SNP use transaction:
/SAPAPO/RLCDEL
BAPI to create planned orders:
BAPI_MOSRVAPS_SAVEMULTI3
There is also a BAPI to delete planned orders if this is more suitable.
BAPI_MOSRVAPS_DELEMULTI
Hope this helps, M -
Unable to convert SNP planned order to PP/DS planned order in RRP3
Hi,
This is an in-house production scenario. SNP planned order are created based on forecast, now i want to convert those SNP planned orders to PP/DS planned orders in product view. While converting i am getting the following error message.
Conversion canceled with error
Message no. /SAPAPO/RRP707
I have checked the SNP, PP/DS PDS, it looks good.
Regards,
LVHi Lingaiah,
Conversion SNP -> PP/DS SAP002 is scheduling heuristic
Heuristic for Conversion SNP->PP/DS as SAP_SNP_SNGL used for order conversion.
Regards,
R.Brahmankar -
Creating SNP planned order using ''BAPI_MOSRVAPS_SAVEMULTI3'
Hi Experts,
I am new to SAP-APO, kindly clarify my question. I am using 'BAPI_MOSRVAPS_SAVEMULTI3' with source of supply PDS for creating SNP planned order by passing 'EE' in the table parameters 'ORDER_HEAD-MASTER_ATPCAT'. It is creating a planned order which is PPDS planned order with number range starting from '1000...' rather than creating SNP planned order with number range starting from '8000..'. Please let me know what might be the reason for the BAPI misbehaving incorrectly. Also kindly let meknow what are specific parameters to pass to above bapi to create SNP planned order.Hi,
The BAPI BAPI_MOSRVAPS_SAVEMULTI3 is used for creating PPDS inhouse orders.
You will have to use BAPI_MOSRVAPS_CREATESNPORDER for SNP inhouse orders creation from SNP PPMs( there is no explict mention of SNP PDS- you may please check).
Regards
Datta -
How to Change Component on a SNP Planned Order ( Just 1 time )
Hello,
We are trying to change a component on a SNP Planned Order just 1 time.
So we do not want to change the PDS since this is one time change only.
We tried changing it in R/3. Once we do that, R/3 shows new component but APO still shows dependant demand on old component ( May be because APO SNP Planned order is still connected with the PDS ) .
Then we went to APO and tried to change the component in /sapapo/rrp3. Here you can delete the old component but doesn't let me add new component.
Next thing we tried was to convert it to PPDS Order. Once converted, we went to change mode and tried to remove old component and add new component. It lets me do this. Only issue with this route is that, it puts correct start and end dates on the order dependning on the order quantity and so order moves the dates which we do not like.
Is there any other better way to fix this issue ?.
Thanks.
Ketan Doshi.This being a very unique requirement, I would use one-off approaches usually not followed. You may need to explore the use of BAPI BAPI_MOSRVAPS_CREATESNPORDER. This will help you point the source of planned order to a PPM or a PDS that you may want to create in APO system on a one-off basis. PPMs can be maintained in APO, however PDS are usually CIFed from R3. You can try to create PDS (based on the new component) in APO system only using backend tables. Try do some little research on /sapapo/curto tables to create the PDS in APO. Then use the BAPI to point the source to this new PDS. (better you also try the PPM approach since there are no issues keeping the PPM in APO)
-
SNP Planned order - Doesnt get the complete BOM when CIFd to ECC
Hello,
When we create SNP Planned order in APO and sent to ECC, the Planned order doesn’t get the complete BOM, it works for the most part, except if we have Materials from multiple plants within the same BOM (sourcing from multiple plants).
Do we have to do any separate Configuration for this scenario?
We are planning only the End item in SNP, and we are generating the production version and PDS transfer to APO. We are not transferring all the materials to APO.
if we go to the Change mode of the Planned order in ECC and re-explode the BOM, I get all the components from the BOM, its just that when the planned order gets created thru the CIF we have this issue.
Any help would be appreciated.
Regards
GkHello Marius
Thank you for your quick response.
I looked at the SAP note you mentioned, the description seems to be matching with the issue we are having. Recently we had SNC implemented, and the note states that that can be the case why the components are getting deleted during planned order creation.
The only thing about this note is its very old, and we are having the SAP 6.0 and SCM 7.2 ,
Do you think this would be still applicable.
I will look into the details and let you know whether the note is applicable for us.
Regards
Gk -
Factors influencing creation of a planned order
Hi,
What are the factors that lead to creation of a planned order during a Heuristic run?
When does a system decides to create a planned order? at what stock level? and how is the planned order qty. decided?
I have a material in a location that has planned orders generated.
I am trying to understand why the system created this order?
There is no safety stock, safety days supply or target days supply or rounding profile defined in Product master in Lot size tab.
Lot sizing procedure is by period (Days) - number of periods = 1
Lot size strategy blank
When I look at the product view,
the requirements pileup with category SNP:DepDmd and after some days, a planned order is generated for some qty.
I am trying to understand when the system determines to create a planned orders? What is the upper limit of the demand when the system generates a Planned order?
In the system, some times the planned order is generated when the stock is at 2,484.567 PCs some times 13.645 PCs.Planned Order creation is based on a MRP calculations (net requirements planning) and ofcourse APO takes into account various factors such as min or max lotsizes, time-phasing requirements, calendars or safety stock requirements etc.
Keeping aside the safety stock complexity in your situation, some of the reasons why a planned order could be created even with lots of stock in hand could be:
1. Check projected stock on hand may be going down under 0 if the planned order were not created on time
2. There would be a window of time for planned order creation due to production and other calendars that if lost would force projected stock in hand below 0
3. the stock in hand is blocked stock not useful for planning
4. Issues with SNP planning book configuration where key figures are not mapped correctly to ATP categories. Makes sense to double check in Product View
5. Due to min lot size being high, it might appear that system is over planning production. -
To build query related to SNP: Planned Order
Hi,
System: SCM 5.0
Scenario: SO received at plant and planning creates PR against SO at plant and accordingly SNP:Planned Order at Vendor location. If SO is cancelled/deleted (manually), sometime only the PR gets cancelled/deleted (automatically during planning run) but corresponding SNP:Planned Orders still remains at vendor location and so the dependent requirements. PR and Planned Orders are pegged to SO so one-to-one relation is maintained.
I could not find any reason why system is not deleting Planned Order at vendor location despite SO and PR is deleted at plant location. So I am planning to build query where SNP:Planned Orders are not pegged to any PR or SO.
Can anyone help with list of SNP:Planned Order tables so that I can build query around it to identify ghost Planned Orders.
Hope I was clear with my query but let me know if any further information is require.
Thanks and regards,
DevangHI Marius,
Sorry for delay reply.
I was working on on some other more critical issues to business.
Finally we decided to built report to identify obsolete Planned Orders for which PR is not available in ordering plant. I have listed below logic for that report:
Get Location ID from table /SAPAPO/LOC based on Location entered in selection screen
Get PEGIDs from FM /SAPAPO/DM_MATLOC_GET_PEGIDS based on IV_SIMID as 000 and location id from step 1
In FM /SAPAPO/OM_PEG_CAT_GET_ORDERS, use SIMVERSION as 000 and in Import Para IS_GEN_PARAMS insert all PEGIDs from step 2.
From Export Para ET_PEG_INPNODE take From_OrderID and store in internal table.
Execute T.Code /SAPAPO/RRP4 with following selection (Use Selection Variant: OBSOLETE PR and add Location as entered in Selection Screen)
Planning Version: 000
From: Current date – 60 days
To: Current date +180 days
Location: 0000201328
Product: *
Order Type: 1F
6. Compare output of step 4 and step 5 and display result.
From FM /SAPAPO/DM_MATLOC_GET_PEGIDS the output (step 4) will be Order ID (22 characters) while step 5 (T.Code /SAPAPO/RRP4) will give Planned Order number (8 character). I am not sure how to compare Internal Order ID (22 characters) for corresponding Planned Order Nos. (8 characters).
I have not marked your post as correct answer as still need to find answer of above query.
Thank you in advance for your guidance.
Regards,
Devang Shah -
Issue in Deployment of SNP Planned orders
Hi Experts,
I am trying to deploy SNP Planned orders and I have made relevant settings in SNP2 i.e. ATP category in ATD Receipt.
When I run deployment, it creats deployment stock transfer (DEP: PReq / DEP:ConRl) based on available stock first. When I run deployment second time, then it creats deployment stock transfer( DEP: PReq / DEP:ConRl) for SNP Planned order with the same quantity of stock & not for entire quantity of SNP Planned order. Please refer below example to make it clear
Total Demand at destination location = 600
Stock at supply location = 100
After planning run, Purchase requsition of 600 is generated at destination location.
At supply location, SNP Planned order of 500 is generated considering 100 stock is available against PReqRel of 600.
When I run Deployment first time, it forms DEP: PReq / DEP:ConRl of 100 based on available quantity of 100.
After running Deployment second time it forms again DEP: PReq / DEP:ConRl of 100 and it continues to create deployment stock transfer till it completes the quantity of SNP planned order.
So all together it creates 6 deployment stock transfers instead of forming one deployment stock transfer (stock+ SNP Planned order).
There is no lot size setting for product master.
Can anyone suggest whether I need to do some settings to get one deployment order instead of 6.
Thanks & Regards,
Chetan
Edited by: Chetan Patil on Nov 10, 2010 4:45 PMHi Chetan,
It looks the SNP planned order is not being considered in the receipts quantities to be available for deploying against requirements.
Please check SNP order ATP type( it is normally EE) is included in the appropriate Categroy group
IMG >> APO > Supply Chain Planning > SNP > Basic Settings > Maintain Category Groups
Example : ATD Receipts: ATR
Typical values : AI, AJ, BF, CC,EE,EF, EI
Secondly, in the transaction /SAPAPO/MSDP_ADMIN, in the Key Figure detailed tab, ATD Receipts should have assigned the Category Group(say ATR).
Regards
Datta -
Source of Supply for SNP Planned Order
Hi All,
I have a situation where we are feeding SNP planned orders using /sapapo/lcin (Time series to Order Network). When we use this transaction SNP planned orders are created in SNP but PDS is not attached to such orders. I would like to know how can I get PDSs attached to SNP planned orders created?
Regards,
Harshil DesaiThanks for reply Nandha,
PDS is active & Valid also SNP planned order indicator is set. Just to clarify that planned orders are not created by SNP. We are creating planned orders using /sapapo/lcin (Time series to Order Network) transaction.
Regards,
Harshil Desai -
Hi Experts,
May I ask for your help. I have a gr processing time of 1 and In-house production of 1 day as well. But whenever I run heuristic, it results in 4 days from start date to availability date. Say April 16 start date and availability date is April 20. Are there other factors on how this is computed?really hoping for a reply from you.
Thanks! Sincerely, RiaHello Ria,
Have you maintained any GR time in ECC?
I faced a similar issue (in PPDS order though) in which it was computing the availability date
first based on the GR processing time maintained in APO, when the order goes to ECC it would pick up the GR processing time maintained in ECC, and move the availability date of the order in APO.
We are working on code to stop this transfer back to APO.
Note 508993 gives more details about the FM.
You may try an option to stop the transfer from SAP R/3 since you are working with SNP planned orders:
https://help.sap.com/saphelp_scm50/helpdata/en/80/e8bc0f629af14db213108bb6fa7515/content.htm?frameset=/en/b3/32c5d32970834dadf53cac0aa2b5b4/frameset.htm¤t_toc=/en/9b/954d3baf755b67e10000000a114084/plain.htm&node_id=147
Hope this helps you!
Regards,
Subhash -
Hi Gurus,
I have a small confusion, Some of my products in a Production Plant donot have a SNP PPM. and when i run network heuristic on that location product. It creates SNP Planned orders.
Just for information the product location master has procurement type E (In House Production).
Please help me out if this is a normal behavior of the system.
Thanks,
MDefault behavior is to generate Orders without a source of supply.
"If there is neither a valid transportation lane (for procurement type F; external procurement) nor valid PPM/PDS (for procurement type E; in-house production), the system creates an SNP stock transfer or SNP planned order with no reference to a source of supply. The same applies if there is no product at the source location of the transportation lane"
if you dont want planned orders there,
Try using the SDP relevance indicator for the location - product . Am not sure but you can use option 1 in it (though it sounds like it will not plan in DP too)
Maybe you are looking for
-
Java style and coding conventions
Hello All, Most of my programming experience is in Java, and as such, I try to conform to the style and coding conventions that are used in all of the Sun tutorials, and to my understanding, the specification. I'm enrolled in my final semester of a b
-
Help required in creating a QUERY!!!
hi my name is johnny. I am new to this forums. My question is "There are 4 players in a team and that team played 4 matches. The scores for player1: 34,44,23,9. player2: 12,15,62,40. player3: 54,65,34,82. player4: 77,53,69,88. in four inning in four
-
Safari won't fully load websites
Safari is having many and varied moments of not fully loading webpages. It is also happening to a lesser degree on other browsers (firefox, camino, shiira). I have tested removing internet plugins, deleting cache, history, duplicate fonts, plist, etc
-
Hi Experts, I am running the MRP for a particular material ,and the material contains some sales order. I dont want the mrp to consider the sales order. I have made the changes in Strategy group from 40 to 10 in MRP3 tab. Schedule line from cp t
-
Upgrade to 11.5.9
hi all i still using oracle apps 11i(11.5.7) DB (8i). I want to upgrade to (11.5.9) DB 9i what are the steps required for upgrading?