Register Login

What is the CI_EKKODB in SAP?

Updated Jun 23, 2024

CI_EKKODB is a standard SAP table within your logistic module that specially deals with the Purchasing (MM) application area. 

What is CI_EKKODB?

CI_EKKODB: Where the 'CI' stands for Customer Include is a customer include file for enhancement of EKKO database table. Purchase order headers in SAP are kept in the "EKKO" table.

EKKO Table: This table contains the Header Information of Purchase Orders in MM (Materials Management module. This table has attributes like the purchase order number

Purpose of CI_EKKODB

Custom Fields: The main purpose of CI_EKKODB is to add custom fields in the EKKO Table without changing the SAP database structure with the help of using Enhancement Framework

Data Extension: This allows organizations to extend the standard purchase order header data with additional custom-specific fields based on their business level of customization.

How to Use CI_EKKODB

  1. Accessing Enhancement: You can add fields to CI_EKKODB through the ABAP Dictionary. It is accessed by navigating to the SE11 transaction code (ABAP Dictionary).
  2. Creating Fields:
    • Open the EKKO table in SE11.
    • Use the "Append Structure" functionality to create a new append structure if it does not already exist.
    • Add the desired custom fields to this append structure.
  3. Activation: After adding custom fields, the structure needs to be activated. This ensures that the new fields are available in the EKKO table.
  4. Data Maintenance: Ensure that the custom fields are maintained and populated correctly during purchase order processing. This may require custom coding in user exits, BADIs, or enhancement spots.

How to Use CI_EKKODB

In the image on the right (after pressing Display), you can see all of the fields of the context CI_EKKODB declared in DDIC and defined at runtime, from an access enhancement perspective. It is available by going to the transaction code SE11 (ABAP Dictionary).

Step 1) Accessing Enhancement: The fields can be added to CI_EKKODB via ABAP Dictionary. It is accessed by going to T-code SE11

Step 2) Creating Fields:

  • Open the EKKO table in t-code SE11.
  • Use Append Structure function to create a new append structure.
  • Enhance this append structure with your required custom fields.

Step 3) Activation: The append structure needs to be activated once custom fields are added. This means that the new fields can now be maintained in the EKKO table.

Step 4) Data Maintenance: Make sure that the new custom fields are maintained and populated appropriately in purchase order handling .This may involve a customization in User exits, BADIs or enhancement spots.

Important Considerations

  • Upgrade Safety: Since CI_EKKODB is a customer include structure, it ensures that custom enhancements are upgrade-safe, meaning they are less likely to be affected by SAP upgrades.
  • Performance Impact: Adding fields to the EKKO table via CI_EKKODB can impact performance. It is essential to ensure that only necessary fields are added and proper indexing is considered if required.
  • Consistency: Custom fields added should be consistently populated and managed to avoid data integrity issues.

Important Considerations

  • Upgrade Safety: Since CI_EKKODB is a customer-inclusive structure, it ensures the custom enhancement will be upgrade- safe ie not affected by SAP system upgrades.
  • Performance Impact: Adding fields in EKKO table by CI_EKKODB can impact performance. It's important to be sure that you only add the fields that are needed and index where appropriate.
  • Consistency: Custom fields are populated and managed in a consistent way to ensure data consistency.

Example Use Case

For example, the company wants to keep track of information such as Project Code and Approval Status at the purchase order header level but these fields are not available in the standard EKKO table. We can add these fields in the EKKO table using CI_EKKODB:

  • Add project code and approval status as new fields into the CI_EKKODB structure
  • The logic should be implemented in the SAP system to ensure these fields are correctly filled out when creating or modifying a purchase order.


CI_EKKODB is a good tool to extend the SAP standard functionality to meet a specific business requirement and make the MM enhancement future-ready.