C_COGSSplitRelevantGLItems
Relevant Items from COGS Split and Original Document
C_COGSSplitRelevantGLItems is a Consumption CDS View that provides data about "Relevant Items from COGS Split and Original Document" in SAP S/4HANA. It reads from 4 data sources (I_GLAccountLineItem, I_GLAccountLineItem, I_COGSSplitSourceAccount, I_Ledger) and exposes 76 fields with key fields Ledger, CompanyCode, FiscalYear, JournalEntry, JournalEntryItem. It has 3 associations to related views.
Data Sources (4)
| Source | Alias | Join Type |
|---|---|---|
| I_GLAccountLineItem | A | from |
| I_GLAccountLineItem | A | union_all |
| I_COGSSplitSourceAccount | COGS_Accounts | inner |
| I_Ledger | I_Ledger | inner |
Associations (3)
| Cardinality | Target | Alias | Condition |
|---|---|---|---|
| [1..*] | I_COGSSplitGLItemRole | _ITEMROLE | _ITEMROLE.DomainValue is not null |
| [0..*] | I_GLAccountTextRawData | _GLAccountText | $projection.ChartOfAccounts = _GLAccountText.ChartOfAccounts and $projection.GLAccount = _GLAccountText.GLAccount |
| [1..1] | C_COGSSplitAndOriginalItem | _OriginalItem | $projection.Ledger = _OriginalItem.Ledger and $projection.CompanyCode = _OriginalItem.CompanyCode and $projection.FiscalYear = _OriginalItem.FiscalYear and $projection.JournalEntry = _OriginalItem.JournalEntry and $projection.JournalEntryItem = _OriginalItem.JournalEntryItem and $projection.GLBusinessTransactionType = _OriginalItem.BusinessTransactionType and $projection.ReferenceDocument = _OriginalItem.ReferenceDocument and $projection.ReferenceDocumentItem = _OriginalItem.ReferenceDocumentItem and $projection.ReferenceDocumentType = _OriginalItem.ReferenceDocumentType and $projection.SourceReferenceDocument = _OriginalItem.SourceReferenceDocument and $projection.SourceReferenceDocumentItem = _OriginalItem.SourceReferenceDocumentItem and $projection.SourceReferenceDocumentType = _OriginalItem.SourceReferenceDocumentType and $projection.PostingDate = _OriginalItem.PostingDate -- Implemented in implementing class or $projection.AccountingDocumentCategory <> 'P' ) |
Annotations (14)
| Name | Value | Level | Field |
|---|---|---|---|
| AbapCatalog.sqlViewName | CCOGSSPLRELGLI | view | |
| AbapCatalog.compiler.compareFilter | true | view | |
| AbapCatalog.preserveKey | true | view | |
| ClientHandling.algorithm | #SESSION_VARIABLE | view | |
| Metadata.allowExtensions | true | view | |
| AccessControl.authorizationCheck | #CHECK | view | |
| ObjectModel.usageType.sizeCategory | #M | view | |
| ObjectModel.usageType.dataClass | #MIXED | view | |
| ObjectModel.usageType.serviceQuality | #C | view | |
| VDM.viewType | #CONSUMPTION | view | |
| EndUserText.label | Relevant Items from COGS Split and Original Document | view | |
| UI.headerInfo.description.value | COGSSplitGLItemRoleName | view | |
| UI.headerInfo.title.type | STANDARD | view | |
| UI.headerInfo.title.value | JournalEntry | view |
Fields (76)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | Ledger | I_GLAccountLineItem | Ledger | Ledger |
| KEY | CompanyCode | I_GLAccountLineItem | CompanyCode | Receiver Company Code |
| KEY | FiscalYear | I_GLAccountLineItem | FiscalYear | G/L Fiscal Year |
| KEY | JournalEntry | I_GLAccountLineItem | AccountingDocument | Journal Entry |
| KEY | JournalEntryItem | |||
| PostingDate | I_GLAccountLineItem | PostingDate | Posting Date for GR | |
| FiscalPeriod | I_GLAccountLineItem | FiscalPeriod | Tax period | |
| Product | I_GLAccountLineItem | Product | Product Sold | |
| Plant | I_GLAccountLineItem | Plant | Valuation Area | |
| CompanyCodeHierarchy | ||||
| CompanyCodeHierarchyNode | ||||
| GLAccountHierarchy | ||||
| GLAccountHierarchyNode | ||||
| GLAccountName | ||||
| GLAccount | I_GLAccountLineItem | GLAccount | General Ledger | |
| AmountInCompanyCodeCurrency | I_GLAccountLineItem | AmountInCompanyCodeCurrency | Local Crcy Amt | |
| BaseUnit | I_GLAccountLineItem | BaseUnit | Unit of Measure | |
| CompanyCodeCurrency | I_GLAccountLineItem | CompanyCodeCurrency | Local Currency | |
| AmountInGlobalCurrency | I_GLAccountLineItem | AmountInGlobalCurrency | Amount in Global Currency | |
| GlobalCurrency | I_GLAccountLineItem | GlobalCurrency | GM Billing Element: Global Currency | |
| Quantity | I_GLAccountLineItem | Quantity | Value | |
| ReferenceDocument | I_GLAccountLineItem | ReferenceDocument | Reference Document | |
| ReferenceDocumentItem | I_GLAccountLineItem | ReferenceDocumentItem | Reference item | |
| ReferenceDocumentType | I_GLAccountLineItem | ReferenceDocumentType | Reference Document Type | |
| SourceReferenceDocument | I_GLAccountLineItem | SourceReferenceDocument | Reference Doc. | |
| SourceReferenceDocumentItem | I_GLAccountLineItem | SourceReferenceDocumentItem | Ref. Doc. Item | |
| SourceReferenceDocumentType | I_GLAccountLineItem | SourceReferenceDocumentType | Ref. procedure | |
| AccountingDocumentCategory | I_GLAccountLineItem | AccountingDocumentCategory | Journal Entry Category | |
| BusinessTransactionType | I_GLAccountLineItem | BusinessTransactionType | Bus.transaction | |
| GLBusinessTransactionType | I_GLAccountLineItem | GLBusinessTransactionType | Transact. Type | |
| SubLedgerAcctLineItemType | I_GLAccountLineItem | SubLedgerAcctLineItemType | SLALineItemType | |
| _SubLedgerAccLineItemType | I_GLAccountLineItem | _SubLedgerAccLineItemType | ||
| SalesOrder | I_GLAccountLineItem | SalesOrder | SD Document | |
| SalesOrderItem | I_GLAccountLineItem | SalesOrderItem | Sales Order Item | |
| _OriginalItem | _OriginalItem | |||
| ChartOfAccounts | I_GLAccountLineItem | ChartOfAccounts | Node Class | |
| OrganizationDivision | I_GLAccountLineItem | OrganizationDivision | Org. Division | |
| _ServiceDocument | I_GLAccountLineItem | _ServiceDocument | ||
| SalesOrganization | I_GLAccountLineItem | SalesOrganization | Sales Organization | |
| _CurrentCostCenter | I_GLAccountLineItem | _CurrentCostCenter | ||
| DistributionChannel | I_GLAccountLineItem | DistributionChannel | RefDistCh-Cust/Mat. | |
| FinancialAccountType | I_GLAccountLineItem | FinancialAccountType | Fin. Account Type | |
| CostCenter | I_GLAccountLineItem | CostCenter | Cost Center | |
| ControllingArea | I_GLAccountLineItem | ControllingArea | Controlling Area | |
| _CurrentProfitCenter | I_GLAccountLineItem | _CurrentProfitCenter | ||
| BusinessArea | I_GLAccountLineItem | BusinessArea | Business Area | |
| FunctionalArea | I_GLAccountLineItem | FunctionalArea | Sendr Fctl Area | |
| Segment | I_GLAccountLineItem | Segment | Segment number | |
| ValuationArea | I_GLAccountLineItem | ValuationArea | Valuation Area | |
| AssetClass | I_GLAccountLineItem | AssetClass | Asset Class | |
| _Order | I_GLAccountLineItem | _Order | ||
| OrderID | I_GLAccountLineItem | OrderID | Order ID | |
| _SalesDocument | I_GLAccountLineItem | _SalesDocument | ||
| SalesDocument | I_GLAccountLineItem | SalesDocument | SD Document | |
| SalesDocumentItem | I_GLAccountLineItem | SalesDocumentItem | Sales Document Item | |
| ServiceDocumentType | I_GLAccountLineItem | ServiceDocumentType | Transaction Type | |
| _AccountingDocumentType | I_GLAccountLineItem | _AccountingDocumentType | ||
| AccountingDocumentType | I_GLAccountLineItem | AccountingDocumentType | Journal Entry Type | |
| ProfitCenter | I_GLAccountLineItem | ProfitCenter | Profit Center | |
| _GLAccountInCompanyCode | I_GLAccountLineItem | _GLAccountInCompanyCode | ||
| _Supplier | I_GLAccountLineItem | _Supplier | ||
| Supplier | I_GLAccountLineItem | Supplier | Supplier | |
| _Customer | I_GLAccountLineItem | _Customer | ||
| Customer | I_GLAccountLineItem | Customer | Sold-to Party | |
| ServiceDocument | I_GLAccountLineItem | ServiceDocument | Transaction ID | |
| CompanyCodeName | ||||
| PlantName | ||||
| BusinessTransactionTypeName | ||||
| AccountingDocumentCategoryP | ||||
| purposeSTANDARD | ||||
| typeFIELDGROUP_REFERENCE | ||||
| labelCOGSSplitBasis | ||||
| position10 | ||||
| CompanyCode | Receiver Company Code | |||
| position10 | ||||
| ProductName |
Derived SQL interpretation, reconstructed from the parsed view metadata (data sources, associations, and field mappings). SAP annotations are omitted and the structure is reformulated as SQL — this is a functional approximation, not the verbatim SAP source.
-- Derived SQL interpretation of CDS view C_COGSSplitRelevantGLItems.
-- Reconstructed from parsed metadata (data sources, associations, fields).
-- SAP annotations are omitted and the structure is reformulated as SQL;
-- this is a functional approximation, not the verbatim SAP source. Some join
-- conditions may be unavailable and a few CDS constructs are kept as-is.
-- SQL view name: CCOGSSPLRELGLI
CREATE VIEW C_COGSSplitRelevantGLItems AS
SELECT
A.Ledger AS Ledger,
A.CompanyCode AS CompanyCode,
A.FiscalYear AS FiscalYear,
A.AccountingDocument AS JournalEntry,
cast( A.LedgerGLLineItem as fis_jeitm ) AS JournalEntryItem,
A.PostingDate AS PostingDate,
A.FiscalPeriod AS FiscalPeriod,
A.Product AS Product,
A.Plant AS Plant,
cast('' as fis_hryid_ccode_42) AS CompanyCodeHierarchy,
cast('' as fis_hrynid_ccode_50) AS CompanyCodeHierarchyNode,
cast('' as fis_glaccthier) AS GLAccountHierarchy,
cast('' as fis_glacct_hrynid_50) AS GLAccountHierarchyNode,
_GLAccountText[1:Language = $session.system_language ].GLAccountName AS GLAccountName,
A.GLAccount AS GLAccount,
A.AmountInCompanyCodeCurrency AS AmountInCompanyCodeCurrency,
A.BaseUnit AS BaseUnit,
A.CompanyCodeCurrency AS CompanyCodeCurrency,
A.AmountInGlobalCurrency AS AmountInGlobalCurrency,
A.GlobalCurrency AS GlobalCurrency,
A.Quantity AS Quantity,
A.ReferenceDocument AS ReferenceDocument,
A.ReferenceDocumentItem AS ReferenceDocumentItem,
A.ReferenceDocumentType AS ReferenceDocumentType,
A.SourceReferenceDocument AS SourceReferenceDocument,
A.SourceReferenceDocumentItem AS SourceReferenceDocumentItem,
A.SourceReferenceDocumentType AS SourceReferenceDocumentType,
A.AccountingDocumentCategory AS AccountingDocumentCategory,
A.BusinessTransactionType AS BusinessTransactionType,
A.GLBusinessTransactionType AS GLBusinessTransactionType,
A.SubLedgerAcctLineItemType AS SubLedgerAcctLineItemType,
A._SubLedgerAccLineItemType AS _SubLedgerAccLineItemType,
A.SalesOrder AS SalesOrder,
A.SalesOrderItem AS SalesOrderItem,
A.ChartOfAccounts AS ChartOfAccounts,
A.OrganizationDivision AS OrganizationDivision,
A._ServiceDocument AS _ServiceDocument,
A.SalesOrganization AS SalesOrganization,
A._CurrentCostCenter AS _CurrentCostCenter,
A.DistributionChannel AS DistributionChannel,
A.FinancialAccountType AS FinancialAccountType,
A.CostCenter AS CostCenter,
A.ControllingArea AS ControllingArea,
A._CurrentProfitCenter AS _CurrentProfitCenter,
A.BusinessArea AS BusinessArea,
A.FunctionalArea AS FunctionalArea,
A.Segment AS Segment,
A.ValuationArea AS ValuationArea,
A.AssetClass AS AssetClass,
A._Order AS _Order,
A.OrderID AS OrderID,
A._SalesDocument AS _SalesDocument,
A.SalesDocument AS SalesDocument,
A.SalesDocumentItem AS SalesDocumentItem,
A.ServiceDocumentType AS ServiceDocumentType,
A._AccountingDocumentType AS _AccountingDocumentType,
A.AccountingDocumentType AS AccountingDocumentType,
A.ProfitCenter AS ProfitCenter,
A._GLAccountInCompanyCode AS _GLAccountInCompanyCode,
A._Supplier AS _Supplier,
A.Supplier AS Supplier,
A._Customer AS _Customer,
A.Customer AS Customer,
A.ServiceDocument AS ServiceDocument,
A._CompanyCode.CompanyCodeName AS CompanyCodeName,
A._Plant.PlantName AS PlantName,
A._BusinessTransactionType._Text[1:Language = $session.system_language ].BusinessTransactionTypeName AS BusinessTransactionTypeName,
A._Product._Text[1:Language = $session.system_language ].ProductName AS AccountingDocumentCategoryP,
purpose : #STANDARD AS purposeSTANDARD,
type : #FIELDGROUP_REFERENCE AS typeFIELDGROUP_REFERENCE,
label : 'COGS Split Basis' AS labelCOGSSplitBasis,
position : 10 AS position10,
importance: #HIGH AS ProductName
FROM I_GLAccountLineItem AS A
INNER JOIN I_COGSSplitSourceAccount AS COGS_Accounts ON /* join condition not captured in parsed metadata */
INNER JOIN I_Ledger ON /* join condition not captured in parsed metadata */
LEFT OUTER JOIN I_COGSSplitGLItemRole AS _ITEMROLE ON /* condition not available in parsed metadata */ -- association [1..*]
LEFT OUTER JOIN I_GLAccountTextRawData AS _GLAccountText ON ChartOfAccounts = _GLAccountText.ChartOfAccounts AND GLAccount = _GLAccountText.GLAccount -- association [0..*]
LEFT OUTER JOIN C_COGSSplitAndOriginalItem AS _OriginalItem ON Ledger = _OriginalItem.Ledger AND CompanyCode = _OriginalItem.CompanyCode AND FiscalYear = _OriginalItem.FiscalYear AND JournalEntry = _OriginalItem.JournalEntry AND JournalEntryItem = _OriginalItem.JournalEntryItem AND GLBusinessTransactionType = _OriginalItem.BusinessTransactionType AND ReferenceDocument = _OriginalItem.ReferenceDocument AND ReferenceDocumentItem = _OriginalItem.ReferenceDocumentItem AND ReferenceDocumentType = _OriginalItem.ReferenceDocumentType AND SourceReferenceDocument = _OriginalItem.SourceReferenceDocument AND SourceReferenceDocumentItem = _OriginalItem.SourceReferenceDocumentItem AND SourceReferenceDocumentType = _OriginalItem.SourceReferenceDocumentType AND PostingDate = _OriginalItem.PostingDate -- association [1..1]
-- UNION ALL with additional select branch(es): I_GLAccountLineItem
;
Learn More
- VDM (Virtual Data Model) in SAP S/4HANA Explained
- Types of CDS Views: Basic, Composite, Consumption, and Transactional
- CDS View Annotations — A Complete Guide
- What Is a CDS View in SAP S/4HANA?
- SAP Tables vs CDS Views — Key Differences
- Understanding Data Lineage in SAP S/4HANA
- CDS View Field Mapping and Associations
- Understanding the SAP S/4HANA Data Model
- CDS View Extensions and Custom Fields in SAP S/4HANA
- Released APIs and Stability Contracts in SAP S/4HANA
- BSEG to ACDOCA: The Universal Journal Migration
- Business Partner Migration: KNA1/LFA1 to BUT000
- Material Document Migration: MSEG/MKPF to MATDOC
- How to Find the Right CDS View for an SAP Table
- BW Extractor to CDS View Migration Guide
- S/4HANA CDS View Deprecation: What You Need to Know
- ABAP CDS View Tutorial — From Basics to Real-World Examples
- RAP and CDS Views — Building Transactional Apps in SAP S/4HANA
- Sales Document Status Migration: VBUP/VBUK Removal in S/4HANA
- CO Tables in S/4HANA: COEP, COBK, COSS, COSP to ACDOCA