P_PurchasingDocReceivedQty

DDL: P_PURCHASINGDOCRECEIVEDQTY Type: view_entity COMPOSITE

P_PurchasingDocReceivedQty is a Composite CDS View in SAP S/4HANA. It reads from 1 data source (I_PurchasingDocumentHistoryBsc) and exposes 4 fields with key fields PurchasingDocument, PurchasingDocumentItem.

Data Sources (1)

SourceAliasJoin Type
I_PurchasingDocumentHistoryBsc _PurchDocHist from

Annotations (3)

NameValueLevelField
VDM.private true view
VDM.viewType #COMPOSITE view
AccessControl.authorizationCheck #NOT_REQUIRED view

Fields (4)

KeyFieldSource TableSource FieldDescription
KEY PurchasingDocument PurchasingDocument
KEY PurchasingDocumentItem PurchasingDocumentItem
ReceivedQuantity
OrderQuantityUnit OrderQuantityUnit
@VDM.private: true
@VDM.viewType: #COMPOSITE
@AccessControl.authorizationCheck: #NOT_REQUIRED
//@EndUserText.label: 'Calc sum of rcvd qty per pur doc item'


define view entity P_PurchasingDocReceivedQty
  as select from I_PurchasingDocumentHistoryBsc as _PurchDocHist
{
  key PurchasingDocument,
  key PurchasingDocumentItem,
      @Semantics.quantity.unitOfMeasure:'OrderQuantityUnit'
      sum(Quantity) as ReceivedQuantity,
      OrderQuantityUnit
}
where PurchasingHistoryDocumentType = '1' // Select Goods Receipt as Document Type

group by
  PurchasingDocument,
  PurchasingDocumentItem,
  OrderQuantityUnit