I_PURCHASINGDOCUMENTHISTORYBSC
History per Purchasing Document Item
I_PURCHASINGDOCUMENTHISTORYBSC is a CDS View in S/4HANA. History per Purchasing Document Item. It contains 52 fields. 9 CDS views read from this table.
CDS Views using this table (9)
| View | Type | Join | VDM | Description |
|---|---|---|---|---|
| I_PurchasingDocumentHistory | view | from | COMPOSITE | Purchasing Document History |
| P_GoodsIssueDataSIT | view | from | COMPOSITE | |
| P_GoodsReceiptDataSIT | view | from | COMPOSITE | |
| P_GoodsReceiptDataSITLoc | view | from | COMPOSITE | |
| P_GRAmtPerPurgDocumentItem | view | from | CONSUMPTION | GR Amount per Purchasing Document Item |
| P_InvcAmtPerPurgDocItem | view | from | CONSUMPTION | Invoice Amount |
| P_PurchasingDocReceivedQty | view_entity | from | COMPOSITE | |
| P_PURORDITEMHIS | view | from | CONSUMPTION | Purchase Order Item History |
| P_RFM_SlsOrdPrgrsMntrPOHist | view | from | COMPOSITE |
Fields (52)
| Key | Field | CDS Fields | Used in Views |
|---|---|---|---|
| KEY | AccountAssignmentNumber | AccountAssignmentNumber | 1 |
| KEY | PurchasingDocument | PurchaseOrder,PurchasingDocument | 5 |
| KEY | PurchasingDocumentItem | PurchaseOrderItem,PurchasingDocumentItem | 5 |
| KEY | PurchasingHistoryDocument | MaterialDocument,PurchasingHistoryDocument | 4 |
| KEY | PurchasingHistoryDocumentItem | MaterialDocumentItem,PurchasingHistoryDocumentItem | 4 |
| KEY | PurchasingHistoryDocumentType | PurchasingHistoryDocumentType | 1 |
| KEY | PurchasingHistoryDocumentYear | MaterialDocumentYear,PurchasingHistoryDocumentYear | 4 |
| AccountingDocumentCreationDate | AccountingDocumentCreationDate | 1 | |
| Batch | Batch | 1 | |
| CreatedByUser | CreatedByUser | 1 | |
| Currency | Currency | 1 | |
| DebitCreditCode | DebitCreditCode | 1 | |
| DeliveryDocument | DeliveryDocument | 1 | |
| DeliveryDocumentItem | DeliveryDocumentItem | 1 | |
| DeliveryQuantityUnit | DeliveryQuantityUnit | 1 | |
| DocumentDate | DocumentDate | 1 | |
| DocumentReferenceID | DocumentReferenceID | 1 | |
| ExchangeRate | ExchangeRate | 1 | |
| ExchangeRateDifferenceAmount | ExchangeRateDifferenceAmount | 1 | |
| GdsRcptBlkdStkQtyInOrdPrcUnit | GdsRcptBlkdStkQtyInOrdPrcUnit | 1 | |
| GdsRcptBlkdStkQtyInOrdQtyUnit | GdsRcptBlkdStkQtyInOrdQtyUnit | 1 | |
| GoodsMovementType | GoodsMovementType | 1 | |
| GRIRAcctClrgAmtInCoCodeCrcy | GRIRAcctClrgAmtInCoCodeCrcy | 1 | |
| GRIRAcctClrgAmtInOrdTrnsacCrcy | GRIRAcctClrgAmtInOrdTrnsacCrcy | 1 | |
| GRIRAcctClrgAmtInTransacCrcy | GRIRAcctClrgAmtInTransacCrcy | 1 | |
| InventoryValuationType | InventoryValuationType | 1 | |
| InvoiceAmountInFrgnCurrency | InvoiceAmountInFrgnCurrency | 1 | |
| InvoiceAmtInCoCodeCrcy | InvoiceAmtInCoCodeCrcy | 1 | |
| InvoiceAmtInPurOrdTransacCrcy | InvoiceAmtInPurOrdTransacCrcy | 1 | |
| InvtryMgmtRefDocumentItem | ReferenceDocumentItem | 1 | |
| InvtryMgmtReferenceDocument | ReferenceDocument | 1 | |
| IsCompletelyDelivered | IsCompletelyDelivered | 1 | |
| IsToBeAcceptedAtOrigin | IsToBeAcceptedAtOrigin | 1 | |
| ManufacturerMaterial | ManufacturerMaterial | 1 | |
| Material | Material | 4 | |
| Plant | Plant | 1 | |
| PostingDate | PostingDate | 1 | |
| PricingDocument | PricingDocument | 1 | |
| PurchaseOrderAmount | PurchaseOrderAmount | 1 | |
| PurchasingHistoryCategory | PurchasingHistoryCategory | 1 | |
| PurgHistDocumentCreationTime | PurgHistDocumentCreationTime | 1 | |
| PurOrdAmountInCompanyCodeCrcy | PurOrdAmountInCompanyCodeCrcy | 1 | |
| QtyInPurchaseOrderPriceUnit | QtyInPurchaseOrderPriceUnit | 1 | |
| Quantity | Quantity,QuantityInPurchaseOrderUnit | 4 | |
| QuantityInBaseUnit | QuantityInBaseUnit | 1 | |
| QuantityInDeliveryQtyUnit | QuantityInDeliveryQtyUnit | 1 | |
| ReferenceDocumentFiscalYear | ReferenceDocumentFiscalYear | 1 | |
| RvslOfGoodsReceiptIsAllowed | RvslOfGoodsReceiptIsAllowed | 1 | |
| ShipgInstrnSupplierCompliance | ShipgInstrnSupplierCompliance | 1 | |
| TaxCode | TaxCode | 1 | |
| VltdGdsRcptBlkdQtyInOrdPrcUnit | VltdGdsRcptBlkdQtyInOrdPrcUnit | 1 | |
| VltdGdsRcptBlkdStkQtyInOrdUnit | VltdGdsRcptBlkdStkQtyInOrdUnit | 1 |
@AbapCatalog.preserveKey: true
@ClientHandling.algorithm: #SESSION_VARIABLE
@AbapCatalog.sqlViewName: 'IMMPURDOCHISB'
@AbapCatalog.compiler.compareFilter: true
@AccessControl.authorizationCheck: #PRIVILEGED_ONLY
@EndUserText.label: 'History per Purchasing Document Item'
@VDM.viewType : #BASIC
@Metadata.ignorePropagatedAnnotations: true
@ObjectModel.usageType.serviceQuality: #A
@ObjectModel.usageType.sizeCategory: #L
@ObjectModel.usageType.dataClass: #TRANSACTIONAL
@VDM.lifecycle.contract.type: #SAP_INTERNAL_API
define view I_PurchasingDocumentHistoryBsc
as select from ekbe
association [1..1] to I_PurchasingDocument as _PurchasingDocument on $projection.PurchasingDocument = _PurchasingDocument.PurchasingDocument
association [1..1] to I_PurchasingDocumentItem as _PurchasingDocumentItem on $projection.PurchasingDocument = _PurchasingDocumentItem.PurchasingDocument
and $projection.PurchasingDocumentItem = _PurchasingDocumentItem.PurchasingDocumentItem
association [1..1] to I_UnitOfMeasure as _OrderQuantityUnit on $projection.orderquantityunit = _OrderQuantityUnit.UnitOfMeasure
association [1..1] to I_UnitOfMeasure as _OrderPriceUnit on $projection.orderpriceunit = _OrderPriceUnit.UnitOfMeasure
association [1..1] to I_UnitOfMeasure as _DeliveryQuantityUnit on $projection.DeliveryQuantityUnit = _DeliveryQuantityUnit.UnitOfMeasure
association [1..1] to I_UnitOfMeasure as _BaseUnit on $projection.baseunit = _BaseUnit.UnitOfMeasure
association [1..1] to I_Currency as _Currency on $projection.Currency = _Currency.Currency
association [1..1] to I_Currency as _CompanyCodeCurrency on $projection.CompanyCodeCurrency = _CompanyCodeCurrency.Currency
association [1..1] to I_Currency as _PurchasingDocumentCurrency on $projection.PurchasingDocumentCurrency = _PurchasingDocumentCurrency.Currency
{
key ekbe.ebeln as PurchasingDocument,
key ekbe.ebelp as PurchasingDocumentItem,
key ekbe.zekkn as AccountAssignmentNumber,
key ekbe.vgabe as PurchasingHistoryDocumentType,
key ekbe.gjahr as PurchasingHistoryDocumentYear,
key ekbe.belnr as PurchasingHistoryDocument,
key ekbe.buzei as PurchasingHistoryDocumentItem,
ekbe.bewtp as PurchasingHistoryCategory,
ekbe.bwart as GoodsMovementType,
ekbe.budat as PostingDate,
@Semantics.currencyCode: true
@ObjectModel.foreignKey.association: '_Currency'
ekbe.waers as Currency,
ekbe.shkzg as DebitCreditCode,
ekbe.elikz as IsCompletelyDelivered,
ekbe.lfgja as ReferenceDocumentFiscalYear,
ekbe.lfbnr as InvtryMgmtReferenceDocument,
ekbe.lfpos as InvtryMgmtRefDocumentItem,
ekbe.matnr as Material,
ekbe.werks as Plant,
ekbe.xwsbr as RvslOfGoodsReceiptIsAllowed,
ekbe.knumv as PricingDocument,
ekbe.mwskz as TaxCode,
ekbe.bldat as DocumentDate,
ekbe.ernam as CreatedByUser,
ekbe.bwtar as InventoryValuationType,
ekbe.xblnr as DocumentReferenceID,
@Semantics.unitOfMeasure: true
@ObjectModel.foreignKey.association: '_DeliveryQuantityUnit'
ekbe.lsmeh as DeliveryQuantityUnit,
ekbe.ematn as ManufacturerMaterial,
ekbe.cpudt as AccountingDocumentCreationDate,
ekbe.cputm as PurgHistDocumentCreationTime,
@Semantics.quantity.unitOfMeasure:'OrderQuantityUnit'
ekbe.menge as Quantity,
@Semantics.amount.currencyCode: 'CompanyCodeCurrency'
ekbe.dmbtr as PurOrdAmountInCompanyCodeCrcy,
@Semantics.amount.currencyCode: 'Currency'
ekbe.wrbtr as PurchaseOrderAmount,
@Semantics.quantity.unitOfMeasure:'OrderPriceUnit'
ekbe.bpmng as QtyInPurchaseOrderPriceUnit,
@Semantics.amount.currencyCode: 'CompanyCodeCurrency'
ekbe.arewr as GRIRAcctClrgAmtInCoCodeCrcy,
@Semantics.quantity.unitOfMeasure:'OrderQuantityUnit'
ekbe.wesbs as GdsRcptBlkdStkQtyInOrdQtyUnit,
@Semantics.quantity.unitOfMeasure:'OrderPriceUnit'
ekbe.bpwes as GdsRcptBlkdStkQtyInOrdPrcUnit,
@Semantics.amount.currencyCode: 'CompanyCodeCurrency'
ekbe.reewr as InvoiceAmtInCoCodeCrcy,
ekbe.evere as ShipgInstrnSupplierCompliance,
@Semantics.amount.currencyCode: 'Currency'
ekbe.refwr as InvoiceAmountInFrgnCurrency,
@Semantics.quantity.unitOfMeasure:'DeliveryQuantityUnit'
ekbe.lsmng as QuantityInDeliveryQtyUnit,
@Semantics.amount.currencyCode: 'Currency'
ekbe.areww as GRIRAcctClrgAmtInTransacCrcy,
@Semantics.quantity.unitOfMeasure: 'BaseUnit'
ekbe.bamng as QuantityInBaseUnit,
ekbe.charg as Batch,
@Semantics.amount.currencyCode: 'PurchasingDocumentCurrency'
ekbe.arewb as GRIRAcctClrgAmtInOrdTrnsacCrcy,
@Semantics.amount.currencyCode: 'PurchasingDocumentCurrency'
ekbe.rewrb as InvoiceAmtInPurOrdTransacCrcy,
@Semantics.quantity.unitOfMeasure:'OrderQuantityUnit'
ekbe.wesbb as VltdGdsRcptBlkdStkQtyInOrdUnit,
@Semantics.quantity.unitOfMeasure:'OrderPriceUnit'
ekbe.bpweb as VltdGdsRcptBlkdQtyInOrdPrcUnit,
ekbe.weora as IsToBeAcceptedAtOrigin,
@Semantics.amount.currencyCode: 'Currency'
ekbe.kudif as ExchangeRateDifferenceAmount,
// ekbe.wkurs as ExchangeRate,
cast( ekbe.wkurs as fis_exchange_rate ) as ExchangeRate,
ekbe.vbeln_st as DeliveryDocument,
ekbe.vbelp_st as DeliveryDocumentItem,
@Semantics.unitOfMeasure: true
@ObjectModel.foreignKey.association: '_OrderPriceUnit'
_PurchasingDocumentItem.OrderPriceUnit,
@Semantics.unitOfMeasure: true
@ObjectModel.foreignKey.association: '_OrderQuantityUnit'
_PurchasingDocumentItem.OrderQuantityUnit,
@Semantics.unitOfMeasure: true
@ObjectModel.foreignKey.association: '_BaseUnit'
_PurchasingDocumentItem.BaseUnit,
@Semantics.currencyCode: true
@ObjectModel.foreignKey.association: '_PurchasingDocumentCurrency'
_PurchasingDocument.DocumentCurrency as PurchasingDocumentCurrency,
@Semantics.currencyCode: true
@ObjectModel.foreignKey.association: '_CompanyCodeCurrency'
_PurchasingDocument._CompanyCode.Currency as CompanyCodeCurrency,
_OrderQuantityUnit,
_OrderPriceUnit,
_DeliveryQuantityUnit,
_BaseUnit,
_Currency,
_CompanyCodeCurrency,
_PurchasingDocumentCurrency
}
/*+[internal] {
"BASEINFO":
{
"FROM":
[
"I_COMPANYCODE",
"I_PURCHASINGDOCUMENT",
"I_PURCHASINGDOCUMENTITEM",
"EKBE"
],
"ASSOCIATED":
[
"I_CURRENCY",
"I_PURCHASINGDOCUMENT",
"I_PURCHASINGDOCUMENTITEM",
"I_UNITOFMEASURE"
],
"BASE":
[],
"ANNO_REF":
[],
"SCALAR_FUNCTION":
[],
"VERSION":0,
"ANNOREF_EVALUATION_ERROR":""
}
}*/