Sub topic 5
Example: defining enterprise structure in the IMG
This chapter assumes you can open SPRO and the Reference IMG, and that you know the difference between client-dependent and cross-client tables from earlier chapters. It follows one concrete task: creating a new company code and seeing what that does to your Customizing request.
What enterprise structure is
Enterprise structure is the set of organizational units that every transaction refers to. In the IMG it sits under Enterprise Structure, split into Definition (create the units) and Assignment (link them together). A typical Financial Accounting and Logistics chain looks like this:
- A company is used for consolidation. A company code is the smallest unit with its own legally complete set of books.
- A plant is assigned to exactly one company code.
- A controlling area groups company codes for management accounting.
Worked example: a new company code
- Run SPRO and choose SAP Reference IMG.
- Open Enterprise Structure > Definition > Financial Accounting > Edit, Copy, Delete, Check Company Code (transaction OX02 opens the same area).
- Choose Copy, delete, check company code, copy an existing code such as 1000 to a new code, for example Z100, and confirm the copy of dependent data.
- Edit the new code's name, city, country and currency in the Edit Company Code Data activity.
- Open Enterprise Structure > Assignment > Financial Accounting > Assign Company Code to Company and set the company.
Each activity writes to Customizing tables. The company code master data lands in table T001, and the copy action also writes dependent tables. If SCC4 allows recording, the system asks for a Customizing request when you save. Use one request for the whole task, so the definition and the assignment travel together.
Checking the result
Because T001 is client-dependent, Open SQL returns only rows for your logon client. This report lists the codes you just created:
REPORT zdemo_company_codes.
SELECT bukrs, butxt, ort01, waers
FROM t001
ORDER BY bukrs
INTO TABLE @DATA(company_codes).
LOOP AT company_codes INTO DATA(cc).
WRITE: / cc-bukrs, cc-butxt, cc-ort01, cc-waers.
ENDLOOP.Run it in the development client and again in the quality client before you import. Z100 should be missing in the quality client and present after the import.
Common errors
- Assignment imported without the definition. The assignment entries refer to a company code that does not exist in the target. Put both in one request, or import in order.
- Change made but no request prompt. The client is set to not record changes in SCC4. The change exists only locally and cannot be transported.
- Editing in the wrong client. The values were saved in a client that is not the configuration client, so the transport source has nothing to release.
- Changing a company code after go-live. Some fields, such as currency, are locked once postings exist. Define the structure carefully before any business data is posted.
Exercise
You define company code Z100 in one request and, in a second request, assign it to a company. Your colleague imports only the second request into the quality system. What do you expect, and how do you avoid it?
Show answer
The import will fail or give a warning, because the assignment refers to a company code that does not yet exist in the quality system. Avoid this by keeping the definition and assignment in the same request, or by importing the requests in the order they were created.