P_EBPCC_Cost1

DDL: P_EBPCC_COST1 SQL: PEBPCCCOST1 Type: view COMPOSITE Package: ODATA_CO_EB_PROD_COST_CLTR_DET

Event-Based PCC Cost layer 1

P_EBPCC_Cost1 is a Composite CDS View that provides data about "Event-Based PCC Cost layer 1" in SAP S/4HANA. It reads from 2 data sources (P_EBPCC_ProductCostCollector, P_EBPCC_CostUnion) and exposes 30 fields with key fields CompanyCode, ControllingArea, ControllingValueType, CostElement, ControllingKeySubNumber. Part of development package ODATA_CO_EB_PROD_COST_CLTR_DET.

Data Sources (2)

SourceAliasJoin Type
P_EBPCC_ProductCostCollector OrderHeader from
P_EBPCC_CostUnion P_EBPCC_CostUnion inner

Parameters (6)

NameTypeDefault
P_OrderID fis_order_number
P_ProducedProduct fis_produced_product
P_FromFiscalYearPeriod fis_jahrper
P_ToFiscalYearPeriod fis_jahrper
P_Ledger fins_ledger
P_CurrencyRole fac_crcyrole

Annotations (7)

NameValueLevelField
AbapCatalog.sqlViewName PEBPCCCOST1 view
AbapCatalog.compiler.compareFilter true view
AbapCatalog.preserveKey true view
AccessControl.authorizationCheck #NOT_REQUIRED view
ClientHandling.algorithm #SESSION_VARIABLE view
VDM.viewType #COMPOSITE view
VDM.private true view

Fields (30)

KeyFieldSource TableSource FieldDescription
KEY CompanyCode P_EBPCC_ProductCostCollector CompanyCode Receiver Company Code
KEY ControllingArea P_EBPCC_ProductCostCollector ControllingArea Controlling Area
KEY ControllingValueType ControllingValueType
KEY CostElement G/L Account
KEY ControllingKeySubNumber ControllingKeySubNumber
KEY BusinessTransactionCategory BusinessTransactionCategory Business Transaction Category
KEY ControllingDebitCreditCode ControllingDebitCreditCode Dr/Cr ind. CO
KEY OriginSenderObject OriginSenderObject
KEY CtrlgOriginClassification CtrlgOriginClassification
KEY OrderID P_EBPCC_ProductCostCollector OrderID Order ID
KEY AccountAssignmentType AccountAssignmentType Sndr AcctAssgmt Type
KEY PartnerAccountAssignment PartnerAccountAssignment Partner Account Assignment
KEY PartnerObjectType PartnerAccountAssignmentType Partner Account Assignment Type
KEY PartnerCostCenter PartnerCostCenter Sender Cost Ctr
KEY PartnerCostCtrActivityType PartnerCostCtrActivityType Partner Cost Center Activity Type
KEY PartnerBusinessProcess PartnerBusinessProcess Part. Bus. Process
KEY PartnerOrder PartnerOrder Partner Order
KEY UnitOfMeasure UnitOfMeasure Unit Protected Qty
KEY Material Costs Material Vehicle Model
KEY Plant Costs Plant Valuation Area
KEY CostOriginGroup CostOriginGroup Origin Group
KEY SubLedgerAcctLineItemType SubLedgerAcctLineItemType SLALineItemType
KEY IsLotSizeIndependent IsLotSizeIndependent
KEY OriginCostCenter OriginCostCenter
KEY OriginCostCtrActivityType OriginCostCtrActivityType
SystemDate
AmountInDisplayCurrency
FixedAmountInDisplayCurrency
TotalQuantity
FixedQuantity

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 P_EBPCC_Cost1.
-- 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: PEBPCCCOST1
-- Parameters: P_OrderID : fis_order_number, P_ProducedProduct : fis_produced_product, P_FromFiscalYearPeriod : fis_jahrper, P_ToFiscalYearPeriod : fis_jahrper, P_Ledger : fins_ledger, P_CurrencyRole : fac_crcyrole

CREATE VIEW P_EBPCC_Cost1 AS
SELECT
  OrderHeader.CompanyCode AS CompanyCode,
  OrderHeader.ControllingArea AS ControllingArea,
  ControllingValueType,
  cast(CostElement as fis_saknr) AS CostElement,
  ControllingKeySubNumber,
  BusinessTransactionCategory,
  ControllingDebitCreditCode,
  OriginSenderObject,
  CtrlgOriginClassification,
  OrderHeader.OrderID AS OrderID,
  AccountAssignmentType,
  PartnerAccountAssignment,
  PartnerAccountAssignmentType AS PartnerObjectType,
  PartnerCostCenter,
  PartnerCostCtrActivityType,
  PartnerBusinessProcess,
  PartnerOrder,
  UnitOfMeasure,
  Costs.Material AS Material,
  Costs.Plant AS Plant,
  CostOriginGroup,
  SubLedgerAcctLineItemType,
  IsLotSizeIndependent,
  OriginCostCenter,
  OriginCostCtrActivityType,
  $session.system_date AS SystemDate,
  sum(AmountInDisplayCurrency) AS AmountInDisplayCurrency,
  sum(FixedAmountInDisplayCurrency) AS FixedAmountInDisplayCurrency,
  sum(TotalQuantity) AS TotalQuantity,
  sum(FixedQuantity) AS FixedQuantity
FROM P_EBPCC_ProductCostCollector AS OrderHeader
INNER JOIN P_EBPCC_CostUnion ON /* join condition not captured in parsed metadata */
;