Lesson 1 of 6
Outbound invoices from billing
8 min
Listen to this lesson
Great Lakes Fleet Services buys alternators from Contoso Motor Co. by EDI: its purchase orders arrive as X12 850s and become sales orders (sap-edi-203), and it wants invoices back as X12 810s so its accounts payable system can match them without retyping. This lesson sets up that outbound invoice. The running example is billing document 90001877 for sales order 1000457 and delivery 80001234: 50 alternators CMC-ALT-100 at 240.00 USD, 12,000.00 USD net, no sales tax because Great Lakes Fleet Services holds an exemption.
Two output frameworks, one choice for all of billing
Billing in SAP S/4HANA can run on output determination (SD-BF-OC), the condition-technique message control known from ECC, or on SAP S/4HANA output control (CA-GTF-OC). SAP's billing documentation states a rule that shapes every design: you cannot combine the two frameworks within billing, so the choice applies to all billing apps. Which one is active by default depends on the release and on whether the system was converted, so check the activation setting rather than assuming. The Fiori apps Create Billing Documents, Manage Billing Documents and Schedule Billing Output send output only with output control.
| Aspect | Output determination (SD-BF-OC) | SAP S/4HANA output control (CA-GTF-OC) |
|---|---|---|
| Rule | Condition records for output type RD00 (application V3) | Output Parameter Determination rules for BILLING_DOCUMENT |
| EDI setting | Transmission medium 6 (EDI), partner function bill-to | Receiver role RE, channel EDI |
| IDoc build | Partner profile message control V3 / RD00 / process code SD09 (IDOC_OUTPUT_INVOIC) | EDI channel; SAP documents that it supports IDoc and SOA formats depending on the scenario |
| Parallel channels | Separate output types or condition records | Several channel rules per role, for example EDI plus EMAIL, with an exclusive indicator |
Contoso runs billing on output control: invoice 90001877 was first sent to Great Lakes as a PDF by email (sap-sd-207 shows that rule). For EDI, Theo's team adds a Channel rule for output type BILLING_DOCUMENT, role RE and channel EDI, restricted to Great Lakes Fleet Services. Both channels stay active for role RE: the 810 is the document Great Lakes' accounts payable system processes, and the PDF copy goes to its AP mailbox for reference. If Great Lakes ever wants EDI only, marking the EDI rule exclusive stops the email without touching the 810. For the IDoc side of the EDI channel, follow SAP Note 2228611 and the billing documentation for your release; under SD-BF-OC the equivalent is the well-known V3 / RD00 / SD09 setup.
The partner profile
| Setting | Value for Great Lakes Fleet Services |
|---|---|
| Partner number / type | 17100001 / KU (customer) |
| Outbound message type | INVOIC |
| Basic type | INVOIC02 (SAP also delivers INVOIC01; use 02 for new partners) |
| Receiver port | XQ1_PO in CMQ, XP1_PO in CMP (tRFC ports to Process Orchestration) |
| Message control tab | No entry under output control; under output determination it would be V3 / RD00 / SD09 |
| Output mode | Collect IDocs; a job running RSEOUT00 sends them every 30 minutes |
| Partner function | Bill-to party, matching the output's receiver role RE |
Outbound INVOIC partner profile for Great Lakes Fleet Services.
Why collect rather than send immediately? A billing run in the evening creates hundreds of invoices for fleet customers. Collecting them into 30-minute batches keeps the load on Process Orchestration smooth and gives Great Lakes a predictable number of interchanges a day. The cost is that every invoice IDoc waits in status 30 for up to half an hour, which monitoring must treat as normal (sap-edi-208 covers status 30).
Credit and debit memos
Credit memos (billing type G2) and debit memos (L2) go out through the same message type INVOIC. The IDoc header tells the receiver which document it is, and the mapping turns a credit memo into an 810 flagged as a credit or, for EDIFACT, an INVOIC with a credit note document code. Agree with Great Lakes whether credit memos travel as 810s at all; some customers want credits only on paper or as remittance adjustments, and that decision changes the output rules.
Testing the outbound invoice
A first test of outbound EDI invoicing is more than "the IDoc is green". In CMQ, Priya's team bills a delivery for Great Lakes and checks four points: the EDI output item is processed on the billing document; the INVOIC IDoc carries the expected values (invoice number, PO reference, items, tax exemption, total); Process Orchestration in XQ1 produced an 810 that passes Great Lakes' test translator with a positive 997; and Great Lakes' AP team confirms that the test invoice matched their PO in their system. The last step is the one that proves the business value, and the one most often skipped.
- Billing uses one output framework for all billing apps: output determination (RD00, V3, SD09) or output control (BILLING_DOCUMENT, role RE).
- In output control, the EDI channel carries electronic messages to customers; Contoso sends Great Lakes both the 810 (EDI) and a PDF copy (EMAIL) for role RE.
- The outbound partner profile for the customer (KU) holds message type INVOIC, basic type INVOIC02, the port and the output mode.
- Credit and debit memos travel as INVOIC too; agree with the customer whether it wants them by EDI.
Check your understanding · not graded
Lesson check
1. Which process code builds an INVOIC IDoc from output type RD00 under output determination?
2. Why must Contoso pick one output framework for billing?
3. How does Contoso send Great Lakes both the 810 and a PDF copy?
4. Invoice IDocs for Great Lakes sit in status 30 for up to 30 minutes. What does that indicate?