P_EnhPhysInvtryActvStkSepVSitn

DDL: P_ENHPHYSINVTRYACTVSTKSEPVSITN Type: view_entity COMPOSITE Package: ODATA_MM_IM_PI_OBJECT_PAGE

Value of additional fields for P_EnhPhysInvtryActvStkSepSitn

P_EnhPhysInvtryActvStkSepVSitn is a Composite CDS View that provides data about "Value of additional fields for P_EnhPhysInvtryActvStkSepSitn" in SAP S/4HANA. It reads from 1 data source (P_EnhPhysInvtryActvStkSepSitn) and exposes 29 fields with key fields Material, Plant, StorageLocation, Batch, Supplier. Part of development package ODATA_MM_IM_PI_OBJECT_PAGE.

Data Sources (1)

SourceAliasJoin Type
P_EnhPhysInvtryActvStkSepSitn sep from

Annotations (3)

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

Fields (29)

KeyFieldSource TableSource FieldDescription
KEY Material
KEY Plant P_EnhPhysInvtryActvStkSepSitn Plant Valuation Area
KEY StorageLocation
KEY Batch P_EnhPhysInvtryActvStkSepSitn Batch Lot No.
KEY Supplier P_EnhPhysInvtryActvStkSepSitn Supplier Supplier
KEY SalesOrder P_EnhPhysInvtryActvStkSepSitn SalesOrder SD Document
KEY SalesOrderItem P_EnhPhysInvtryActvStkSepSitn SalesOrderItem Sales Order Item
KEY WBSElement P_EnhPhysInvtryActvStkSepSitn WBSElement WBS Internal ID
KEY Customer P_EnhPhysInvtryActvStkSepSitn Customer Sold-to Party
KEY StockOwner P_EnhPhysInvtryActvStkSepSitn StockOwner Owner of stock
KEY InventoryStockType P_EnhPhysInvtryActvStkSepSitn InventoryStockType Stock Type
KEY InventorySpecialStockType P_EnhPhysInvtryActvStkSepSitn InventorySpecialStockType Special Stock Type
KEY MaterialBaseUnit P_EnhPhysInvtryActvStkSepSitn MaterialBaseUnit Valuation Unit
WBSElementInternalID P_EnhPhysInvtryActvStkSepSitn WBSElementInternalID WBS Internal ID
ProductType P_EnhPhysInvtryActvStkSepSitn ProductType Product Type Group
ProductGroup P_EnhPhysInvtryActvStkSepSitn ProductGroup Product Sold Group
MatlWrhsStkQtyInMatlBaseUnit P_EnhPhysInvtryActvStkSepSitn MatlWrhsStkQtyInMatlBaseUnit Quantity
PhysicalInventoryLastCountDate P_EnhPhysInvtryActvStkSepSitn PhysicalInventoryLastCountDate Count Date
NumberOfPhysInventoryCounts P_EnhPhysInvtryActvStkSepSitn NumberOfPhysInventoryCounts
NmbrOfDaysSinceLastPInvCount P_EnhPhysInvtryActvStkSepSitn NmbrOfDaysSinceLastPInvCount
PhysicalInventoryItemIsCounted P_EnhPhysInvtryActvStkSepSitn PhysicalInventoryItemIsCounted Is Counted
GdsIssQtySinceLastCountInBsUnt
AvgStkQtySinceLastCountCorrect
NumberOfPInvAdjustmentsPerYear
PInvDiffQtyPerYearInBaseUnit
NrOfGdsRcptSinceLastPInvCount
GdsRcptQtySinceLastCtInBsUnt
NrOfGoodsIssSinceLastPInvCount
CurrentDate P_EnhPhysInvtryActvStkSepSitn CurrentDate

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_EnhPhysInvtryActvStkSepVSitn.
-- 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.

CREATE VIEW P_EnhPhysInvtryActvStkSepVSitn AS
SELECT
  cast(sep.Material as matnr preserving type) AS Material,
  sep.Plant AS Plant,
  cast(sep.StorageLocation as pi_storage_location preserving type) AS StorageLocation,
  sep.Batch AS Batch,
  sep.Supplier AS Supplier,
  sep.SalesOrder AS SalesOrder,
  sep.SalesOrderItem AS SalesOrderItem,
  sep.WBSElement AS WBSElement,
  sep.Customer AS Customer,
  sep.StockOwner AS StockOwner,
  sep.InventoryStockType AS InventoryStockType,
  sep.InventorySpecialStockType AS InventorySpecialStockType,
  sep.MaterialBaseUnit AS MaterialBaseUnit,
  sep.WBSElementInternalID AS WBSElementInternalID,
  sep.ProductType AS ProductType,
  sep.ProductGroup AS ProductGroup,
  sep.MatlWrhsStkQtyInMatlBaseUnit AS MatlWrhsStkQtyInMatlBaseUnit,
  sep.PhysicalInventoryLastCountDate AS PhysicalInventoryLastCountDate,
  sep.NumberOfPhysInventoryCounts AS NumberOfPhysInventoryCounts,
  sep.NmbrOfDaysSinceLastPInvCount AS NmbrOfDaysSinceLastPInvCount,
  sep.PhysicalInventoryItemIsCounted AS PhysicalInventoryItemIsCounted,
  cast(sep.GdsIssQtySinceLastCountInBsUnt as pi_gi_qty_since_last_cnt) AS GdsIssQtySinceLastCountInBsUnt,
  FLTP_TO_DEC( sep.AvgStkQtySinceLastCountCorrect as abap.dec(31,14) ) AS AvgStkQtySinceLastCountCorrect,
  cast(_PIPerYear.NumberOfPInvAdjustmentsPerYear as pi_nr_of_adjstmnt_per_year) AS NumberOfPInvAdjustmentsPerYear,
  cast(_PIPerYear.PInvDiffQtyPerYearInBaseUnit as pi_difference_qty_per_year) AS PInvDiffQtyPerYearInBaseUnit,
  cast(sep.NrOfGdsRcptSinceLastPInvCount as pi_nr_of_gr_since_last_cnt) AS NrOfGdsRcptSinceLastPInvCount,
  cast(sep.GdsRcptQtySinceLastCtInBsUnt as pi_gr_qty_since_last_cnt) AS GdsRcptQtySinceLastCtInBsUnt,
  cast(sep.NrOfGoodsIssSinceLastPInvCount as pi_nr_of_gi_since_last_cnt) AS NrOfGoodsIssSinceLastPInvCount,
  sep.CurrentDate AS CurrentDate
FROM P_EnhPhysInvtryActvStkSepSitn AS sep
;