P_MltplMatlStk_L4_ALL

DDL: P_MLTPLMATLSTK_L4_ALL Type: view_entity COMPOSITE Package: MBND_CLOUD_BL

Lvl 4: Mat on stock and never on stock

P_MltplMatlStk_L4_ALL is a Composite CDS View that provides data about "Lvl 4: Mat on stock and never on stock" in SAP S/4HANA. It reads from 1 data source (P_MltplMatlStk_L3_ALL) and exposes 46 fields with key fields Material, Plant, StorageLocation, Batch, Supplier. Part of development package MBND_CLOUD_BL.

Data Sources (1)

SourceAliasJoin Type
P_MltplMatlStk_L3_ALL P_MltplMatlStk_L3_ALL from

Parameters (1)

NameTypeDefault
P_EndDate sydate

Annotations (7)

NameValueLevelField
AccessControl.authorizationCheck #NOT_REQUIRED view
Metadata.ignorePropagatedAnnotations true view
ObjectModel.usageType.serviceQuality #X view
ObjectModel.usageType.sizeCategory #XL view
ObjectModel.usageType.dataClass #TRANSACTIONAL view
VDM.viewType #COMPOSITE view
VDM.private true view

Fields (46)

KeyFieldSource TableSource FieldDescription
KEY Material Material Vehicle Model
KEY Plant Plant Valuation Area
KEY StorageLocation StorageLocation StorageLocation
KEY Batch Batch Lot No.
KEY Supplier Supplier Supplier
KEY SDDocument SDDocument SD Document
KEY SDDocumentItem SDDocumentItem
KEY WBSElementInternalID WBSElementInternalID WBS Internal ID
KEY Customer Customer Sold-to Party
KEY ResourceID ResourceID Vehicle ID
KEY InventorySpecialStockType InventorySpecialStockType Special Stock Type
MatlWithStockPostingsCode
CompanyCode CompanyCode Receiver Company Code
MaterialBaseUnit MaterialBaseUnit Valuation Unit
InventoryValuationType InventoryValuationType Valuation Type
Currency Currency Valuation Crcy
VltdUnrestrictedUseStkQty
QualityInspectionStockQuantity
ReturnsBlockedStockQuantity
TransferStockStorageLocQty
TransferStockPlantQuantity
StockInTransitQuantity
BlockedStockQuantity
RestrictedStockQuantity
TiedEmptiesStockQuantity
GoodsReceiptBlockedStockQty
CurrentStockCurVal
QualityInspectionStockCurVal
ReturnsBlockedStockCurVal
TransferStockStorageLocCurVal
TransferStockPlantCurVal
StockInTransitCurVal
BlockedStockCurVal
RestrictedStockCurVal
TiedEmptiesStockCurVal
GoodsReceiptBlockedStockCurVal
CurrentStockValue
QualityInspectionStockValue
ReturnsBlockedStockValue
TransferStockStorageLocValue
TransferStockPlantValue
StockInTransitValue
BlockedStockValue
RestrictedStockValue
TiedEmptiesStockValue
GoodsReceiptBlockedStockValue

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_MltplMatlStk_L4_ALL.
-- 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_EndDate : sydate

CREATE VIEW P_MltplMatlStk_L4_ALL AS
SELECT
  Material,
  Plant,
  StorageLocation,
  Batch,
  Supplier,
  SDDocument,
  SDDocumentItem,
  WBSElementInternalID,
  Customer,
  ResourceID,
  InventorySpecialStockType,
  cast('02' as mmim_sourceid) AS MatlWithStockPostingsCode,
  CompanyCode,
  MaterialBaseUnit,
  InventoryValuationType,
  Currency,
  sum(VltdUnrestrictedUseStkQty) AS VltdUnrestrictedUseStkQty,
  sum(QualityInspectionStockQuantity) AS QualityInspectionStockQuantity,
  sum(ReturnsBlockedStockQuantity) AS ReturnsBlockedStockQuantity,
  sum(TransferStockStorageLocQty) AS TransferStockStorageLocQty,
  sum(TransferStockPlantQuantity) AS TransferStockPlantQuantity,
  sum(StockInTransitQuantity) AS StockInTransitQuantity,
  sum(BlockedStockQuantity) AS BlockedStockQuantity,
  sum(RestrictedStockQuantity) AS RestrictedStockQuantity,
  sum(TiedEmptiesStockQuantity) AS TiedEmptiesStockQuantity,
  sum(GoodsReceiptBlockedStockQty) AS GoodsReceiptBlockedStockQty,
  sum(CurrentStockCurVal) AS CurrentStockCurVal,
  sum(QualityInspectionStockCurVal) AS QualityInspectionStockCurVal,
  sum(ReturnsBlockedStockCurVal) AS ReturnsBlockedStockCurVal,
  sum(TransferStockStorageLocCurVal) AS TransferStockStorageLocCurVal,
  sum(TransferStockPlantCurVal) AS TransferStockPlantCurVal,
  sum(StockInTransitCurVal) AS StockInTransitCurVal,
  sum(BlockedStockCurVal) AS BlockedStockCurVal,
  sum(RestrictedStockCurVal) AS RestrictedStockCurVal,
  sum(TiedEmptiesStockCurVal) AS TiedEmptiesStockCurVal,
  sum(GoodsReceiptBlockedStockCurVal) AS GoodsReceiptBlockedStockCurVal,
  sum(CurrentStockValue) AS CurrentStockValue,
  sum(QualityInspectionStockValue) AS QualityInspectionStockValue,
  sum(ReturnsBlockedStockValue) AS ReturnsBlockedStockValue,
  sum(TransferStockStorageLocValue) AS TransferStockStorageLocValue,
  sum(TransferStockPlantValue) AS TransferStockPlantValue,
  sum(StockInTransitValue) AS StockInTransitValue,
  sum(BlockedStockValue) AS BlockedStockValue,
  sum(RestrictedStockValue) AS RestrictedStockValue,
  sum(TiedEmptiesStockValue) AS TiedEmptiesStockValue,
  sum(GoodsReceiptBlockedStockValue) AS GoodsReceiptBlockedStockValue
FROM P_MltplMatlStk_L3_ALL
;