P_ITEM_BATCH

DDL: P_ITEM_BATCH SQL: PITEMBATCH Type: view BASIC

P_ITEM_BATCH is a Basic CDS View in SAP S/4HANA. It reads from 1 data source (rbdrseg) and exposes 53 fields with key fields SupplierInvoice, FiscalYear, SupplierInvoiceItem.

Data Sources (1)

SourceAliasJoin Type
rbdrseg rbdrseg from

Annotations (9)

NameValueLevelField
AbapCatalog.sqlViewName PITEMBATCH view
AbapCatalog.compiler.compareFilter true view
AccessControl.authorizationCheck #PRIVILEGED_ONLY view
AccessControl.personalData.blocking #REQUIRED view
ClientHandling.algorithm #SESSION_VARIABLE view
VDM.viewType #BASIC view
VDM.private true view
VDM.lifecycle.contract.type #NONE view
AbapCatalog.preserveKey true view

Fields (53)

KeyFieldSource TableSource FieldDescription
KEY SupplierInvoice rbdrseg rblnr Inv. Doc. No.
KEY FiscalYear rbdrseg rjahr Fiscal Year
KEY SupplierInvoiceItem rbdrseg rblgp Item
PurchaseOrder rbdrseg ebeln Source PurchDoc
PurchaseOrderItem rbdrseg ebelp Item pur. doc.
Plant rbdrseg werks Receiving Plant
SupplierInvoiceItemText rbdrseg sgtxt Text
PurchaseOrderItemMaterial rbdrseg matnr Vehicle Model
PurchaseOrderQuantityUnit rbdrseg meins Valuation Unit
QuantityInPurchaseOrderUnit rbdrseg menge WarrCountValue
PurchaseOrderPriceUnit rbdrseg bprme PO Price Unit
QtyInPurchaseOrderPriceUnit rbdrseg bpmng Qty. in OPUn
StockUnit rbdrseg basme Unit of measure
SuplrInvcDeliveryCostCndnType rbdrseg kschl Tax Item Type
SuplrInvcDeliveryCostCndnStep rbdrseg stunr Step Number
SuplrInvcDeliveryCostCndnCount rbdrseg zaehk Counter
SupplierInvoiceItemAmount rbdrseg wrbtr Gross Amount
IsSubsequentDebitCredit rbdrseg tbtkz Subseq. Dr/Cr
TaxCode rbdrseg mwskz Tax Code
TaxJurisdiction rbdrseg txjcd Tax Jurisdict.
ReferenceDocument rbdrseg lfbnr Reference Doc.
ReferenceDocumentFiscalYear rbdrseg lfgja Year Cur.Period
ReferenceDocumentItem rbdrseg lfpos Ref. Doc. Item
PurchaseContract
PurchaseContractItem
DebitCreditCode rbdrseg shkzg Returns
FreightSupplier
IsNotCashDiscountLiable rbdrseg xskrl W/o CashDsc.
SuplrInvcItemHasPriceVariance rbdrseg spgrp Block.Reas.:Prc
SuplrInvcItemHasQtyVariance rbdrseg spgrm Block.Reas.:Qty
SuplrInvcItemHasDateVariance rbdrseg spgrt Bl. Reason Date
SuplrInvcItemHasOrdPrcQtyVarc rbdrseg spgrg Block.Reas: OPQ
SuplrInvcItemHasOtherVariance rbdrseg spgrq Man.Block.Reasn
SuplrInvcItemHasAmountOutsdTol rbdrseg spgrs Blkg Reas. Amount
SuplrInvcItmHasQualityVariance rbdrseg spgrc Block: Quality
PurchasingDocumentItemCategory rbdrseg pstyp Item Category
ProductType rbdrseg producttype Product Type Group
TaxCountry rbdrseg tax_country Tax Ctry/Rgn
InventoryValuationType rbdrseg bwtar Valuation Type
SuplrInvcPurgDocItmCompanyCode rbdrseg bukrs Value
IsFinallyInvoiced rbdrseg erekz Final Invoice Ind.
RetentionAmountInDocCurrency rbdrseg retamt_fc Retent. in Doc. Crcy
RetentionPercentage rbdrseg retpc Retention %
RetentionDueDate rbdrseg retduedt Due Date
IN_HSNOrSACCode rbdrseg hsn_sac HSN/SAC Code
IN_CustomDutyAssessableValue rbdrseg customs_val Assessable Val.
TaxDeterminationDate rbdrseg txdat Tax Date
NL_ChainLiabilityStartDate
NL_ChainLiabilityEndDate
NL_ChainLiabilityDescription
NL_ChainLbltyCnstrctnSiteDesc
NL_ChainLiabilityPercent
NL_ChainLiabilityDuration

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_ITEM_BATCH.
-- 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: PITEMBATCH

CREATE VIEW P_ITEM_BATCH AS
SELECT
  rbdrseg.rblnr AS SupplierInvoice,
  rbdrseg.rjahr AS FiscalYear,
  rbdrseg.rblgp AS SupplierInvoiceItem,
  rbdrseg.ebeln AS PurchaseOrder,
  rbdrseg.ebelp AS PurchaseOrderItem,
  rbdrseg.werks AS Plant,
  rbdrseg.sgtxt AS SupplierInvoiceItemText,
  rbdrseg.matnr AS PurchaseOrderItemMaterial,
  rbdrseg.meins AS PurchaseOrderQuantityUnit,
  rbdrseg.menge AS QuantityInPurchaseOrderUnit,
  rbdrseg.bprme AS PurchaseOrderPriceUnit,
  rbdrseg.bpmng AS QtyInPurchaseOrderPriceUnit,
  rbdrseg.basme AS StockUnit,
  rbdrseg.kschl AS SuplrInvcDeliveryCostCndnType,
  rbdrseg.stunr AS SuplrInvcDeliveryCostCndnStep,
  rbdrseg.zaehk AS SuplrInvcDeliveryCostCndnCount,
  rbdrseg.wrbtr AS SupplierInvoiceItemAmount,
  rbdrseg.tbtkz AS IsSubsequentDebitCredit,
  rbdrseg.mwskz AS TaxCode,
  rbdrseg.txjcd AS TaxJurisdiction,
  rbdrseg.lfbnr AS ReferenceDocument,
  rbdrseg.lfgja AS ReferenceDocumentFiscalYear,
  rbdrseg.lfpos AS ReferenceDocumentItem,
  cast ( ' ' as konnr preserving type) AS PurchaseContract,
  cast ( '00000' as ktpnr preserving type) AS PurchaseContractItem,
  rbdrseg.shkzg AS DebitCreditCode,
  cast ( ' ' as lifnr preserving type) AS FreightSupplier,
  rbdrseg.xskrl AS IsNotCashDiscountLiable,
  rbdrseg.spgrp AS SuplrInvcItemHasPriceVariance,
  rbdrseg.spgrm AS SuplrInvcItemHasQtyVariance,
  rbdrseg.spgrt AS SuplrInvcItemHasDateVariance,
  rbdrseg.spgrg AS SuplrInvcItemHasOrdPrcQtyVarc,
  rbdrseg.spgrq AS SuplrInvcItemHasOtherVariance,
  rbdrseg.spgrs AS SuplrInvcItemHasAmountOutsdTol,
  rbdrseg.spgrc AS SuplrInvcItmHasQualityVariance,
  rbdrseg.pstyp AS PurchasingDocumentItemCategory,
  rbdrseg.producttype AS ProductType,
  rbdrseg.tax_country AS TaxCountry,
  rbdrseg.bwtar AS InventoryValuationType,
  rbdrseg.bukrs AS SuplrInvcPurgDocItmCompanyCode,
  rbdrseg.erekz AS IsFinallyInvoiced,
  rbdrseg.retamt_fc AS RetentionAmountInDocCurrency,
  rbdrseg.retpc AS RetentionPercentage,
  rbdrseg.retduedt AS RetentionDueDate,
  rbdrseg.hsn_sac AS IN_HSNOrSACCode,
  rbdrseg.customs_val AS IN_CustomDutyAssessableValue,
  rbdrseg.txdat AS TaxDeterminationDate,
  cast ( '00000000' as abap.numc(8) ) AS NL_ChainLiabilityStartDate,
  cast ( '00000000' as abap.numc(8) ) AS NL_ChainLiabilityEndDate,
  cast ( ' ' as wka_descr preserving type ) AS NL_ChainLiabilityDescription,
  cast ( ' ' as wka_despl preserving type ) AS NL_ChainLbltyCnstrctnSiteDesc,
  cast ( 0 as abap.dec(5,2) ) AS NL_ChainLiabilityPercent,
  cast ( '0000000000' as wka_hours preserving type ) AS NL_ChainLiabilityDuration
FROM rbdrseg
;