I_PhysInvtryBatchVH

DDL: I_PHYSINVTRYBATCHVH Type: view_entity COMPOSITE Package: ODATA_MM_IM_PI_MANAGE_COUNT

Batches in Physical Inventory

I_PhysInvtryBatchVH is a Composite CDS View that provides data about "Batches in Physical Inventory" in SAP S/4HANA. It reads from 1 data source (I_Batch) and exposes 32 fields with key fields Batch, Plant, StorageLocation, Material, InventorySpecialStockType. It has 3 associations to related views. It is exposed through 2 OData services (ASQL_F5430, ASQL_F8634). Part of development package ODATA_MM_IM_PI_MANAGE_COUNT.

Data Sources (1)

SourceAliasJoin Type
I_Batch _batch inner

Associations (3)

CardinalityTargetAliasCondition
[1..1] I_Plant _Plant $projection.Plant = _Plant.Plant
[1..1] I_StorageLocation _StorageLocation $projection.Plant = _StorageLocation.Plant and $projection.StorageLocation = _StorageLocation.StorageLocation
[1..1] I_Product _Product $projection.Material = _Product.Product

Annotations (16)

NameValueLevelField
EndUserText.label Batches in Physical Inventory view
AbapCatalog.dataMaintenance #RESTRICTED view
ObjectModel.usageType.sizeCategory #M view
ObjectModel.usageType.serviceQuality #C view
ObjectModel.usageType.dataClass #MASTER view
ObjectModel.dataCategory #VALUE_HELP view
ObjectModel.modelingPattern #ANALYTICAL_DIMENSION view
ObjectModel.representativeKey Batch view
VDM.viewType #COMPOSITE view
VDM.lifecycle.contract.type #NONE view
Search.searchable true view
Metadata.allowExtensions true view
Metadata.ignorePropagatedAnnotations true view
AccessControl.authorizationCheck #CHECK view
AccessControl.personalData.blocking #NOT_REQUIRED view
Consumption.ranked true view

OData Services (2)

ServiceBindingVersionContractRelease
ASQL_F5430 ASQL_F5430 C2 NOT_RELEASED
ASQL_F8634 ASQL_F8634 C2 NOT_RELEASED

Fields (32)

KeyFieldSource TableSource FieldDescription
KEY Batch I_Batch Batch Lot No.
KEY Plant _matdoc Plant Valuation Area
KEY StorageLocation _matdoc StockIdfgStorageLocation
KEY Material _matdoc StockIdentifyingMaterial
KEY InventorySpecialStockType _matdoc InventorySpecialStockType Special Stock Type
InventoryValuationType I_Batch InventoryValuationType Valuation Type
BatchIsMarkedForDeletion I_Batch BatchIsMarkedForDeletion
MatlBatchIsInRstrcdUseStock I_Batch MatlBatchIsInRstrcdUseStock Batch restr.
Supplier I_Batch Supplier Supplier
BatchBySupplier I_Batch BatchBySupplier Supplier Batch
CountryOfOrigin I_Batch CountryOfOrigin Country/Region of Origin
RegionOfOrigin I_Batch RegionOfOrigin Reg. of Origin
MatlBatchAvailabilityDate I_Batch MatlBatchAvailabilityDate
ShelfLifeExpirationDate I_Batch ShelfLifeExpirationDate SLED/BBD
ManufactureDate I_Batch ManufactureDate Date of Manuf.
FreeDefinedDate1 I_Batch FreeDefinedDate1
FreeDefinedDate2 I_Batch FreeDefinedDate2
FreeDefinedDate3 I_Batch FreeDefinedDate3
FreeDefinedDate4 I_Batch FreeDefinedDate4
FreeDefinedDate5 I_Batch FreeDefinedDate5
FreeDefinedDate6 I_Batch FreeDefinedDate6
DefinitionOfBatchLevel I_Batch DefinitionOfBatchLevel
CreationDateTime I_Batch CreationDateTime Timestamp
LastChangeDateTime I_Batch LastChangeDateTime Timestamp
ClfnObjectInternalID I_Batch ClfnObjectInternalID
BatchExtWhseMgmtInternalId I_Batch BatchExtWhseMgmtInternalId
_Supplier I_Batch _Supplier
_CountryOfOrigin I_Batch _CountryOfOrigin
_RegionOfOrigin I_Batch _RegionOfOrigin
_Plant _Plant
_StorageLocation _StorageLocation
_Product _Product

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 I_PhysInvtryBatchVH.
-- 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 I_PhysInvtryBatchVH AS
SELECT
  _batch.Batch AS Batch,
  _matdoc.Plant AS Plant,
  _matdoc.StockIdfgStorageLocation AS StorageLocation,
  _matdoc.StockIdentifyingMaterial AS Material,
  _matdoc.InventorySpecialStockType AS InventorySpecialStockType,
  _batch.InventoryValuationType AS InventoryValuationType,
  _batch.BatchIsMarkedForDeletion AS BatchIsMarkedForDeletion,
  _batch.MatlBatchIsInRstrcdUseStock AS MatlBatchIsInRstrcdUseStock,
  _batch.Supplier AS Supplier,
  _batch.BatchBySupplier AS BatchBySupplier,
  _batch.CountryOfOrigin AS CountryOfOrigin,
  _batch.RegionOfOrigin AS RegionOfOrigin,
  _batch.MatlBatchAvailabilityDate AS MatlBatchAvailabilityDate,
  _batch.ShelfLifeExpirationDate AS ShelfLifeExpirationDate,
  _batch.ManufactureDate AS ManufactureDate,
  _batch.FreeDefinedDate1 AS FreeDefinedDate1,
  _batch.FreeDefinedDate2 AS FreeDefinedDate2,
  _batch.FreeDefinedDate3 AS FreeDefinedDate3,
  _batch.FreeDefinedDate4 AS FreeDefinedDate4,
  _batch.FreeDefinedDate5 AS FreeDefinedDate5,
  _batch.FreeDefinedDate6 AS FreeDefinedDate6,
  _batch.DefinitionOfBatchLevel AS DefinitionOfBatchLevel,
  _batch.CreationDateTime AS CreationDateTime,
  _batch.LastChangeDateTime AS LastChangeDateTime,
  _batch.ClfnObjectInternalID AS ClfnObjectInternalID,
  _batch.BatchExtWhseMgmtInternalId AS BatchExtWhseMgmtInternalId,
  _batch._Supplier AS _Supplier,
  _batch._CountryOfOrigin AS _CountryOfOrigin,
  _batch._RegionOfOrigin AS _RegionOfOrigin
INNER JOIN I_Batch AS _batch ON /* join condition not captured in parsed metadata */
LEFT OUTER JOIN I_Plant AS _Plant ON Plant = _Plant.Plant  -- association [1..1]
LEFT OUTER JOIN I_StorageLocation AS _StorageLocation ON Plant = _StorageLocation.Plant AND StorageLocation = _StorageLocation.StorageLocation  -- association [1..1]
LEFT OUTER JOIN I_Product AS _Product ON Material = _Product.Product  -- association [1..1]
;