I_PurchaseOrderStatus
Status of a purchase order
I_PurchaseOrderStatus is a Composite CDS View that provides data about "Status of a purchase order" in SAP S/4HANA. It reads from 1 data source (I_PurchaseOrder) and exposes 4 fields with key field PurchaseOrder. It is exposed through 1 OData service (UI_RFM_PO_MNG). It is used in 1 Fiori application: Manage Purchase Orders - Fashion.
Data Sources (1)
| Source | Alias | Join Type |
|---|---|---|
| I_PurchaseOrder | header | from |
Annotations (15)
| Name | Value | Level | Field |
|---|---|---|---|
| AbapCatalog.preserveKey | true | view | |
| AbapCatalog.compiler.compareFilter | true | view | |
| Metadata.ignorePropagatedAnnotations | true | view | |
| VDM.lifecycle.contract.type | #PUBLIC_LOCAL_API | view | |
| VDM.viewType | #COMPOSITE | view | |
| AccessControl.authorizationCheck | #CHECK | view | |
| AccessControl.personalData.blocking | #BLOCKED_DATA_EXCLUDED | view | |
| AbapCatalog.sqlViewName | IMMPOHDRSTATUS | view | |
| ClientHandling.algorithm | #SESSION_VARIABLE | view | |
| EndUserText.label | Status of a purchase order | view | |
| ObjectModel.usageType.serviceQuality | #C | view | |
| ObjectModel.usageType.sizeCategory | #L | view | |
| ObjectModel.usageType.dataClass | #TRANSACTIONAL | view | |
| ObjectModel.semanticKey | PurchaseOrder | view | |
| ObjectModel.representativeKey | PurchaseOrder | view |
OData Services (1)
| Service | Binding | Version | Contract | Release |
|---|---|---|---|---|
| UI_RFM_PO_MNG | UI_RFM_PO_MNG | V2 | C1 | NOT_RELEASED |
Fiori Apps (1)
| App ID | App Name | Type | Description |
|---|---|---|---|
| F5391 | Manage Purchase Orders - Fashion | Transactional |
Manage Purchase Orders - Fashion
Business Role: Purchaser (Retail)
With this app, you can now consolidate purchase order items into an existing purchase order based on the settings in the rule maintained using the Configure Purchase Order Consolidation Rule app.
Fields (4)
| Key | Field | Source Table | Source Field | Description |
|---|---|---|---|---|
| KEY | PurchaseOrder | I_PurchaseOrder | PurchaseOrder | |
| PurchaseOrderType | PurchaseOrderType | |||
| PurchasingOrganization | PurchasingOrganization | |||
| PurchasingGroup | PurchasingGroup |
@AbapCatalog.preserveKey: true
@AbapCatalog.compiler.compareFilter: true
// =========================================================================
// Status of Purchase Order Header
// =========================================================================
// The following status values are supported for PO Header:
// 01 Draft
// 02 In Approval
// 03 Not Sent Yet
// 04 Sent
// 05 Follow-On Documents
// 10 Deleted
// 37 Output Error
// 38 Rejected
// =========================================================================
@Metadata.ignorePropagatedAnnotations:true
@VDM.lifecycle.contract.type: #PUBLIC_LOCAL_API
@VDM.viewType: #COMPOSITE
@AccessControl.authorizationCheck: #CHECK
@AccessControl.personalData.blocking: #BLOCKED_DATA_EXCLUDED
@AbapCatalog.sqlViewName: 'IMMPOHDRSTATUS'
@ClientHandling.algorithm: #SESSION_VARIABLE
@EndUserText.label: 'Status of a purchase order'
@ObjectModel.supportedCapabilities:[#SQL_DATA_SOURCE, #CDS_MODELING_DATA_SOURCE]
@ObjectModel.usageType.serviceQuality: #C
@ObjectModel.usageType.sizeCategory: #L
@ObjectModel.usageType.dataClass: #TRANSACTIONAL
@ObjectModel.semanticKey: 'PurchaseOrder'
@ObjectModel.representativeKey: 'PurchaseOrder'
define view I_PurchaseOrderStatus
as select from I_PurchaseOrder as header
left outer to one join P_PurchaseOrderStatusHist as pos_ekbe on header.PurchaseOrder = pos_ekbe.PurchaseOrder
left outer to one join P_PurchaseOrderStatusOMApoc as om_new on header.PurchaseOrder = om_new.appl_object_id
left outer to one join P_PurchaseOrderStatusOMNast as om_old on header.PurchaseOrder = om_old.objky
left outer to one join P_PurchaseOrderStatusOMErr as om_error on header.PurchaseOrder = om_error.appl_object_id
{
key header.PurchaseOrder as PurchaseOrder,
case header.PurchasingDocumentDeletionCode
when 'X' then cast('10' as mmpur_doc_status)
when 'L' then cast('10' as mmpur_doc_status)
when 'C' then cast('10' as mmpur_doc_status) //3365420
else case header.PurchasingCompletenessStatus
when 'X' then cast('01' as mmpur_doc_status)
else case header.PurchasingProcessingStatus
when '08' then cast('38' as mmpur_doc_status)
else case header.ReleaseIsNotCompleted
when 'X' then cast('02' as mmpur_doc_status)
else case when (om_error.appl_object_id is null) then // ^2879307
case when (pos_ekbe.PurchaseOrder is null) then
case when (om_new.appl_object_id is null) then
case when (om_old.objky is null) then cast('03' as mmpur_doc_status)
else cast('04' as mmpur_doc_status)
end
else cast('04' as mmpur_doc_status)
end
else cast('05' as mmpur_doc_status) // v2879307
end
else cast('37' as mmpur_doc_status)
end
end
end
end
end as PurchasingDocumentStatus,
PurchaseOrderType,
PurchasingOrganization,
PurchasingGroup
}
Learn More
- What Is a CDS View in SAP S/4HANA?
- Types of CDS Views: Basic, Composite, Consumption, and Transactional
- SAP Tables vs CDS Views — Key Differences
- Understanding Data Lineage in SAP S/4HANA
- VDM (Virtual Data Model) in SAP S/4HANA Explained
- CDS View Annotations — A Complete Guide
- 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