P_MRPMATERIALSTATUS
P_MRPMATERIALSTATUS is a Composite CDS View in SAP S/4HANA. It reads from 1 data source (I_ProductPlantBasic) and exposes 5 fields with key fields Material, MRPPlant. It has 4 associations to related views.
Data Sources (1)
| Source | Alias | Join Type |
|---|---|---|
| I_ProductPlantBasic | ProductPlant | from |
Associations (4)
| Cardinality | Target | Alias | Condition |
|---|---|---|---|
| [0..1] | P_MRPMaterialPlantStatus | _MaterialPlant | $projection.Material = _MaterialPlant.Material and $projection.MRPPlant = _MaterialPlant.MRPPlant |
| [0..1] | P_MRPMaterialCrossPlantStatus | _Material | $projection.Material = _Material.Material |
| [0..1] | I_MRPMaterialStatusText | _MaterialStatusText | $projection.MRPValidMaterialStatus = _MaterialStatusText.MRPValidMaterialStatus and _MaterialStatusText.Language = $session.system_language |
| [0..1] | I_MRPMaterialStatusCodeText | _MRPMaterialStatusCodeText | $projection.MRPMaterialStatus = _MRPMaterialStatusCodeText.MRPMaterialStatus and _MRPMaterialStatusCodeText.Language = $session.system_language |
Annotations (13)
| Name | Value | Level | Field |
|---|---|---|---|
| ClientHandling.algorithm | #SESSION_VARIABLE | view | |
| Search.searchable | false | view | |
| VDM.private | true | view | |
| VDM.viewType | #COMPOSITE | view | |
| ObjectModel.usageType.serviceQuality | #C | view | |
| ObjectModel.usageType.sizeCategory | #M | view | |
| ObjectModel.usageType.dataClass | #MIXED | view | |
| AccessControl.authorizationCheck | #NOT_REQUIRED | view | |
| AccessControl.personalData.blocking | #NOT_REQUIRED | view | |
| AbapCatalog.sqlViewName | PMRPMATERIALSTAT | view | |
| AbapCatalog.compiler.compareFilter | true | view | |
| AbapCatalog.preserveKey | true | view | |
| AbapCatalog.dataMaintenance | #RESTRICTED | view |
Fields (5)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | Material | Product | Product Sold | |
| KEY | MRPPlant | Plant | Valuation Area | |
| CrossPlantStatusendasMRPMaterialStatus | ||||
| _MaterialStatusText | _MaterialStatusText | |||
| _MRPMaterialStatusCodeText | _MRPMaterialStatusCodeText |
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_MRPMATERIALSTATUS.
-- 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.
CREATE VIEW P_MRPMATERIALSTATUS AS
SELECT
Product AS Material,
Plant AS MRPPlant,
case when _MaterialPlant.ShiftStatusCode is not null and _MaterialPlant.ShiftStatusCode = 'B' then _MaterialPlant.ProfileCode when _Material.ShiftStatusCode is not null and _Material.ShiftStatusCode <> '' then _Material.CrossPlantStatus when _MaterialPlant.ShiftStatusCode is not null then _MaterialPlant.ProfileCode when _Material.ShiftStatusCode is not null then _Material.CrossPlantStatus end as MRPMaterialStatus AS CrossPlantStatusendasMRPMaterialStatus
FROM I_ProductPlantBasic AS ProductPlant
LEFT OUTER JOIN P_MRPMaterialPlantStatus AS _MaterialPlant ON Material = _MaterialPlant.Material AND MRPPlant = _MaterialPlant.MRPPlant -- association [0..1]
LEFT OUTER JOIN P_MRPMaterialCrossPlantStatus AS _Material ON Material = _Material.Material -- association [0..1]
LEFT OUTER JOIN I_MRPMaterialStatusText AS _MaterialStatusText ON MRPValidMaterialStatus = _MaterialStatusText.MRPValidMaterialStatus AND _MaterialStatusText.Language = $session.system_language -- association [0..1]
LEFT OUTER JOIN I_MRPMaterialStatusCodeText AS _MRPMaterialStatusCodeText ON MRPMaterialStatus = _MRPMaterialStatusCodeText.MRPMaterialStatus AND _MRPMaterialStatusCodeText.Language = $session.system_language -- association [0..1]
;
Learn More
- VDM (Virtual Data Model) in SAP S/4HANA Explained
- Types of CDS Views: Basic, Composite, Consumption, and Transactional
- CDS View Annotations — A Complete Guide
- What Is a CDS View in SAP S/4HANA?
- SAP Tables vs CDS Views — Key Differences
- Understanding Data Lineage in SAP S/4HANA
- CDS View Field Mapping and Associations
- Understanding the SAP S/4HANA Data Model
- CDS View Extensions and Custom Fields in SAP S/4HANA
- Released APIs and Stability Contracts in SAP S/4HANA
- BSEG to ACDOCA: The Universal Journal Migration
- Business Partner Migration: KNA1/LFA1 to BUT000
- Material Document Migration: MSEG/MKPF to MATDOC
- How to Find the Right CDS View for an SAP Table
- BW Extractor to CDS View Migration Guide
- S/4HANA CDS View Deprecation: What You Need to Know
- ABAP CDS View Tutorial — From Basics to Real-World Examples
- RAP and CDS Views — Building Transactional Apps in SAP S/4HANA
- Sales Document Status Migration: VBUP/VBUK Removal in S/4HANA
- CO Tables in S/4HANA: COEP, COBK, COSS, COSP to ACDOCA