P_PurOrdItmAcctAssgmt1
P_PurOrdItmAcctAssgmt1 is a Consumption CDS View in SAP S/4HANA. It reads from 3 data sources (I_PurgDocAccountAssignment, I_PurchaseOrder, I_PurchaseOrderItem) and exposes 34 fields with key fields PurchaseOrder, PurchaseOrderItem, AccountAssignmentNumber.
Data Sources (3)
| Source | Alias | Join Type |
|---|---|---|
| I_PurgDocAccountAssignment | AccountAssignment | left_outer |
| I_PurchaseOrder | PurchaseOrder | inner |
| I_PurchaseOrderItem | PurchaseOrderItem | from |
Parameters (2)
| Name | Type | Default |
|---|---|---|
| P_StartDate | bedat | |
| P_EndDate | bedat |
Annotations (6)
| Name | Value | Level | Field |
|---|---|---|---|
| AbapCatalog.sqlViewName | PMMPOIACCASGMT1 | view | |
| AbapCatalog.compiler.compareFilter | true | view | |
| AccessControl.authorizationCheck | #CHECK | view | |
| VDM.viewType | #CONSUMPTION | view | |
| VDM.private | true | view | |
| AccessControl.personalData.blocking | #NOT_REQUIRED | view |
Fields (34)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | PurchaseOrder | I_PurchaseOrderItem | PurchaseOrder | Purchasing Document |
| KEY | PurchaseOrderItem | I_PurchaseOrderItem | PurchaseOrderItem | Purchasing Document Item |
| KEY | AccountAssignmentNumber | I_PurgDocAccountAssignment | AccountAssignmentNumber | Account Assgmt No. |
| Supplier | I_PurchaseOrder | Supplier | Supplier | |
| PurchasingOrganization | I_PurchaseOrder | PurchasingOrganization | Purchasing Organization | |
| PurchasingGroup | I_PurchaseOrder | PurchasingGroup | Purchasing Group | |
| CompanyCode | I_PurchaseOrder | CompanyCode | Receiver Company Code | |
| ReceivingCompanyCode | I_PurchaseOrderItem | CompanyCode | Receiver Company Code | |
| PurchaseOrderType | I_PurchaseOrder | PurchaseOrderType | PO Type | |
| PurchaseOrderDate | I_PurchaseOrder | PurchaseOrderDate | PO Date | |
| CreatedByUser | I_PurchaseOrder | CreatedByUser | User Name | |
| Currency | I_PurchaseOrder | DocumentCurrency | Document Currency | |
| MaterialGroup | I_PurchaseOrderItem | MaterialGroup | Product Group | |
| Material | I_PurchaseOrderItem | Material | Vehicle Model | |
| Plant | I_PurchaseOrderItem | Plant | Valuation Area | |
| ProductType | I_PurchaseOrderItem | ProductType | Product Type Group | |
| ServicePerformer | I_PurchaseOrderItem | ServicePerformer | Service Performer | |
| MultipleAcctAssgmtDistribution | I_PurchaseOrderItem | MultipleAcctAssgmtDistribution | Distribution | |
| AccountAssignmentCategory | I_PurchaseOrderItem | AccountAssignmentCategory | Acct Assgmt Cat | |
| MultipleAcctAssgmtDistrPercent | I_PurgDocAccountAssignment | MultipleAcctAssgmtDistrPercent | Distribution | |
| CostCenter | I_PurgDocAccountAssignment | CostCenter | Cost Center | |
| WBSElementInternalID | I_PurgDocAccountAssignment | WBSElementInternalID | WBS Internal ID | |
| ControllingArea | I_PurgDocAccountAssignment | ControllingArea | Controlling Area | |
| GLAccount | I_PurgDocAccountAssignment | GLAccount | General Ledger | |
| ProfitCenter | I_PurgDocAccountAssignment | ProfitCenter | Profit Center | |
| Quantity | I_PurgDocAccountAssignment | Quantity | Value | |
| OrderQuantity | I_PurchaseOrderItem | OrderQuantity | Quantity | |
| PurchaseOrderQuantityUnit | I_PurchaseOrderItem | PurchaseOrderQuantityUnit | Order Unit | |
| IsCompletelyDelivered | IsCompletelyDelivered | Is completely delivered | ||
| InvoiceIsGoodsReceiptBased | InvoiceIsGoodsReceiptBased | GR-Based IV | ||
| OverdelivTolrtdLmtRatioInPct | OverdelivTolrtdLmtRatioInPct | Overdeliv. Tol. | ||
| UnderdelivTolrtdLmtRatioInPct | UnderdelivTolrtdLmtRatioInPct | Underdel. Tol. | ||
| ReturnsItem | ||||
| QuantityendasPurchaseOrderQty |
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_PurOrdItmAcctAssgmt1.
-- 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: PMMPOIACCASGMT1
-- Parameters: P_StartDate : bedat, P_EndDate : bedat
CREATE VIEW P_PurOrdItmAcctAssgmt1 AS
SELECT
PurchaseOrderItem.PurchaseOrder AS PurchaseOrder,
PurchaseOrderItem.PurchaseOrderItem AS PurchaseOrderItem,
AccountAssignment.AccountAssignmentNumber AS AccountAssignmentNumber,
PurchaseOrder.Supplier AS Supplier,
PurchaseOrder.PurchasingOrganization AS PurchasingOrganization,
PurchaseOrder.PurchasingGroup AS PurchasingGroup,
PurchaseOrder.CompanyCode AS CompanyCode,
PurchaseOrderItem.CompanyCode AS ReceivingCompanyCode,
PurchaseOrder.PurchaseOrderType AS PurchaseOrderType,
PurchaseOrder.PurchaseOrderDate AS PurchaseOrderDate,
PurchaseOrder.CreatedByUser AS CreatedByUser,
PurchaseOrder.DocumentCurrency AS Currency,
PurchaseOrderItem.MaterialGroup AS MaterialGroup,
PurchaseOrderItem.Material AS Material,
PurchaseOrderItem.Plant AS Plant,
PurchaseOrderItem.ProductType AS ProductType,
PurchaseOrderItem.ServicePerformer AS ServicePerformer,
PurchaseOrderItem.MultipleAcctAssgmtDistribution AS MultipleAcctAssgmtDistribution,
PurchaseOrderItem.AccountAssignmentCategory AS AccountAssignmentCategory,
AccountAssignment.MultipleAcctAssgmtDistrPercent AS MultipleAcctAssgmtDistrPercent,
AccountAssignment.CostCenter AS CostCenter,
AccountAssignment.WBSElementInternalID AS WBSElementInternalID,
AccountAssignment.ControllingArea AS ControllingArea,
AccountAssignment.GLAccount AS GLAccount,
AccountAssignment.ProfitCenter AS ProfitCenter,
AccountAssignment.Quantity AS Quantity,
PurchaseOrderItem.OrderQuantity AS OrderQuantity,
PurchaseOrderItem.PurchaseOrderQuantityUnit AS PurchaseOrderQuantityUnit,
IsCompletelyDelivered,
InvoiceIsGoodsReceiptBased,
OverdelivTolrtdLmtRatioInPct,
UnderdelivTolrtdLmtRatioInPct,
cast( case when PurchaseOrderItem.IsReturnsItem = 'X' then -1 else 1 end as int2 ) AS ReturnsItem,
case when PurchaseOrderItem.MultipleAcctAssgmtDistribution = '' then PurchaseOrderItem.OrderQuantity else AccountAssignment.Quantity end as PurchaseOrderQty AS QuantityendasPurchaseOrderQty
FROM I_PurchaseOrderItem AS PurchaseOrderItem
INNER JOIN I_PurchaseOrder AS PurchaseOrder ON /* join condition not captured in parsed metadata */
LEFT OUTER JOIN I_PurgDocAccountAssignment AS AccountAssignment ON /* join condition not captured in parsed metadata */
;
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