{"audience":"Production planners who prepare the weekly production schedule in Excel or an external planning tool, and companies producing by project or for contract customers.","authorization_objects":[{"note":"Create and release production orders by order type","object":"C_AFKO_AWA"},{"note":"Production order authorization by plant and order type","object":"C_AFKO_AWK"}],"components":[],"countries":[],"effort_days_max":6,"effort_days_min":4,"effort_size":"M","faq":[{"a":"Yes. By adding sales order and item columns to the template, orders can be created for sales-order stock; the requirement class and account assignment are then checked as well, and the effort range increases by one or two days.","q":"Can orders be linked to a sales order?"},{"a":"No. The new production orders are seen as firm receipts in MRP; the related planned orders are reduced or deleted in the next MRP run. Keep the duplicate check on so that the same requirement is not covered by both a planned and a production order.","q":"Does creating production orders instead of planned orders disturb MRP?"},{"a":"Yes. BAPI_PRODORD_CREATE and BAPI_PRODORD_RELEASE are supported on S/4HANA. Because the production version is mandatory in S/4HANA, the program selects the valid version automatically or marks the row as failed if the version column is left blank.","q":"Does the program work on S/4HANA?"}],"features":[{"code":"test_run","label":"Test mode (check without posting)","note":""},{"code":"log","label":"Line-by-line result and error log","note":""},{"code":"error_file","label":"Download failed lines as a separate file","note":"Failed rows can be downloaded in the same template, corrected and uploaded again."},{"code":"background","label":"Runs as a background job","note":""}],"functions":[{"name":"BAPI_PRODORD_CREATE","role":"Creates the production order for each valid row"},{"name":"BAPI_PRODORD_RELEASE","role":"Releases the new order when requested"},{"name":"BAPI_TRANSACTION_COMMIT","role":"Saves successful rows permanently"},{"name":"BAPI_TRANSACTION_ROLLBACK","role":"Rolls back in test mode and for failed rows"}],"gap":"CO01 creates one order; CO40 and CO41 only convert planned orders created by MRP. Entering independent requirements in MD61 and running MRP is a planning process and does not give firm order quantities on specific dates. Planners who prepare the schedule outside SAP enter hundreds of rows one by one in CO01. The custom program creates the order for each row in the file through a BAPI and lists the result.","id":"pp-production-order-create-upload","industries":[],"input_columns":[{"derived":false,"label":"Material","required":true,"rule":"","target_field":"MATNR","target_table":"AFPO"},{"derived":false,"label":"Plant","required":true,"rule":"","target_field":"WERKS","target_table":"AUFK"},{"derived":false,"label":"Order type (blank = default)","required":false,"rule":"","target_field":"AUART","target_table":"AUFK"},{"derived":false,"label":"Quantity","required":true,"rule":"","target_field":"GAMNG","target_table":"AFKO"},{"derived":false,"label":"Basic start","required":false,"rule":"","target_field":"GSTRP","target_table":"AFKO"},{"derived":false,"label":"Basic finish","required":true,"rule":"","target_field":"GLTRP","target_table":"AFKO"},{"derived":false,"label":"Production version","required":false,"rule":"","target_field":"VERID","target_table":"AFPO"},{"derived":false,"label":"Storage location","required":false,"rule":"","target_field":"LGORT","target_table":"AFPO"},{"derived":false,"label":"Short text","required":false,"rule":"","target_field":"KTEXT","target_table":"AUFK"}],"kind":"program","language":"en","lastmod":"2026-11-17","logic":"1. The file (XLSX or CSV) is read from the user's PC or, in a background job, from the application server; the first row is skipped as the header.\n2. For each row MARC confirms that the material exists in the plant and is produced in-house, T399X that the order type is defined for the plant; if a production version is given, MKAL confirms it is not locked and is valid on the date.\n3. With the duplicate check selected, rows for which an open order with the same material, plant and basic start date exists in AFPO/AFKO are skipped as 'already exists'.\n4. For valid rows BAPI_PRODORD_CREATE is called with quantity, basic start/finish, version and storage location. In test mode the call is rolled back with BAPI_TRANSACTION_ROLLBACK.\n5. With 'release immediately' selected, the new order is released with BAPI_PRODORD_RELEASE; each row is committed separately, so a failed row does not affect the others.\n6. The result list shows the row, order number, release result and BAPI message; failed rows can be corrected and uploaded again with the same template.","module":"PP","object_type":"upload","output_columns":[{"calculated":true,"formula":"Row number in the file","label":"Row","source_field":null,"source_table":null},{"calculated":false,"formula":"","label":"Material","source_field":"MATNR","source_table":"AFPO"},{"calculated":false,"formula":"","label":"Plant","source_field":"WERKS","source_table":"AUFK"},{"calculated":false,"formula":"","label":"Quantity","source_field":"GAMNG","source_table":"AFKO"},{"calculated":false,"formula":"","label":"Order","source_field":"AUFNR","source_table":"AUFK"},{"calculated":true,"formula":"Result of BAPI_PRODORD_RELEASE: released, not requested or error","label":"Release","source_field":null,"source_table":null},{"calculated":true,"formula":"Created, test passed, already exists or error","label":"Status","source_field":null,"source_table":null},{"calculated":true,"formula":"BAPI return message or check error","label":"Message","source_field":null,"source_table":null}],"parameters":[{"example":"C:\\temp\\haftalik-uretim-programi.xlsx","kind":"parameter","label":"Upload file (XLSX or CSV)","name":"P_FILE","ref_field":"","required":true},{"example":"PP01","kind":"parameter","label":"Default order type","name":"P_AUART","ref_field":"AUFK-AUART","required":true},{"example":"","kind":"checkbox","label":"Release orders immediately","name":"P_REL","ref_field":"","required":false},{"example":"X","kind":"checkbox","label":"Skip when an open order exists for the same material and date","name":"P_DUPL","ref_field":"","required":false},{"example":"X","kind":"checkbox","label":"Test mode (check without posting)","name":"P_TEST","ref_field":"","required":false}],"part_of":[],"performance":"BAPI_PRODORD_CREATE schedules each order and checks materials; run files above a few hundred rows as a background job. Do the check reads (MARC, MKAL, T399X) once with the keys from the file.","quote_url":"https://nekuhub.com/en/request-a-quote/?report=pp-production-order-create-upload","related":["pp-mass-release-with-component-check","pp-planned-order-conversion-readiness"],"releases":[],"source":"custom","standard_alternatives":[{"note":"Creates one production order on screen; does not read files.","tcode":"CO01"},{"note":"Converts planned orders collectively; does not create orders from a list prepared outside MRP.","tcode":"CO41"}],"summary":"A custom program that creates production orders in bulk from material, quantity and date rows in an Excel or CSV file, and optionally releases them immediately. In test mode it checks the material, production version and order type, skips duplicate orders and lists the result of each row with the order number.","tables":[{"access":"read","join_on":"MARC-MATNR = dosya malzeme AND MARC-WERKS = dosya üretim yeri","role":"Existence of the material in the plant and procurement type","table":"MARC","variant":"both"},{"access":"read","join_on":"T399X-WERKS = dosya üretim yeri AND T399X-AUART = dosya sipariş türü","role":"Order type defined for the plant","table":"T399X","variant":"both"},{"access":"read","join_on":"MKAL-MATNR = MARC-MATNR AND MKAL-WERKS = MARC-WERKS AND MKAL-VERID = dosya versiyon","role":"Validity and lock of the production version","table":"MKAL","variant":"both"},{"access":"write","join_on":"AUFK-AUFNR = yeni sipariş","role":"New order header (through the BAPI)","table":"AUFK","variant":"both"},{"access":"write","join_on":"AFKO-AUFNR = AUFK-AUFNR","role":"Order quantity and basic dates; duplicate check","table":"AFKO","variant":"both"},{"access":"write","join_on":"AFPO-AUFNR = AUFK-AUFNR","role":"Order item: material, version, storage location","table":"AFPO","variant":"both"}],"title":"Mass Production Order Creation from File Program","url":"https://nekuhub.com/en/programs/mass-production-order-creation-from-file-program/","vendor_id":"nekudos"}