P_DACRCostComponentConsumption

DDL: P_DACRCOSTCOMPONENTCONSUMPTION SQL: PDACRCCSCONS Type: view COMPOSITE

Consumptions for cost components in DACR

P_DACRCostComponentConsumption is a Composite CDS View that provides data about "Consumptions for cost components in DACR" in SAP S/4HANA. It reads from 2 data sources (P_DMVCMLDOCCostComponentSplit, P_MaterialLedgerDocument) and exposes 12 fields with key fields LedgerValuationCurrencyRole, CostEstimate, CostComponentStructure, CostComponent, CostComponentSplitType.

Data Sources (2)

SourceAliasJoin Type
P_DMVCMLDOCCostComponentSplit _ccs from
P_MaterialLedgerDocument _mldoc inner

Annotations (12)

NameValueLevelField
AbapCatalog.sqlViewName PDACRCCSCONS view
AbapCatalog.compiler.compareFilter true view
AbapCatalog.preserveKey true view
AccessControl.authorizationCheck #NOT_REQUIRED view
EndUserText.label Consumptions for cost components in DACR view
ClientHandling.algorithm #SESSION_VARIABLE view
Metadata.ignorePropagatedAnnotations true view
ObjectModel.usageType.serviceQuality #X view
ObjectModel.usageType.sizeCategory #S view
ObjectModel.usageType.dataClass #MIXED view
VDM.private true view
VDM.viewType #COMPOSITE view

Fields (12)

KeyFieldSource TableSource FieldDescription
KEY LedgerValuationCurrencyRole P_DMVCMLDOCCostComponentSplit LedgerValuationCurrencyRole
KEY CostEstimate P_MaterialLedgerDocument CostEstimate
KEY CostComponentStructure P_DMVCMLDOCCostComponentSplit elesmhk
KEY CostComponent P_DMVCMLDOCCostComponentSplit element
KEY CostComponentSplitType P_DMVCMLDOCCostComponentSplit CostComponentSplitType
FiscalYearPeriod P_MaterialLedgerDocument FiscalYearPeriod
Ledger P_MaterialLedgerDocument Ledger
Currency P_DMVCMLDOCCostComponentSplit waers
tot
fix
totll
fixll
@AbapCatalog.sqlViewName: 'PDACRCCSCONS'
@AbapCatalog.compiler.compareFilter: true
@AbapCatalog.preserveKey: true
@AccessControl.authorizationCheck: #NOT_REQUIRED
@EndUserText.label: 'Consumptions for cost components in DACR'

@ClientHandling.algorithm: #SESSION_VARIABLE
@Metadata.ignorePropagatedAnnotations: true
@ObjectModel.usageType:{
  serviceQuality: #X,
  sizeCategory: #S,
  dataClass: #MIXED
}

@VDM.private: true
@VDM.viewType: #COMPOSITE
define view P_DACRCostComponentConsumption
  as select from P_DMVCMLDOCCostComponentSplit as _ccs

    inner join   P_MaterialLedgerDocument      as _mldoc on  _ccs.docref                      = _mldoc.docref
                                                         and _ccs.LedgerValuationCurrencyRole = _mldoc.LedgerValuationCurrencyRole
{
  key _ccs.LedgerValuationCurrencyRole,
  key _mldoc.CostEstimate,
  key _ccs.elesmhk   as CostComponentStructure,
  key _ccs.element   as CostComponent,
  key _ccs.CostComponentSplitType,
      _mldoc.FiscalYearPeriod,
      _mldoc.Ledger,
      _ccs.waers     as Currency,
      @Semantics.amount.currencyCode : 'Currency'
      sum(_ccs.tot ) as tot,
      @Semantics.amount.currencyCode : 'Currency'
      sum(_ccs.fix ) as fix,
      @Semantics.amount.currencyCode : 'Currency'
      sum(_ccs.totll ) as totll,
      @Semantics.amount.currencyCode : 'Currency'
      sum(_ccs.fixll ) as fixll
}
where
      _mldoc.categ = 'VN'
  and _ccs.svrel   = 'X'
  and _ccs.dipa    = ''
  and _ccs.patnr   is initial
group by
  _ccs.LedgerValuationCurrencyRole,
  _mldoc.CostEstimate,
  _ccs.elesmhk,
  _ccs.element,
  _ccs.CostComponentSplitType,
  _mldoc.FiscalYearPeriod,
  _mldoc.Ledger,
  _ccs.waers
/*+[internal] {
"BASEINFO":
{
"FROM":
[
"P_DMVCMLDOCCOSTCOMPONENTSPLIT",
"P_MATERIALLEDGERDOCUMENT"
],
"ASSOCIATED":
[],
"BASE":
[],
"ANNO_REF":
[],
"SCALAR_FUNCTION":
[],
"VERSION":0,
"ANNOREF_EVALUATION_ERROR":""
}
}*/