I_ActualPlanServiceMarginCube
Actual and Plan Service Margin - Cube
I_ActualPlanServiceMarginCube is a Composite CDS View (Cube) that provides data about "Actual and Plan Service Margin - Cube" in SAP S/4HANA. It reads from 1 data source (I_GLAcctLineItemSemTagGLAcct) and exposes 111 fields with key fields Ledger, SourceLedger, CompanyCode, FiscalYear, AccountingDocument. It has 10 associations to related views.
Data Sources (1)
| Source | Alias | Join Type |
|---|---|---|
| I_GLAcctLineItemSemTagGLAcct | I_GLAcctLineItemSemTagGLAcct | from |
Associations (10)
| Cardinality | Target | Alias | Condition |
|---|---|---|---|
| [0..1] | I_MargAnlysProdAndSrvcObjType | _ObjectType | $projection.AccountAssignmentType = _ObjectType.MarginAnalysisObjectType |
| [0..1] | I_ServiceDocument | _SolutionOrder | $projection.BusinessSolutionOrder = _SolutionOrder.ServiceDocument and _SolutionOrder.ServiceObjectType = 'BUS2000172' |
| [0..1] | I_AcctgServiceDocumentType | _ServiceDocumentTypeNew | $projection.ServiceDocumentType = _ServiceDocumentTypeNew.ServiceDocumentType |
| [0..1] | I_AccountingServiceDocument | _ServiceDocumentNew | $projection.ServiceDocumentType = _ServiceDocumentNew.ServiceDocumentType and $projection.ServiceDocument = _ServiceDocumentNew.ServiceDocument |
| [0..1] | I_AcctgSrvcDocumentItemBasic | _ServiceDocumentItemNew | $projection.ServiceDocumentType = _ServiceDocumentItemNew.ServiceDocumentType and $projection.ServiceDocument = _ServiceDocumentItemNew.ServiceDocument and $projection.ServiceDocumentItem = _ServiceDocumentItemNew.ServiceDocumentItem |
| [0..1] | I_AcctgServiceDocumentType | _ServiceContractTypeNew | $projection.ServiceContractType = _ServiceContractTypeNew.ServiceDocumentType |
| [0..1] | I_AccountingServiceDocument | _ServiceContractNew | $projection.ServiceContractType = _ServiceContractNew.ServiceDocumentType and $projection.ServiceContract = _ServiceContractNew.ServiceDocument |
| [0..1] | I_AcctgSrvcDocumentItemBasic | _ServiceContractItemNew | $projection.ServiceContractType = _ServiceContractItemNew.ServiceDocumentType and $projection.ServiceContract = _ServiceContractItemNew.ServiceDocument and $projection.ServiceContractItem = _ServiceContractItemNew.ServiceDocumentItem |
| [0..*] | I_SemTagGLAccountHierarchy | _Hierarchy | $projection.GLAccountHierarchy = _Hierarchy.GLAccountHierarchy |
| [1..1] | E_JournalEntryItem | _Extension_acdoca | $projection.SourceLedger = _Extension_acdoca.SourceLedger and $projection.CompanyCode = _Extension_acdoca.CompanyCode and $projection.FiscalYear = _Extension_acdoca.FiscalYear and $projection.AccountingDocument = _Extension_acdoca.AccountingDocument and $projection.LedgerGLLineItem = _Extension_acdoca.LedgerGLLineItem |
Annotations (13)
| Name | Value | Level | Field |
|---|---|---|---|
| Analytics.technicalName | IACTLPLNSRVCMARG | view | |
| Analytics.internalName | #LOCAL | view | |
| VDM.viewType | #COMPOSITE | view | |
| AccessControl.authorizationCheck | #MANDATORY | view | |
| Analytics.dataCategory | #CUBE | view | |
| ObjectModel.usageType.sizeCategory | #XXL | view | |
| ObjectModel.usageType.serviceQuality | #D | view | |
| ObjectModel.usageType.dataClass | #MIXED | view | |
| ObjectModel.modelingPattern | #ANALYTICAL_CUBE | view | |
| AccessControl.personalData.blocking | #REQUIRED | view | |
| Metadata.allowExtensions | true | view | |
| Metadata.ignorePropagatedAnnotations | true | view | |
| EndUserText.label | Actual and Plan Service Margin - Cube | view |
Fields (111)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | Ledger | Ledger | Ledger | |
| KEY | SourceLedger | SourceLedger | Source Ledger | |
| KEY | CompanyCode | CompanyCode | Receiver Company Code | |
| KEY | FiscalYear | FiscalYear | G/L Fiscal Year | |
| KEY | AccountingDocument | AccountingDocument | Journal Entry | |
| KEY | LedgerGLLineItem | LedgerGLLineItem | Journal Entry Item | |
| KEY | GLAccountHierarchy | GLAccountHierarchy | ||
| KEY | SemanticTag | SemanticTag | Semantic Tag | |
| KEY | ValidityStartDate | ValidityStartDate | Validity Start Date | |
| KEY | ValidityEndDate | ValidityEndDate | ValidTo | |
| KEY | FinancialPlanningReqTransSqnc | |||
| KEY | FinancialPlanningDataPacket | |||
| KEY | FinancialPlanningEntryItem | |||
| PlanningCategory | ||||
| ActualPlanCode | ||||
| FiscalYearVariant | FiscalYearVariant | FY Variant | ||
| FiscalPeriod | FiscalPeriod | Tax period | ||
| FiscalYearPeriod | FiscalYearPeriod | Period/Year | ||
| ServiceContract | ServiceContract | Transaction ID | ||
| ServiceContractItem | ServiceContractItem | Item Number in Doc. | ||
| BusinessSolutionOrder | BusinessSolutionOrder | Solution Order | ||
| BusinessSolutionOrderItem | BusinessSolutionOrderItem | Solution Order Item | ||
| ProviderContract | ProviderContract | Contract | ||
| ProviderContractItem | ProviderContractItem | Contract Item | ||
| SoldProduct | SoldProduct | Product Sold | ||
| ServiceContractType | ServiceContractType | |||
| AccountAssignmentType | AccountAssignmentType | Sndr AcctAssgmt Type | ||
| ProjectExternalID | ProjectExternalID | Project def. | ||
| ProfitCenter | ProfitCenter | Profit Center | ||
| ServiceDocumentType | ServiceDocumentType | Transaction Type | ||
| ServiceDocument | ServiceDocument | Transaction ID | ||
| ServiceDocumentItem | ServiceDocumentItem | Service Document | ||
| BillToParty | BillToParty | Inv. Recipient | ||
| BusinessTransactionType | BusinessTransactionType | Bus.transaction | ||
| Customer | Customer | Sold-to Party | ||
| CustomerGroup | CustomerGroup | Customer Group | ||
| GLAccount | GLAccount | General Ledger | ||
| CustomerSupplierIndustry | CustomerSupplierIndustry | Industry | ||
| SoldProductGroup | SoldProductGroup | Product Sold Group | ||
| SalesOrder | SalesOrder | SD Document | ||
| SalesOrderItem | SalesOrderItem | Sales Order Item | ||
| SalesDocument | SalesDocument | SD Document | ||
| SalesOrganization | SalesOrganization | Sales Organization | ||
| ShipToParty | ShipToParty | Ship-To Party (obsolete) | ||
| ChartOfAccounts | ChartOfAccounts | Node Class | ||
| ControllingArea | ControllingArea | Controlling Area | ||
| BaseUnit | BaseUnit | Unit of Measure | ||
| Quantity | Quantity | Value | ||
| BillableControl | BillableControl | Billable Control | ||
| DistributionChannel | DistributionChannel | RefDistCh-Cust/Mat. | ||
| OrganizationDivision | OrganizationDivision | Org. Division | ||
| Equipment | Equipment | Equipment check | ||
| FunctionalArea | FunctionalArea | Sendr Fctl Area | ||
| PartnerCostCtrActivityType | PartnerCostCtrActivityType | Partner Cost Center Activity Type | ||
| PersonnelNumber | PersonnelNumber | Personnel No. | ||
| Plant | Plant | Valuation Area | ||
| CustomerSupplierCountry | CustomerSupplierCountry | Customer or Supplier Country/Region | ||
| WBSElement | WBS Internal ID | |||
| SalesDistrict | SalesDistrict | Sales District | ||
| Segment | Segment | Segment number | ||
| GlobalCurrency | GlobalCurrency | GM Billing Element: Global Currency | ||
| AmountInGlobalCurrency | AmountInGlobalCurrency | Amount in Global Currency | ||
| CompanyCodeCurrency | CompanyCodeCurrency | Local Currency | ||
| AmountInCompanyCodeCurrency | AmountInCompanyCodeCurrency | Local Crcy Amt | ||
| InvertedAmtInCoCodeCurrency | ||||
| LedgerFiscalYear | LedgerFiscalYear | |||
| _ProjectExternalID | _ProjectExternalID | |||
| _SourceLedger | _SourceLedger | |||
| _JournalEntry | _JournalEntry | |||
| _CompanyCodeCurrency | _CompanyCodeCurrency | |||
| _BaseUnit | _BaseUnit | |||
| _Hierarchy | _Hierarchy | |||
| _SemanticTag | _SemanticTag | |||
| _CurrentProfitCenter | _CurrentProfitCenter | |||
| _CustomerSupplierCountry | _CustomerSupplierCountry | |||
| _GLAccountInCompanyCode | _GLAccountInCompanyCode | |||
| _CompanyCode | _CompanyCode | |||
| _FiscalYear | _FiscalYear | |||
| _Ledger | _Ledger | |||
| _ObjectType | _ObjectType | |||
| _SalesOrder | _SalesOrder | |||
| _SalesOrderItem | _SalesOrderItem | |||
| _SalesDocument | _SalesDocument | |||
| _ServiceContractNew | _ServiceContractNew | |||
| _ServiceContractItemNew | _ServiceContractItemNew | |||
| _ServiceContractTypeNew | _ServiceContractTypeNew | |||
| _ProviderContract | _ProviderContract | |||
| _ProviderContractItem | _ProviderContractItem | |||
| _Customer | _Customer | |||
| _CustomerGroup | _CustomerGroup | |||
| _ShipToParty | _ShipToParty | |||
| _SoldProduct | _SoldProduct | |||
| _SoldProductGroup | _SoldProductGroup | |||
| _ProfitCenter | _ProfitCenter | |||
| _SolutionOrder | _SolutionOrder | |||
| _ServiceDocumentTypeNew | _ServiceDocumentTypeNew | |||
| _ServiceDocumentNew | _ServiceDocumentNew | |||
| _ServiceDocumentItemNew | _ServiceDocumentItemNew | |||
| _SalesOrganization | _SalesOrganization | |||
| _BillToParty | _BillToParty | |||
| _BusinessTransactionType | _BusinessTransactionType | |||
| _ChartOfAccounts | _ChartOfAccounts | |||
| _ControllingArea | _ControllingArea | |||
| _DistributionChannel | _DistributionChannel | |||
| _Equipment | _Equipment | |||
| _FunctionalArea | _FunctionalArea | |||
| _GLAccountInChartOfAccounts | _GLAccountInChartOfAccounts | |||
| _FiscalYearVariant | _FiscalYearVariant | |||
| _PartnerCostCtrActivityType | _PartnerCostCtrActivityType | |||
| _Plant | _Plant | |||
| _SalesDistrict | _SalesDistrict |
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 I_ActualPlanServiceMarginCube.
-- 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.
CREATE VIEW I_ActualPlanServiceMarginCube AS
SELECT
Ledger,
SourceLedger,
CompanyCode,
FiscalYear,
AccountingDocument,
LedgerGLLineItem,
GLAccountHierarchy,
SemanticTag,
ValidityStartDate,
ValidityEndDate,
cast(cast('00000000000000000000000' as abap.numc(23))as fis_fp_request_tsn) AS FinancialPlanningReqTransSqnc,
cast(cast('000000' as abap.numc(6)) as fis_fp_data_packet) AS FinancialPlanningDataPacket,
cast(0 as fis_fp_entry_item_new) AS FinancialPlanningEntryItem,
cast(cast( 'ACT01' as abap.char( 5 )) as fcom_category) AS PlanningCategory,
cast(cast( 'P' as abap.char (1)) as fis_actual_plan_code) AS ActualPlanCode,
FiscalYearVariant,
FiscalPeriod,
FiscalYearPeriod,
ServiceContract,
ServiceContractItem,
BusinessSolutionOrder,
BusinessSolutionOrderItem,
ProviderContract,
ProviderContractItem,
SoldProduct,
ServiceContractType,
AccountAssignmentType,
ProjectExternalID,
ProfitCenter,
ServiceDocumentType,
ServiceDocument,
ServiceDocumentItem,
BillToParty,
BusinessTransactionType,
Customer,
CustomerGroup,
GLAccount,
CustomerSupplierIndustry,
SoldProductGroup,
SalesOrder,
SalesOrderItem,
SalesDocument,
SalesOrganization,
ShipToParty,
ChartOfAccounts,
ControllingArea,
BaseUnit,
Quantity,
BillableControl,
DistributionChannel,
OrganizationDivision,
Equipment,
FunctionalArea,
PartnerCostCtrActivityType,
PersonnelNumber,
Plant,
CustomerSupplierCountry,
cast( WBSElement as fis_wbs_no_conv preserving type ) AS WBSElement,
SalesDistrict,
Segment,
GlobalCurrency,
AmountInGlobalCurrency,
CompanyCodeCurrency,
AmountInCompanyCodeCurrency,
cast(( AmountInCompanyCodeCurrency * -1 ) as fis_hsl_inverted) AS InvertedAmtInCoCodeCurrency,
LedgerFiscalYear
FROM I_GLAcctLineItemSemTagGLAcct
LEFT OUTER JOIN I_MargAnlysProdAndSrvcObjType AS _ObjectType ON AccountAssignmentType = _ObjectType.MarginAnalysisObjectType -- association [0..1]
LEFT OUTER JOIN I_ServiceDocument AS _SolutionOrder ON BusinessSolutionOrder = _SolutionOrder.ServiceDocument AND _SolutionOrder.ServiceObjectType = 'BUS2000172' -- association [0..1]
LEFT OUTER JOIN I_AcctgServiceDocumentType AS _ServiceDocumentTypeNew ON ServiceDocumentType = _ServiceDocumentTypeNew.ServiceDocumentType -- association [0..1]
LEFT OUTER JOIN I_AccountingServiceDocument AS _ServiceDocumentNew ON ServiceDocumentType = _ServiceDocumentNew.ServiceDocumentType AND ServiceDocument = _ServiceDocumentNew.ServiceDocument -- association [0..1]
LEFT OUTER JOIN I_AcctgSrvcDocumentItemBasic AS _ServiceDocumentItemNew ON ServiceDocumentType = _ServiceDocumentItemNew.ServiceDocumentType AND ServiceDocument = _ServiceDocumentItemNew.ServiceDocument AND ServiceDocumentItem = _ServiceDocumentItemNew.ServiceDocumentItem -- association [0..1]
LEFT OUTER JOIN I_AcctgServiceDocumentType AS _ServiceContractTypeNew ON ServiceContractType = _ServiceContractTypeNew.ServiceDocumentType -- association [0..1]
LEFT OUTER JOIN I_AccountingServiceDocument AS _ServiceContractNew ON ServiceContractType = _ServiceContractNew.ServiceDocumentType AND ServiceContract = _ServiceContractNew.ServiceDocument -- association [0..1]
LEFT OUTER JOIN I_AcctgSrvcDocumentItemBasic AS _ServiceContractItemNew ON ServiceContractType = _ServiceContractItemNew.ServiceDocumentType AND ServiceContract = _ServiceContractItemNew.ServiceDocument AND ServiceContractItem = _ServiceContractItemNew.ServiceDocumentItem -- association [0..1]
LEFT OUTER JOIN I_SemTagGLAccountHierarchy AS _Hierarchy ON GLAccountHierarchy = _Hierarchy.GLAccountHierarchy -- association [0..*]
LEFT OUTER JOIN E_JournalEntryItem AS _Extension_acdoca ON SourceLedger = _Extension_acdoca.SourceLedger AND CompanyCode = _Extension_acdoca.CompanyCode AND FiscalYear = _Extension_acdoca.FiscalYear AND AccountingDocument = _Extension_acdoca.AccountingDocument AND LedgerGLLineItem = _Extension_acdoca.LedgerGLLineItem -- association [1..1]
;
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