{"audience":"Budgeting and planning teams, controllers and finance teams that bring the annual budget into SAP.","authorization_objects":[{"note":"Planning authorization by cost center","object":"K_CSKS_PLA"}],"components":[],"countries":[],"effort_days_max":5,"effort_days_min":3,"effort_size":"M","faq":[{"a":"The standard version loads the primary cost plan. Activity output and rate planning can be loaded with a separate BAPI using the same template logic; this extension adds 1–2 days to the effort range.","q":"Can activity quantities and rates be loaded too?"},{"a":"In overwrite mode the plan value for the same cost center, cost element and period is replaced by the file value. In add mode the amount is added to the existing plan, so add mode must be used carefully for correction files.","q":"What happens if I load the plan a second time?"},{"a":"If classic cost center planning is still used on S/4HANA, the BAPI works the same way. If planning has moved to SAP Analytics Cloud or the new ACDOCP-based planning, the upload is adapted to that target.","q":"Can it be used 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 to a separate file, corrected and uploaded again."},{"code":"excel","label":"Export to Excel","note":"An empty upload template can be downloaded as Excel."},{"code":"background","label":"Runs as a background job","note":""}],"functions":[{"name":"BAPI_COSTACTPLN_POSTPRIMCOST","role":"Posts the primary cost plan by cost center and cost element"},{"name":"BAPI_TRANSACTION_COMMIT","role":"Saves successful packages permanently"},{"name":"BAPI_TRANSACTION_ROLLBACK","role":"Rolls back the change in test mode and for failed packages"}],"gap":"KP06 enters the plan cost center by cost center on layout-bound screens. Excel integration through the planner profile needs configuration and gives no error list per row. KSBL only displays the plan. A budget file with hundreds of cost centers and cost elements needs an upload program with test mode and results per row.","id":"co-cost-center-plan-upload","industries":[],"input_columns":[{"derived":false,"label":"Cost center","required":true,"rule":"","target_field":"KOSTL","target_table":"CSKS"},{"derived":false,"label":"Cost element","required":true,"rule":"","target_field":"KSTAR","target_table":"COSP"},{"derived":true,"label":"Period (blank = annual)","required":false,"rule":"1–12; if blank the amount is spread equally over 12 periods","target_field":null,"target_table":null},{"derived":true,"label":"Amount","required":false,"rule":"Written as the plan value of the period to COSP WKG001…WKG012","target_field":null,"target_table":null},{"derived":false,"label":"Currency","required":false,"rule":"","target_field":"TWAER","target_table":"COSP"}],"kind":"program","language":"en","lastmod":"2026-11-17","logic":"1. The file 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. Every row is checked: the cost center must be valid in the fiscal year (CSKS-DATAB/DATBI), the cost element must be a primary cost element in the controlling area (CSKB-KATYP), and the period must be between 1 and 12 or empty. An empty period means an annual amount that is spread equally over 12 periods.\n3. Rows are grouped by cost center / cost element and mapped to the header (controlling area, fiscal year, period range, version), object and period value structures of BAPI_COSTACTPLN_POSTPRIMCOST.\n4. With P_DELTA the amounts are added to the existing plan; without it the plan values are overwritten.\n5. In test mode the BAPI is called and rolled back with BAPI_TRANSACTION_ROLLBACK; in a real run BAPI_TRANSACTION_COMMIT is called after each cost center package. Results and messages are listed per row.","module":"CO","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":"Cost center","source_field":"KOSTL","source_table":"CSKS"},{"calculated":false,"formula":"","label":"Cost element","source_field":"KSTAR","source_table":"COSP"},{"calculated":true,"formula":"Total planned amount of the row","label":"Amount loaded","source_field":null,"source_table":null},{"calculated":true,"formula":"From the BAPI return messages: posted, checked or error","label":"Status","source_field":null,"source_table":null},{"calculated":true,"formula":"First error or success message from the BAPI return table","label":"Message","source_field":null,"source_table":null}],"parameters":[{"example":"C:\\temp\\butce_2027.xlsx","kind":"parameter","label":"Upload file (XLSX or CSV)","name":"P_FILE","ref_field":"","required":true},{"example":"1000","kind":"parameter","label":"Controlling area","name":"P_KOKRS","ref_field":"CSKS-KOKRS","required":true},{"example":"2027","kind":"parameter","label":"Fiscal year","name":"P_GJAHR","ref_field":"COSP-GJAHR","required":true},{"example":"0","kind":"parameter","label":"Plan version","name":"P_VERSN","ref_field":"COSP-VERSN","required":true},{"example":"","kind":"checkbox","label":"Add to the existing plan (overwrite if not set)","name":"P_DELTA","ref_field":"","required":false},{"example":"X","kind":"checkbox","label":"Test mode (check without posting)","name":"P_TEST","ref_field":"","required":false}],"part_of":["co-cost-center-controlling-pack"],"performance":"Calling the BAPI with one package per cost center isolates errors. Run files with tens of thousands of rows as a background job.","process":"R2R","quote_url":"https://nekuhub.com/en/request-a-quote/?report=co-cost-center-plan-upload","related":["co-cost-center-plan-actual-commitment","fi-gl-journal-entry-upload"],"releases":[],"source":"custom","standard_alternatives":[{"note":"Enters the plan on a layout-bound screen; no bulk upload from a file with results per row.","tcode":"KP06"},{"note":"Displays the cost center plan; does not enter plan values.","tcode":"KSBL"}],"summary":"A custom program that loads periodic plan amounts per cost center and cost element from a budget file into the CO plan in bulk. It checks every row in test mode first, offers to overwrite or add to the existing plan and lists the result of every row.","tables":[{"access":"write","join_on":"","role":"Primary cost plan totals (value type 01, plan version)","table":"COSP","variant":"both"},{"access":"read","join_on":"CSKS-KOKRS = P_KOKRS AND CSKS-KOSTL = dosyadaki masraf yeri","role":"Validity of the cost center in the fiscal year","table":"CSKS","variant":"both"},{"access":"read","join_on":"CSKB-KOKRS = P_KOKRS AND CSKB-KSTAR = dosyadaki maliyet unsuru","role":"Cost element defined as primary in the controlling area","table":"CSKB","variant":"both"}],"title":"Cost Center Cost Plan Upload from Excel","url":"https://nekuhub.com/en/programs/cost-center-cost-plan-upload-from-excel/","vendor_id":"nekudos"}