MM02ME11ME12ME01ME59NMEK1ME23NSM36
As an SAP MM consultant in India, you know that manual processes are the enemy of efficiency, especially in high-volume procurement scenarios. When you're dealing with hundreds or thousands of purchase requisitions (PRs) daily for routine items like MRO spares, office supplies, or even low-value production components, asking a buyer to convert each PR to a Purchase Order (PO) manually using ME21N is simply not sustainable. This is where SAP MM's automatic PO creation functionality, specifically transaction code ME59N, becomes indispensable. It's a critical tool for any organization looking to streamline its procure-to-pay cycle.
This guide will cut straight to the chase, explaining not just what ME59N does, but why it's configured the way it is and how to troubleshoot common issues. We'll cover the essential master data prerequisites, delve into the grouping logic, and walk through practical steps. By the end, you'll be able to confidently set up and manage automatic PO creation from purchase requisitions in your SAP S/4HANA system, moving your team towards a more automated and error-free procurement landscape.
- ME59N automates purchase order creation from purchase requisitions, significantly boosting procurement efficiency and reducing manual effort for routine items.
- Four critical master data prerequisites are mandatory: Material Master (Automatic PO), Vendor BP (Automatic PO), Purchasing Info Record (price, valid dates), and Source List (fixed vendor, valid dates).
- ME59N intelligently groups multiple PRs into one PO or splits one PR into multiple POs based on criteria like vendor, purchasing organization, company code, and PO document type.
- Common errors like 'Source not determined' or 'Pricing error' stem from incomplete or incorrect master data; always start troubleshooting there.
- Always use the 'Test run' or 'Creation indicator = 2' option in ME59N for simulations to identify and resolve issues before creating actual purchase orders.
- ME59N can be scheduled as a background job (SM36) for fully automated, continuous processing of purchase requisitions.
01Business Value of ME59N: Eliminating Manual Buyer Intervention
The core business value of SAP MM automatic PO creation via ME59N lies in its ability to transform a typically labour-intensive and error-prone process into an automated, background task. Imagine a large manufacturing plant in Pune or Chennai, generating thousands of PRs daily for indirect materials. Without ME59N, each of these would require a buyer's manual review and PO creation. This consumes valuable buyer time that could be better spent on strategic sourcing, vendor negotiation, or handling exceptions.
By implementing ME59N, companies can achieve:
- Reduced Operational Costs: Less manual effort translates directly into lower labour costs for routine procurement.
- Increased Efficiency and Speed: POs are created almost instantly once a PR meets the criteria, significantly shortening the procurement lead time. This is crucial for maintaining optimal inventory levels and avoiding production delays.
- Minimized Human Error: Automation eliminates typos, incorrect data entries, or forgotten fields that often plague manual processes.
- Improved Compliance: Adherence to established sourcing rules (e.g., through source lists and info records) is enforced consistently.
- Buyer Focus on Strategic Tasks: Free up your procurement team to focus on high-value activities like contract management, supplier relationship management, and complex category sourcing.
For organisations aiming for true procurement excellence, ME59N is not merely a convenience; it's a strategic necessity, especially when integrated with other automation capabilities like SAP Joule AI in S/4HANA Logistics & Procurement.
02The Mandatory Prerequisites for SAP MM Automatic PO Creation (ME59N)
Automatic PO creation in SAP MM isn't a magical 'push-button' solution. It relies heavily on well-maintained master data. If any of these foundational elements are missing or incorrectly configured, ME59N will fail. You need to verify these settings rigorously:
1. Material Master (MM01/MM02)
The material being procured must be set up for automatic PO creation. Navigate to the Purchasing view for the relevant plant and ensure the 'Automatic PO' indicator is checked. This tells the system that this material is eligible for automated procurement processes.
- T-code:
MM02(Change Material Master) - Path: Logistics > Materials Management > Material Master > Material > Change > Immediately
- View: Purchasing
- Field:
Automatic POindicator (MARC-KZAUT)
2. Vendor Master / Business Partner (BP) (BP)
Similar to the material, the vendor (supplier) must also be enabled for automatic PO creation. In S/4HANA, vendors are managed as Business Partners. Within the 'Supplier' role, under the 'Purchasing Organization Data' section, check the 'Automatic PO' indicator.
- T-code:
BP(Maintain Business Partner) - Path: In BP, select the Supplier role (e.g., FLCU01 for Customer, FLVN01 for Vendor). Go to the 'Purchasing Org. Data' section.
- Field:
Automatic POindicator (LFM1-KZAUT)
3. Purchasing Info Record (ME11/ME12)
The purchasing info record is paramount. It links a material, a vendor, and a purchasing organization, defining pricing conditions, delivery data, and other critical parameters for a specific material-vendor combination. Without an active info record, ME59N cannot determine a valid source for pricing or other details, leading to errors.
- T-code:
ME11(Create Info Record),ME12(Change Info Record) - Path: Logistics > Materials Management > Purchasing > Master Data > Info Record
- Key data points to check:
- Valid Purchasing Organization: The info record must be valid for the purchasing organization linked to the PR.
- Net Price: A valid net price (or a valid pricing condition that determines it, as defined in the SAP MM Pricing Procedure) must be maintained.
- Standard/Subcontracting/Consignment: Ensure the info record type matches the procurement type (e.g., Standard for standard POs).
4. Source List (ME01/ME02)
For materials requiring a specific vendor for a plant, a source list entry is essential. It defines valid vendors for a material during a specific period. ME59N uses the source list to determine *which* vendor to use if multiple info records exist for a material, or simply to ensure a vendor is explicitly approved.
- T-code:
ME01(Maintain Source List) - Path: Logistics > Materials Management > Purchasing > Master Data > Source List
- Key data points to check:
- Material and Plant: Entry must exist for the material and plant specified in the PR.
- Vendor: The vendor must be specified.
- Valid From/To Date: The entry must be valid for the PR's desired delivery date.
- MRP Relevant: Ensure the 'MRP relevant' indicator is set to '1' (Source list record relevant to MRP) if the PR originated from MRP and a fixed vendor is desired.
- Fixed Vendor: If you want to force a specific vendor, mark it as 'Fixed Vendor'. This is highly recommended for predictable automation.
5. Purchase Requisition (ME51N/ME52N)
The PR itself needs to be correctly set up for automatic PO creation:
- Processing Status: The PR must have a processing status that allows PO creation (typically blank or 'Not yet processed'). If it's already 'In process' or 'Rejected', ME59N will ignore it.
- Source of Supply: It's beneficial to assign a source of supply (vendor, info record) in the PR using ME51N/ME52N, though ME59N can determine it if source list/info record are maintained. If you manually assign a fixed vendor in the PR, ensure it matches the vendor in the source list and info record.
- Account Assignment: For account-assigned PRs (e.g., Cost Centre, WBS Element), ensure the account assignment data is complete and valid. Incomplete account assignment will prevent PO creation and trigger errors, which can often be traced back to incorrect configuration in SAP MM OBYC Account Determination.
03Configuring ME59N Parameters for Automatic PO Creation
When you execute ME59N, you're presented with a selection screen to filter and process purchase requisitions. Understanding these parameters is key to running the transaction effectively.
Transaction Code: ME59N
Path: Logistics > Materials Management > Purchasing > Purchase Requisition > Follow-on Functions > Create Purchase Order Automatically
Here are the key selection parameters:
- Purchasing Organization: Essential for filtering PRs relevant to a specific purchasing organization.
- Purchasing Group: You can restrict processing to PRs assigned to a particular purchasing group.
- Vendor: If you want to create POs for a specific vendor, enter their Business Partner number. This is common if you run ME59N separately for critical suppliers.
- Material: Specify a material or range of materials to focus automation.
- Plant: Filter PRs belonging to a specific plant.
- Purchase Requisition: Enter specific PR numbers if you want to process only a few known requisitions.
- Processing Status: Usually left blank to include all PRs not yet processed.
- 'Only with source of supply': If checked, ME59N will only consider PRs for which a source of supply (vendor, info record) is already assigned in the PR itself, or can be uniquely determined via source list/info record. It's often best to keep this checked to avoid errors where no source can be found.
- 'Creation indicator': This is crucial.
- '1' (Create POs directly): The system creates actual POs.
- '2' (Create POs, but do not save): The system simulates the PO creation and displays potential errors, but no POs are saved. This is extremely useful for testing and troubleshooting. Always use this first when setting up or modifying configuration.
- 'Test run': Similar to 'Creation indicator = 2', but specifically for the report itself, showing what would happen without making database changes.
Recommendation: Always perform a 'Test run' or use 'Creation indicator = 2' initially when you are unsure or testing new setups. This allows you to identify and correct master data or configuration issues without creating erroneous purchase orders.
04Grouping and Splitting Logic in ME59N
One of the most powerful features of ME59N is its intelligent grouping and splitting logic. It doesn't simply create one PO for each PR. Instead, it tries to optimize by consolidating multiple PRs into a single PO where appropriate, or splitting a PR into multiple POs based on specific criteria. Understanding this logic is crucial for predicting the outcome of your automatic PO runs.
ME59N determines whether to group or split based on the following key fields:
- Vendor: All items in a single PO must be from the same vendor.
- Purchasing Organization: All items in a single PO must belong to the same purchasing organization.
- Company Code: All items in a single PO must belong to the same company code.
- Document Type of PO: If PRs require different PO document types (e.g., NB for standard, FO for framework), they will be split. This is determined by the configuration of the document type linked to the PR.
- Purchasing Group: Items with different purchasing groups in the PR can be grouped if the PO document type configuration allows it.
- Plant: Typically, ME59N tries to group items for the same plant into one PO. However, if a PR line item has a different plant, it might lead to a split if the PO document type doesn't allow multiple plants or if other grouping criteria conflict.
Here’s how the logic usually works:
- Multiple PRs to One PO (Many-to-One): If several PRs (or PR line items) are for the same vendor, same purchasing organization, same company code, and same PO document type, ME59N will attempt to group them into a single PO, with each PR item becoming a separate PO item. This is the ideal scenario for efficiency.
- One PR to Multiple POs (One-to-Many): If a single PR contains line items that have different vendors, different plants (and the PO document type doesn't allow mixed plants), or require different PO document types, ME59N will split that single PR into multiple POs. For example, if PR X has line item 1 for Vendor A and line item 2 for Vendor B, two separate POs will be created.
- One PR to One PO (One-to-One): This happens when a PR meets all the criteria for grouping, but no other eligible PRs are found to be grouped with it, or when specific configuration settings (e.g., in the vendor master 'Control data' tab, 'GR-based IV' or 'Evaluated Receipt Settlement' indicator could influence PO creation logic) or user exits prevent grouping.
The grouping logic is highly dependent on the consistency of your master data and the selection criteria you provide in ME59N. Always ensure your master data aligns with your desired grouping strategy.
05Common Errors in ME59N and Their Resolution
Running ME59N is rarely a 'first-time-lucky' affair, especially in complex environments. You'll encounter errors. Here are the most frequent ones and how to resolve them:
1. Error: 'Source not determined for material XXXXX in plant YYYY'
Cause: The system cannot find a valid vendor to create the PO. This is almost always a master data issue related to sourcing.
Resolution:
- Check Info Record (ME12): Ensure a valid purchasing info record exists for the material-vendor-purchasing organization combination. Verify the valid-to date and net price. Refer to SAP MM Pricing Procedure (Calculation Schema) Configuration Guide for pricing details.
- Check Source List (ME02): If a source list is required (e.g., 'Source list requirement' checkbox in material master is set), ensure an active source list entry exists for the material, plant, and vendor, covering the required period. Mark it as 'Fixed' if necessary.
- Vendor Master (BP): Confirm the 'Automatic PO' indicator is checked in the vendor's purchasing data.
- Material Master (MM02): Confirm the 'Automatic PO' indicator is checked in the material's purchasing view for the relevant plant.
2. Error: 'Pricing error in item XXXXX' or 'No price could be determined'
Cause: The system failed to determine a net price for the PO item. This is a crucial step for PO creation.
Resolution:
- Check Info Record (ME12): Ensure a valid net price is directly maintained in the info record or that the pricing conditions in the info record are correctly configured to derive a price.
- Check Pricing Procedure (M/08): Verify that the assigned pricing procedure (calculation schema) is correctly configured and contains the necessary condition types to determine the price. Use T-code
MEK1to check if pricing conditions exist for the info record. - Scales/Validity Dates: Ensure any price scales or validity periods in the info record's conditions are met.
3. Error: 'Account assignment data missing' or 'Enter G/L account'
Cause: For PRs with account assignment categories (e.g., K-Cost Center, F-Order, P-Project), the required G/L account and other account assignment objects (Cost Center, WBS Element) are not complete or valid.
Resolution:
- Check PR (ME52N): Review the account assignment tab for the PR item. Ensure all mandatory fields (G/L Account, Cost Center, WBS Element, etc.) are populated correctly and are valid.
- Configuration (OBYC/OME9): For automatic account determination, verify the settings in SAP MM OBYC Account Determination: S/4HANA Automatic Posting Masterclass for relevant movement types and valuation classes. Also, check the account assignment category configuration in OME9.
4. Error: 'No plant specified'
Cause: The purchase requisition item lacks a plant assignment.
Resolution:
- Check PR (ME52N): Ensure every line item in the purchase requisition has a plant specified. This is a mandatory field for procurement.
5. Error: 'No suitable requisition found' (after running ME59N)
Cause: This isn't strictly an error message, but it means no PRs met your selection criteria or the prerequisites for automatic PO creation.
Resolution:
- Review Selection Parameters: Double-check the filters you entered in ME59N (Vendor, Material, Plant, PR number, etc.). Broaden them if necessary.
- Check Prerequisites: Go back to your master data checklist (Material Master, Vendor BP, Info Record, Source List, PR processing status) and verify everything.
- Test Run: Always use the 'Test run' indicator or 'Creation indicator = 2' first to get a detailed log of why PRs were rejected.
06Step-by-Step Execution of ME59N
Once your master data is squared away and you've understood the logic, executing ME59N is straightforward. Here’s a typical procedure:
- Access Transaction: Go to
ME59N. - Enter Selection Criteria:
- Input your
Purchasing Organization. - Enter the
Vendorif you want to run for a specific supplier. - Specify a
Plantif needed. - Crucially, ensure the '
Only with source of supply' checkbox is checked. - For initial runs or troubleshooting, set '
Creation indicator' to '2 - Create POs, but do not save' or tick the 'Test run' checkbox.
- Input your
- Execute: Click the 'Execute' button (F8).
- Analyze Results (Test Run):
- If you ran a test, the system will display a log. Green lights indicate successful simulation of PO creation. Red lights or warning triangles indicate issues.
- Double-click on any red light messages to view the exact error details. Use the error messages section above to troubleshoot.
- Adjust master data or PRs as needed based on the errors.
- Execute for Real:
- Once confident, uncheck '
Test run' and set 'Creation indicator' to '1 - Create POs directly'. - Execute again.
- Once confident, uncheck '
- Verify PO Creation:
- The system will display a list of created purchase orders.
- Note down the PO numbers.
- Use
ME23N(Display Purchase Order) to verify that the POs have been created correctly and reflect the PR details.
Regularly scheduled background jobs can be set up for ME59N (using T-code SM36 for job scheduling) to automate this process completely for routine items, running daily or multiple times a day as required. This is where the true power of automation is realized, freeing up your team from repetitive tasks.
07Interview Questions on SAP MM Automatic PO Creation (ME59N)
As an SAP MM consultant in India, you should expect questions on ME59N during interviews, especially for roles focusing on procurement automation or functional lead positions. Here are some common ones:
- What is the purpose of transaction ME59N in SAP MM?
- List the mandatory master data prerequisites for automatic PO creation using ME59N.
- Explain the significance of the 'Automatic PO' indicator in the Material Master and Vendor Master (Business Partner).
- How does the Purchasing Info Record contribute to ME59N functionality?
- What is the role of the Source List in determining a source of supply for automatic POs?
- Describe a scenario where ME59N would group multiple purchase requisitions into a single purchase order.
- When would ME59N create multiple purchase orders from a single purchase requisition?
- You ran ME59N, and it shows 'Source not determined'. What are the first three things you would check?
- How do you troubleshoot 'Pricing error in item' during ME59N execution?
- What is the difference between 'Test run' and 'Creation indicator = 2' in ME59N?
- Can ME59N be scheduled as a background job? If so, why would you do it?
- How do you ensure proper account assignment for automatically created POs, especially for indirect materials?
Being able to articulate the 'why' behind each prerequisite and resolution step, combined with practical transaction knowledge, will set you apart. For more preparation, review Top 30 SAP MM Interview Questions for 2026.
Get the 40+ lesson playlist, the most-asked interview questions and our 90-day roadmap on WhatsApp.
?Frequently asked questions
What is the primary function of ME59N in SAP MM?
ME59N is an SAP MM transaction code used to automatically create purchase orders (POs) from eligible purchase requisitions (PRs). Its main purpose is to automate routine procurement tasks, reduce manual effort for buyers, and accelerate the procure-to-pay cycle by converting PRs into POs based on predefined master data and configuration.
Which master data must be correctly configured for ME59N to work?
For ME59N to function, you need correctly configured Material Master (with 'Automatic PO' indicator), Vendor Business Partner (with 'Automatic PO' indicator in purchasing data), a valid Purchasing Info Record (with pricing), and often a Source List entry for unique vendor determination. Incomplete or incorrect setup of any of these will lead to errors.
Can ME59N create multiple POs from a single PR, or group multiple PRs into one PO?
Yes, ME59N is designed with flexible grouping and splitting logic. It can group multiple PRs (or PR items) into a single PO if they share the same vendor, purchasing organization, company code, and PO document type. Conversely, a single PR with items that require different vendors or PO document types will be split into multiple POs.
What should I do if ME59N gives an error 'Source not determined'?
If you encounter a 'Source not determined' error, first check the Purchasing Info Record (ME12) for the material and vendor to ensure it's valid and has a price. Then, verify the Source List (ME02) for an active entry linking the material, plant, and vendor. Finally, confirm the 'Automatic PO' indicators are checked in both the Material Master and Vendor Business Partner.
Is ME59N available in SAP S/4HANA, and are there any differences from ECC?
Yes, ME59N is fully available and functions similarly in SAP S/4HANA as it did in ECC. The core logic and prerequisites remain the same. The main difference in S/4HANA is that vendor master data is now managed through the Business Partner (BP) concept (transaction BP), so you'll configure the 'Automatic PO' indicator within the BP record rather than directly in the old vendor master (FK01/MK01).
How can I test ME59N without creating actual purchase orders?
You can test ME59N safely by using the 'Test run' checkbox on the selection screen, or by setting the 'Creation indicator' to '2 - Create POs, but do not save'. Both options simulate the PO creation process and generate a log of potential POs and any errors, allowing you to troubleshoot and correct issues without impacting live data.
Learn SAP hands-on with theTechMentor
Live weekday & weekend batches or 24/7 recorded courses, with S/4HANA practice server access and interview preparation.