Profit Center Table in SAP: Key Fields, Usage, and SQL Queries
Profit centers are essential for organizations to track profitability within specific areas of their business. In SAP, profit centers help segregate financial results by different parts of the business, such as departments, products, or projects. Profit center data is maintained in the CEPC table, and like other master data tables in SAP, it integrates with several related tables to give a comprehensive view of financial performance.
In this blog post, we will explore the structure of the CEPC table, highlight its key fields, and demonstrate how to use it with other tables through SQL queries to answer common business questions.
Key Tables for Profit Center Data
- CEPC – Profit Center Master Data
- PRCTR: Profit center
- KOKRS: Controlling area
- DATBI: Valid-to date
- DATAB: Valid-from date
- NAME: Profit center name
- PCTRV: Profit center type
- ERNAM: Created by
- CEPC_T – Profit Center Texts
- PRCTR: Profit center
- KOKRS: Controlling area
- SPRAS: Language key
- LTEXT: Long description (in a specific language)
- SETNODE – Profit Center Group Nodes
- NODEID: Node ID
- SETCLASS: Set class for
Profit Center Table in SAP: Key Fields, Usage, and SQL Queries
Profit centers play a crucial role in the internal management and financial reporting of organizations. In SAP, profit centers allow businesses to segregate financial results and analyze profitability for different organizational units such as products, departments, or geographic locations. For those new to SAP and working on the backend, the CEPC table is the key for understanding and querying profit center master data.
In this comprehensive blog post, we will explore the CEPC table, its important fields, related tables, and how you can use SQL queries to fetch profit center data to answer business questions.
Key Tables for Profit Center Data
- CEPC – Profit Center Master Data Table
- PRCTR: Profit Center
- KOKRS: Controlling Area
- DATBI: Valid-to Date
- DATAB: Valid-from Date
- NAME1: Profit Center Name
- VERAK: Person Responsible
- BUKRS: Company Code
- LOCK_IND: Lock Indicator
- CEPCT – Profit Center Texts
- PRCTR: Profit Center
- KOKRS: Controlling Area
- SPRAS: Language Key
- LTEXT: Long Description (in a specific language)
- GLPCA – Actual Line Items for Profit Centers
- RCLNT: Client
- GL_SIRID: Line Item ID
- GLPCC – Transaction Attributes for Profit Centers
- OBJNR: Object Number
- GLPCP – Plan Line Items for Profit Centers
- RCLNT: Client
- GL_SIRID: Line Item ID
Common Business Questions and How to Use SQL to Answer Them
1. Retrieve Basic Profit Center Information
If you want to retrieve basic information such as the profit center name, controlling area, and responsible person, the CEPC table is the one to query. Here’s a basic SQL query:
SELECT
PRCTR AS "Profit Center",
NAME1 AS "Profit Center Name",
VERAK AS "Person Responsible",
BUKRS AS "Company Code"
FROM
CEPC
WHERE
KOKRS = '1000'; -- Example controlling area
This query pulls key data such as profit center ID, name, and person responsible for that center.
2. Retrieve Profit Center Descriptions in Multiple Languages
The CEPCT table stores the texts for profit centers in different languages. To retrieve the description in English (language key ‘E’), you can use the following query:
SELECT
CEPC.PRCTR AS "Profit Center",
CEPC.NAME1 AS "Name",
CEPCT.LTEXT AS "Description (English)"
FROM
CEPC
INNER JOIN
CEPCT ON CEPC.PRCTR = CEPCT.PRCTR
WHERE
CEPC.KOKRS = '1000' -- Controlling Area
AND CEPCT.SPRAS = 'E'; -- Language Key for English
This will show the name and description of the profit center in English.
3. Retrieve Profit Center Hierarchy Information
To query profit center hierarchies, we can use tables such as SETNODE (for hierarchy nodes) and SETHEADER (for hierarchy definitions). The following query retrieves profit centers and their hierarchy group assignments:
SELECT
CEPC.PRCTR AS "Profit Center",
CEPC.NAME1 AS "Profit Center Name",
SETHEADER.SETCLASS AS "Hierarchy Group"
FROM
CEPC
INNER JOIN
SETNODE ON CEPC.PRCTR = SETNODE.NODEID
INNER JOIN
SETHEADER ON SETNODE.SETID = SETHEADER.SETID
WHERE
SETHEADER.SETCLASS = '0106' -- Class for Profit Centers
AND CEPC.KOKRS = '1000';
This query helps visualize the hierarchy of profit centers in a specific controlling area.
4. Retrieve Profit Center Actual Costs
To analyze the actual costs incurred by a profit center, you can use the GLPCA table (Profit Center Actual Line Items). Here’s a query to get actual cost values for a specific profit center:
SELECT
GLPCA.PRCTR AS "Profit Center",
GLPCA.RCLNT AS "Client",
GLPCA.GL_SIRID AS "Line Item",
GLPCA.WTG001 AS "Actual Cost"
FROM
GLPCA
WHERE
GLPCA.PRCTR = 'PC1000' -- Example Profit Center
AND GLPCA.KOKRS = '1000'; -- Controlling Area
This query will fetch all actual costs for the specified profit center.
5. Analyze Profit Center Performance (Plan vs. Actual)
To compare the planned versus actual costs for a profit center, you can join the GLPCA (Actual) and GLPCP (Plan) tables. Here’s a query to extract this information:
SELECT
GLPCA.PRCTR AS "Profit Center",
GLPCA.WTG001 AS "Actual Cost",
GLPCP.WTG001 AS "Planned Cost",
(GLPCA.WTG001 - GLPCP.WTG001) AS "Variance"
FROM
GLPCA
INNER JOIN
GLPCP ON GLPCA.PRCTR = GLPCP.PRCTR
WHERE
GLPCA.PRCTR = 'PC1000' -- Example Profit Center
AND GLPCA.KOKRS = '1000'; -- Controlling Area
This will return the actual cost, planned cost, and the variance between the two, helping businesses measure performance against their plans.
Advanced Profit Center Analysis
6. Use of Profit Center for Reporting on Segment Level
Profit centers can be linked to segments in SAP to ensure compliance with IFRS or GAAP. This is especially useful when businesses need to create balance sheet and profit and loss (P&L) reports on a segmented basis. By querying the CEPC table along with the SEGMENT field, you can get reports based on segmental reporting.
SELECT
CEPC.PRCTR AS "Profit Center",
CEPC.SEGMENT AS "Segment",
GLPCA.WTG001 AS "Actual Cost"
FROM
CEPC
INNER JOIN
GLPCA ON CEPC.PRCTR = GLPCA.PRCTR
WHERE
CEPC.KOKRS = '1000' -- Example Controlling Area
AND CEPC.SEGMENT = 'SEG100'; -- Example Segment
This query helps in extracting segment-based financial data for a specific profit center.
How to Check Open Purchase Orders (PO) in SAP
Conclusion
The CEPC table, along with its related tables such as CEPCT, GLPCA, and GLPCP, provides a robust foundation for managing profit center data in SAP. By understanding the structure of these tables and using SQL queries effectively, SAP backend users can extract valuable insights about the financial performance of different areas within the organization.
Whether you’re analyzing costs, comparing plan vs. actual data, or exploring profit center hierarchies, these queries will help you get started on the right path. By mastering these concepts, new SAP users can become proficient in handling profit center accounting and delivering valuable business insights.
For further learning, SAP offers a wide array of resources, including standard reports (Transaction FGI0), interactive reporting tools, and drilldown reports that offer real-time data analysis capabilities
Learn about Cost Center Master Data Table in SAP