What Is the SAP Account Assignment Group?
If you've ever seen a billing document fail to release to accounting in SAP, there's a good chance a missing or misconfigured account assignment group was the culprit. This field is small - just two characters - but it controls something massive: which G/L account your revenue posts to when a billing document hits Finance.
The SAP account assignment group (AAG) is a classification key maintained in two places: the customer master and the material master. Together, these two values - combined with an account key from your pricing procedure - tell the system exactly which General Ledger account to credit when a sale is posted. No account assignment group, no automatic account determination. Simple as that.
This is not a concept you want to skim over. Get this wrong in configuration and your revenue hits the wrong G/L. Get it missing entirely and your billing team can't close invoices. Let's break down exactly how this works and walk through the full setup.
The Two Types of Account Assignment Groups
There are two distinct account assignment groups in SAP SD, and they serve different purposes in the account determination logic:
- Customer Account Assignment Group: Set in the customer master under Sales Area Data → Billing tab. This groups customers by how their revenue should be recorded - for example, domestic customers versus export customers. The system pulls this value automatically into the billing document header from the payer's master record.
- Material Account Assignment Group: Set in the material master under the Sales: Sales Org. 2 view. This groups materials by their accounting nature - finished goods, trading goods, services, etc. It flows into the billing document at the line item level.
When a billing document is created, SAP reads the customer AAG from the document header and the material AAG from each line item. It then uses those values - along with the sales organization, chart of accounts, and account key - to look up the correct G/L account in transaction VKOA.
How Account Assignment Groups Feed Into VKOA
VKOA is the transaction where everything comes together. This is where you assign G/L accounts to specific combinations of criteria. The most commonly used table in VKOA (Table 004: Customer Group / Material Group / Account Key) maps accounts based on the following fields:
- Application (always "V" for SD)
- Condition Type (typically KOFI for G/L account determination)
- Chart of Accounts
- Sales Organization
- Customer Account Assignment Group
- Material Account Assignment Group
- Account Key (ERL for revenue, ERS for sales deductions, etc.)
A practical example: a domestic customer (AAG = 01) purchasing a finished good (material AAG = 01) with account key ERL might map to G/L account 400000 (Domestic Revenue). That same material sold to an export customer (AAG = 02) would map to G/L 400100 (Export Revenue). SAP resolves this automatically at runtime - no manual journal entry required.
This is the engine behind the SD-FI integration. Every time a billing document posts, this determination fires. Get the configuration right once, and your sales-to-finance handoff is seamless. Get it wrong, and your finance team is hunting errors every month.
Free Download: Sales KPIs Tracker
Drop your email and get instant access.
You're in! Here's your download:
Access Now →Step-by-Step Configuration in SAP SD
Here is the full configuration path and sequence. Do these in order - skipping steps is how gaps get created that only surface during month-end billing runs.
Step 1: Define Account Assignment Groups (IMG)
Navigation path: SPRO → Sales and Distribution → Basic Functions → Account Assignment/Costing → Revenue Account Determination → Check Master Data Relevant for Account Assignment
Inside this activity, you'll find two sub-nodes:
- Materials: Account Assignment Groups - Create entries like 01 (Finished Goods), 02 (Trading Goods), 03 (Services). Use clear, consistent naming. Finance will need to understand these labels.
- Customers: Account Assignment Groups - Create entries like 01 (Domestic), 02 (Export), 03 (Intercompany). Align these with your revenue reporting requirements before creating them - retrofitting later is painful.
Each entry is a two-digit alphanumeric key with a description. Once saved, these become selectable in master data.
Step 2: Assign the Group to Customer Master
Go to transaction XD01 (create) or XD02 (change) → Sales Area Data → Billing tab. The field is labeled "Acct Assmt Grp" or "Account Assignment Group." Assign the appropriate key based on the customer's revenue category. This value will automatically copy to the account assignment group field in the billing document header. You can override it manually in the document if needed, though doing that regularly is a sign your master data setup needs review.
Step 3: Assign the Group to Material Master
Go to transaction MM01 or MM02 → Sales: Sales Org. 2 view. The field is "Acct Assmt Grp" under the Accounting section. Set this based on what type of material or service it is. If your company sells both physical products and subscription services, they should have different material AAGs so revenue posts to separate G/L accounts.
Step 4: Maintain G/L Account Assignments in VKOA
Now go to VKOA and open the condition type KOFI. Select the appropriate table - Table 004 is the most specific and most commonly used because it allows the full combination of customer AAG + material AAG + account key. Enter your combinations and the corresponding G/L account for each. Your FI team should provide the target G/L accounts - do not guess these.
A complete VKOA entry looks like:
Application: V | Condition Type: KOFI | Chart of Accounts: INT | Sales Org: 1000 | Cust AAG: 01 | Mat AAG: 01 | Account Key: ERL → G/L: 400000
Step 5: Test With a Billing Document
Create a test sales order, deliver, and bill it. Try to release the billing document to accounting. If account determination fails, SAP will display an error. Use the error analysis button (the green "check" icon in the billing document) to see which combination it was looking for and what it couldn't find in VKOA. Nine times out of ten, the issue is a missing VKOA entry or a blank AAG field in the customer or material master.
Common Errors and How to Fix Them
The most frequent issue is a billing document that won't release to accounting. This usually means the account determination logic hit a dead end. Check these things in sequence:
- Blank AAG on customer master: Open the payer's customer master (XD02), navigate to the Billing tab, and confirm the account assignment group is filled. If it's blank, SAP can't build a complete key to look up in VKOA.
- Blank AAG on material master: Open MM02 for the material, go to Sales: Sales Org. 2, and verify the field is populated. A common oversight when creating new materials is skipping this view entirely.
- Missing VKOA entry: The combination that SAP is trying to match doesn't exist in VKOA. Either add the entry, or go into the billing document manually - GoTo → Header → Header (for customer AAG) and GoTo → Item → Item Detail (for material AAG) - fill in the values, then release.
- Wrong chart of accounts: If your VKOA entries were copied from another company code with a different chart of accounts, the determination will fail. Confirm your company code's assigned chart of accounts in transaction OB62.
Account Assignment Group vs. Account Assignment Category
These two terms get confused constantly, and they're not the same thing. The account assignment group (covered throughout this article) is an SD concept - it's a two-digit key on customer and material masters used for revenue account determination in billing.
The account assignment category is an MM/FI concept - it's used in purchase orders to indicate what the goods or services are being purchased for: a cost center (K), a sales order (E), an asset (A), a project (P), and so on. It determines which additional account assignment fields (cost center, WBS element, asset number) are required on the PO line item.
If you're configuring SD billing flows, you want the account assignment group. If you're configuring purchasing and goods receipt flows, you want the account assignment category. Don't mix them up in project documentation or you'll waste hours troubleshooting the wrong config node.
Need Targeted Leads?
Search unlimited B2B contacts by title, industry, location, and company size. Export to CSV instantly. $149/month, free to try.
Try the Lead Database →Why This Matters Beyond IT Configuration
If you run an agency or consulting firm that sells to SAP-using enterprises, understanding this level of back-office configuration signals something important: your prospects manage revenue data with serious precision. These are organizations with structured chart of accounts, defined billing hierarchies, and FI teams that care deeply about where revenue lands.
That context is useful if you're building prospect lists targeting SAP implementation partners, SAP consulting firms, or large enterprises with SAP environments. You can filter by industry, company size, and technology stack when sourcing those contacts - this B2B lead database lets you do exactly that with filters for seniority, role, and industry vertical.
For tracking your outbound efforts to these accounts once you've sourced them, the Cold Email Tracking Sheet I put together makes it easy to monitor reply rates and follow-up sequences by segment.
Keeping Your SAP Revenue Configuration Clean Long-Term
The account assignment group setup is not a one-time task. It needs maintenance as your business evolves. When you launch new product lines, add new customer segments, or expand into new geographies, you need to revisit both your AAG definitions and your VKOA entries. A few practices that keep this from becoming a mess:
- Document every AAG combination you create. Keep a living spec that maps each customer AAG and material AAG to the G/L account it targets. Finance and SD need to agree on this mapping before go-live, not after.
- Run periodic audits of master data completeness. Pull a list of active customers and materials with blank AAG fields before month-end close. The easiest way to surface this is a custom report on KNA1/KNVV for customers and MVKE for materials.
- Restrict who can change AAGs in production. An incorrect AAG change on a high-volume material mid-month can redirect millions of dollars in revenue to the wrong G/L. Lock this down with authorization objects.
- Test new combinations in a QA system first. Every new VKOA entry should be validated with a test billing document before it goes to production.
If you want to track the operational KPIs around your billing and revenue workflows - things like invoice release rates, error rates, and cycle times - the Sales KPIs Tracker I offer as a free download is a good starting point for building that visibility.
Final Thoughts
The SAP account assignment group is one of those foundational configuration elements that looks deceptively simple on the surface. Two characters. Set it and forget it. Except when you forget it, your billing team can't close the month and your finance team is opening support tickets.
Get the setup right: define your groups in IMG, assign them to customer and material masters, build complete VKOA entries, and test before go-live. Maintain the mapping documentation, audit master data regularly, and restrict changes in production.
If you're a consultant working through complex SAP SD-FI integration setups and want to go deeper on how revenue configuration connects to broader sales operations strategy, I cover this kind of operational infrastructure inside Galadon Gold.
For further reading on the tools and systems that support outbound sales and pipeline management in parallel with your back-office setup, check out the Cold Email Tech Stack guide - it covers the full toolset from lead sourcing through to CRM and reporting.
Ready to Book More Meetings?
Get the exact scripts, templates, and frameworks Alex uses across all his companies.
You're in! Here's your download:
Access Now →