C_StkKPIGroupComparison

DDL: C_STKKPIGROUPCOMPARISON Type: view_entity CONSUMPTION Package: ODATA_MM_IM_KPITIMESERIES

Stock KPI grouping of delta

C_StkKPIGroupComparison is a Consumption CDS View that provides data about "Stock KPI grouping of delta" in SAP S/4HANA. It reads from 1 data source (I_StkKPIGroupingDeltaComprn) and exposes 21 fields with key fields Material, Plant, StorageLocation, StockIdentifyingBatch, SpecialStockIdfgSupplier. It has 4 associations to related views. Part of development package ODATA_MM_IM_KPITIMESERIES.

Data Sources (1)

SourceAliasJoin Type
I_StkKPIGroupingDeltaComprn I_StkKPIGroupingDeltaComprn from

Parameters (6)

NameTypeDefault
P_StartDateOfPreviousPeriod vdm_v_start_date
P_EndDateOfPreviousPeriod vdm_v_end_date
P_StartDateOfReferencePeriod vdm_v_start_date
P_EndDateOfReferencePeriod vdm_v_end_date
P_PeriodType nsdm_period_type
P_InventoryConsumptionGroup inventory_consumption_group

Associations (4)

CardinalityTargetAliasCondition
[1..1] I_Product _Product $projection.Material = _Product.Product
[1..1] I_ProductPlant _ProductPlant $projection.Material = _ProductPlant.Product and $projection.Plant = _ProductPlant.Plant
[1..1] I_Batch _Batch $projection.Material = _Batch.Material and $projection.Plant = _Batch.Plant and $projection.StockIdentifyingBatch = _Batch.Batch
[0..1] I_WBSElementBasicData _SpclStkIdfgWBSElmntBasicData $projection.SpecialStockIdfgWBSElement = _SpclStkIdfgWBSElmntBasicData.ProjectInternalID

Annotations (10)

NameValueLevelField
AccessControl.authorizationCheck #CHECK view
EndUserText.label Stock KPI grouping of delta view
ObjectModel.usageType.sizeCategory #XXL view
ObjectModel.usageType.serviceQuality #X view
ObjectModel.usageType.dataClass #TRANSACTIONAL view
VDM.viewType #CONSUMPTION view
VDM.private false view
ObjectModel.createEnabled false view
ObjectModel.updateEnabled false view
ObjectModel.deleteEnabled false view

Fields (21)

KeyFieldSource TableSource FieldDescription
KEY Material Material Vehicle Model
KEY Plant Plant Valuation Area
KEY StorageLocation StorageLocation StorageLocation
KEY StockIdentifyingBatch StockIdentifyingBatch
KEY SpecialStockIdfgSupplier SpecialStockIdfgSupplier
KEY SpecialStockIdfgSalesOrder SpecialStockIdfgSalesOrder Stock Ident Header
KEY SpecialStockIdfgSalesOrderItem SpecialStockIdfgSalesOrderItem Stock Ident Item
KEY SpecialStockIdfgWBSElement SpecialStockIdfgWBSElement WBS Internal ID
KEY SpecialStockIdfgCustomer SpecialStockIdfgCustomer
KEY InventoryStockType InventoryStockType Stock Type
KEY InventorySpecialStockType InventorySpecialStockType Special Stock Type
StkQtyDeltaInPercent StkQtyDeltaInPercent
CnsmpnQtyDeltaInPercent CnsmpnQtyDeltaInPercent
InvtryTurnoverDeltaInPercent InvtryTurnoverDeltaInPercent
InvtryAgingDeltaInPercent InvtryAgingDeltaInPercent
RangeOfCvrgDeltaInPercent RangeOfCvrgDeltaInPercent
NumberOfMaterialsHavingStkQty
WBSElementExternalID _SpclStkIdfgWBSElmntBasicData WBSElementExternalID WBS Element External ID
_Product _Product
_ProductPlant _ProductPlant
_Batch _Batch

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_StkKPIGroupComparison.
-- 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.
-- Parameters: P_StartDateOfPreviousPeriod : vdm_v_start_date, P_EndDateOfPreviousPeriod : vdm_v_end_date, P_StartDateOfReferencePeriod : vdm_v_start_date, P_EndDateOfReferencePeriod : vdm_v_end_date, P_PeriodType : nsdm_period_type, P_InventoryConsumptionGroup : inventory_consumption_group

CREATE VIEW C_StkKPIGroupComparison AS
SELECT
  Material,
  Plant,
  StorageLocation,
  StockIdentifyingBatch,
  SpecialStockIdfgSupplier,
  SpecialStockIdfgSalesOrder,
  SpecialStockIdfgSalesOrderItem,
  SpecialStockIdfgWBSElement,
  SpecialStockIdfgCustomer,
  InventoryStockType,
  InventorySpecialStockType,
  StkQtyDeltaInPercent,
  CnsmpnQtyDeltaInPercent,
  InvtryTurnoverDeltaInPercent,
  InvtryAgingDeltaInPercent,
  RangeOfCvrgDeltaInPercent,
  cast(1 as abap.int8) AS NumberOfMaterialsHavingStkQty,
  _SpclStkIdfgWBSElmntBasicData.WBSElementExternalID AS WBSElementExternalID
FROM I_StkKPIGroupingDeltaComprn
LEFT OUTER JOIN I_Product AS _Product ON Material = _Product.Product  -- association [1..1]
LEFT OUTER JOIN I_ProductPlant AS _ProductPlant ON Material = _ProductPlant.Product AND Plant = _ProductPlant.Plant  -- association [1..1]
LEFT OUTER JOIN I_Batch AS _Batch ON Material = _Batch.Material AND Plant = _Batch.Plant AND StockIdentifyingBatch = _Batch.Batch  -- association [1..1]
LEFT OUTER JOIN I_WBSElementBasicData AS _SpclStkIdfgWBSElmntBasicData ON SpecialStockIdfgWBSElement = _SpclStkIdfgWBSElmntBasicData.ProjectInternalID  -- association [0..1]
;