P_PriceVariance4
Price Variance 4
P_PriceVariance4 is a Consumption CDS View that provides data about "Price Variance 4" in SAP S/4HANA. It reads from 1 data source (I_PurchaseOrderHistory) and exposes 24 fields with key fields PurchaseOrder, PurchaseOrderItem. It has 2 associations to related views.
Data Sources (1)
| Source | Alias | Join Type |
|---|---|---|
| I_PurchaseOrderHistory | History | from |
Parameters (2)
| Name | Type | Default |
|---|---|---|
| P_StartDate | budat | |
| P_EndDate | budat |
Associations (2)
| Cardinality | Target | Alias | Condition |
|---|---|---|---|
| [1..1] | I_PurchaseOrder | _PurchaseOrder | $projection.PurchaseOrder = _PurchaseOrder.PurchaseOrder |
| [1..1] | I_PurchaseOrderItem | _PurchaseOrderItem | $projection.PurchaseOrder = _PurchaseOrderItem.PurchaseOrder and $projection.PurchaseOrderItem = _PurchaseOrderItem.PurchaseOrderItem |
Annotations (6)
| Name | Value | Level | Field |
|---|---|---|---|
| AbapCatalog.sqlViewName | PMMPRICEVAR4 | view | |
| VDM.viewType | #CONSUMPTION | view | |
| VDM.private | true | view | |
| AccessControl.authorizationCheck | #CHECK | view | |
| AccessControl.personalData.blocking | #NOT_REQUIRED | view | |
| EndUserText.label | Price Variance 4 | view |
Fields (24)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | PurchaseOrder | I_PurchaseOrderHistory | PurchaseOrder | Purchasing Document |
| KEY | PurchaseOrderItem | I_PurchaseOrderHistory | PurchaseOrderItem | Purchasing Document Item |
| PurchaseOrderDate | _PurchaseOrder | PurchaseOrderDate | PO Date | |
| PurchasingOrganization | _PurchaseOrder | PurchasingOrganization | Purchasing Organization | |
| PurchasingGroup | _PurchaseOrder | PurchasingGroup | Purchasing Group | |
| Supplier | _PurchaseOrder | Supplier | Supplier | |
| PurchaseOrderType | ||||
| Material | _PurchaseOrderItem | Material | Vehicle Model | |
| MaterialGroup | _PurchaseOrderItem | MaterialGroup | Product Group | |
| Plant | _PurchaseOrderItem | Plant | Valuation Area | |
| CompanyCode | _PurchaseOrderItem | CompanyCode | Receiver Company Code | |
| PurchasingDocumentCategory | _PurchaseOrderItem | PurchaseOrderCategory | Doc. Category | |
| NetPriceAmount | _PurchaseOrderItem | NetPriceAmount | Net Price | |
| NetPriceQuantity | _PurchaseOrderItem | NetPriceQuantity | Price Unit | |
| OrderQuantity | _PurchaseOrderItem | OrderQuantity | Quantity | |
| PurchaseOrderQuantityUnit | _PurchaseOrderItem | PurchaseOrderQuantityUnit | Order Unit | |
| NetAmount | _PurchaseOrderItem | NetAmount | Stated Amount | |
| DocumentCurrency | _PurchaseOrder | DocumentCurrency | Document Currency | |
| Quantity | I_PurchaseOrderHistory | Quantity | Value | |
| InvoiceAmountInFrgnCurrency | I_PurchaseOrderHistory | InvoiceAmountInFrgnCurrency | Invc. Amt Frgn Crcy | |
| PurchaseOrderAmount | I_PurchaseOrderHistory | InvoiceAmtInCoCodeCrcy | Ord.Set.Value | |
| InvoiceCurrency | I_PurchaseOrderHistory | Currency | Valuation Crcy | |
| InvoiceDate | I_PurchaseOrderHistory | PostingDate | Posting Date for GR | |
| OrderPriceUnit | OrderPriceUnit | Order Price Un. |
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_PriceVariance4.
-- 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: PMMPRICEVAR4
-- Parameters: P_StartDate : budat, P_EndDate : budat
CREATE VIEW P_PriceVariance4 AS
SELECT
History.PurchaseOrder AS PurchaseOrder,
History.PurchaseOrderItem AS PurchaseOrderItem,
_PurchaseOrder.PurchaseOrderDate AS PurchaseOrderDate,
_PurchaseOrder.PurchasingOrganization AS PurchasingOrganization,
_PurchaseOrder.PurchasingGroup AS PurchasingGroup,
_PurchaseOrder.Supplier AS Supplier,
_PurchaseOrderItem._PurchaseOrder.PurchaseOrderType AS PurchaseOrderType,
_PurchaseOrderItem.Material AS Material,
_PurchaseOrderItem.MaterialGroup AS MaterialGroup,
_PurchaseOrderItem.Plant AS Plant,
_PurchaseOrderItem.CompanyCode AS CompanyCode,
_PurchaseOrderItem.PurchaseOrderCategory AS PurchasingDocumentCategory,
_PurchaseOrderItem.NetPriceAmount AS NetPriceAmount,
_PurchaseOrderItem.NetPriceQuantity AS NetPriceQuantity,
_PurchaseOrderItem.OrderQuantity AS OrderQuantity,
_PurchaseOrderItem.PurchaseOrderQuantityUnit AS PurchaseOrderQuantityUnit,
_PurchaseOrderItem.NetAmount AS NetAmount,
_PurchaseOrder.DocumentCurrency AS DocumentCurrency,
History.Quantity AS Quantity,
History.InvoiceAmountInFrgnCurrency AS InvoiceAmountInFrgnCurrency,
History.InvoiceAmtInCoCodeCrcy AS PurchaseOrderAmount,
History.Currency AS InvoiceCurrency,
History.PostingDate AS InvoiceDate,
OrderPriceUnit
FROM I_PurchaseOrderHistory AS History
LEFT OUTER JOIN I_PurchaseOrder AS _PurchaseOrder ON PurchaseOrder = _PurchaseOrder.PurchaseOrder -- association [1..1]
LEFT OUTER JOIN I_PurchaseOrderItem AS _PurchaseOrderItem ON PurchaseOrder = _PurchaseOrderItem.PurchaseOrder AND PurchaseOrderItem = _PurchaseOrderItem.PurchaseOrderItem -- association [1..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