P_CurrentBufferMatlBOM

DDL: P_CURRENTBUFFERMATLBOM SQL: PCURBUFMATLBOM Type: view CONSUMPTION

Current BOM for Buffered Materials

P_CurrentBufferMatlBOM is a Consumption CDS View that provides data about "Current BOM for Buffered Materials" in SAP S/4HANA. It reads from 2 data sources (P_CurrentBufferMatlBOM1, P_TimeDependentBufferLevels) and exposes 27 fields with key fields Material, Plant, MRPArea, BillOfMaterialUUID, ParentComponent. It has 1 association to related views.

Data Sources (2)

SourceAliasJoin Type
P_CurrentBufferMatlBOM1 _CurrentBOM from
P_TimeDependentBufferLevels _StockActual union_all

Associations (1)

CardinalityTargetAliasCondition
[1..*] I_StockLevelPrpslBOM _BOMProposal $projection.BillOfMaterialUUID = _BOMProposal.BillOfMaterialUUID

Annotations (7)

NameValueLevelField
ClientHandling.algorithm #SESSION_VARIABLE view
AbapCatalog.sqlViewName PCURBUFMATLBOM view
AbapCatalog.compiler.compareFilter true view
AccessControl.authorizationCheck #NOT_REQUIRED view
EndUserText.label Current BOM for Buffered Materials view
VDM.private true view
VDM.viewType #CONSUMPTION view

Fields (27)

KeyFieldSource TableSource FieldDescription
KEY Material Material Vehicle Model
KEY Plant Plant Valuation Area
KEY MRPArea MRPArea MRP Area
KEY BillOfMaterialUUID BillOfMaterialUUID Character Field of Length 12
KEY ParentComponent
KEY ParentPlant ParentPlant Valuation Area
KEY BillOfMaterialComponent Component
KEY ComponentPlant ComponentPlant Valuation Area
ComponentMRPArea ComponentMRPArea MRP Area
ParentMRPArea ParentMRPArea MRP Area
SourceOfSupply P_CurrentBufferMatlBOM1 SourceOfSupply
CurrentLeadTime P_CurrentBufferMatlBOM1 CurrentLeadTime
CurrentLeadTimeCalcMethod P_CurrentBufferMatlBOM1 CurrentLeadTimeCalcMethod
Material Vehicle Model
KEY Plant P_TimeDependentBufferLevels Plant Valuation Area
KEY MRPArea P_TimeDependentBufferLevels MRPArea MRP Area
KEY BillOfMaterialUUID P_TimeDependentBufferLevels BillOfMaterialUUID Character Field of Length 12
KEY ParentComponent _BOMProposal ParentComponent
KEY ParentPlantendasParentPlant
KEY BillOfMaterialComponent _BOMProposal BillOfMaterialComponent Component
KEY ComponentPlantendasComponentPlant
ComponentMRPAreaendasComponentMRPArea
ParentMRPAreaendasParentMRPArea
SourceOfSupply _BOMProposal ComponentSOS
CurrentLeadTime _BOMProposal ComponentLeadTime
CurrentLeadTimeCalcMethod _BOMProposal LeadTimeCalculationMethod
_BOMProposal _BOMProposal

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_CurrentBufferMatlBOM.
-- 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: PCURBUFMATLBOM

CREATE VIEW P_CurrentBufferMatlBOM AS
SELECT
  Material,
  Plant,
  MRPArea,
  BillOfMaterialUUID,
  cast('' as pph_parent_bom_comp) AS ParentComponent,
  ParentPlant,
  cast(_CurrentBOM.Material as idnrk) AS BillOfMaterialComponent,
  ComponentPlant,
  ComponentMRPArea,
  ParentMRPArea,
  _CurrentBOM.SourceOfSupply AS SourceOfSupply,
  _CurrentBOM.CurrentLeadTime AS CurrentLeadTime,
  _CurrentBOM.CurrentLeadTimeCalcMethod AS CurrentLeadTimeCalcMethod,
  case when _BOMProposal.ParentPlant is null then _StockActual.Plant else _BOMProposal.ParentPlant end as ParentPlant AS ParentPlantendasParentPlant,
  case when _BOMProposal.ComponentPlant is null then _StockActual.Plant else _BOMProposal.ComponentPlant end as ComponentPlant AS ComponentPlantendasComponentPlant,
  case when _BOMProposal.ComponentMRPArea is null then _StockActual.MRPArea else _BOMProposal.ComponentMRPArea end as ComponentMRPArea AS ComponentMRPAreaendasComponentMRPArea,
  case when _BOMProposal.ParentMRPArea is null then _StockActual.MRPArea else _BOMProposal.ParentMRPArea end as ParentMRPArea AS ParentMRPAreaendasParentMRPArea
FROM P_CurrentBufferMatlBOM1 AS _CurrentBOM
LEFT OUTER JOIN I_StockLevelPrpslBOM AS _BOMProposal ON BillOfMaterialUUID = _BOMProposal.BillOfMaterialUUID  -- association [1..*]
-- UNION ALL with additional select branch(es): P_TimeDependentBufferLevels
;