P_EWM_InboundDeliveryItem

DDL: P_EWM_INBOUNDDELIVERYITEM SQL: PEWMINBDELIVITEM Type: view COMPOSITE

P_EWM_InboundDeliveryItem is a Composite CDS View in SAP S/4HANA. It reads from 1 data source (I_EWM_InbDeliveryItemBasic) and exposes 147 fields with key fields InboundDeliveryUUID, InboundDeliveryItemUUID. It has 7 associations to related views.

Data Sources (1)

SourceAliasJoin Type
I_EWM_InbDeliveryItemBasic I_EWM_InbDeliveryItemBasic from

Associations (7)

CardinalityTargetAliasCondition
[0..1] P_EWM_ProcessCodeDelivQtyChg _QuantityAdjustment $projection.InboundDeliveryUUID = _QuantityAdjustment.DeliveryUUID and $projection.InboundDeliveryItemUUID = _QuantityAdjustment.DeliveryItemUUID and _QuantityAdjustment.DeliveryDocumentCategory = 'PDI'
[0..1] P_EWM_InboundDeliveryHeader _InboundDeliveyHeader $projection.InboundDeliveryUUID = _InboundDeliveyHeader.InboundDeliveryUUID
[0..1] I_EWM_WhseReqTransportation _Transportation $projection.InboundDeliveryUUID = _Transportation.EWMWarehouseRequestUUID and _Transportation.EWMWhseRequestDocumentCategory = 'PDI'
[0..1] I_EWM_DeliveryBPLocation _ReceivingOffice $projection.InboundDeliveryUUID = _ReceivingOffice.OutboundDeliveryOrderUUID and _ReceivingOffice.BusinessPartnerRole = 'SO' and _ReceivingOffice.EWMDeliveryDocumentCategory = 'PDI'
[0..1] I_EWM_WarehouseControl_2 _whseControl $projection.EWMWarehouse = _whseControl.EWMWarehouse
[0..1] I_BusinessPartner _Owner $projection.StockOwner = _Owner.BusinessPartner
[0..1] I_BusinessPartner _DisposalParty $projection.EntitledToDisposeParty = _DisposalParty.BusinessPartner

Annotations (11)

NameValueLevelField
AbapCatalog.sqlViewName PEWMINBDELIVITEM view
AbapCatalog.compiler.compareFilter true view
AbapCatalog.preserveKey true view
AccessControl.authorizationCheck #CHECK view
VDM.private true view
VDM.viewType #COMPOSITE view
ClientHandling.type #INHERITED view
ClientHandling.algorithm #SESSION_VARIABLE view
ObjectModel.usageType.dataClass #MIXED view
ObjectModel.usageType.serviceQuality #C view
ObjectModel.usageType.sizeCategory #M view

Fields (147)

KeyFieldSource TableSource FieldDescription
KEY InboundDeliveryUUID InboundDeliveryUUID Document ID
KEY InboundDeliveryItemUUID InboundDeliveryItemUUID Item ID
Warehouse Warehouse Warehouse No.
EWMWarehouse EWMWarehouse Warehouse No.
InboundDelivery InboundDelivery LE Delivery
EWMInboundDelivery EWMInboundDelivery Document Number
InboundDeliveryItem InboundDeliveryItem Item
EWMInboundDeliveryItem EWMInboundDeliveryItem Item Number
InboundDeliveryDocumentType _InboundDeliveyHeader InboundDeliveryDocumentType
DeliveryDocumentCategory DeliveryDocumentCategory
DeliveryItemCategory DeliveryItemCategory
EWMInboundDeliveryItemCategory EWMInboundDeliveryItemCategory Item Category
InboundDeliveryItemType InboundDeliveryItemType
EWMInboundDeliveryItemType EWMInboundDeliveryItemType Item Type
WarehouseProcessType WarehouseProcessType Whse Proc. Type
WarehouseDoor WarehouseDoor Warehouse Door
StagingAreaGroup StagingAreaGroup Stg. Area Group
StagingArea StagingArea Stag. Area
StagingBay StagingBay Staging Bay
GoodsMovementBin GoodsMovementBin Goods Mvt Bin
Product Product Product Sold
Batch Batch Lot No.
RequirementSegment RequirementSegment Req. Segment
StockSegment StockSegment Stock Segment
EntitledToDisposeParty EntitledToDisposeParty Disposal Party
StockOwner StockOwner Owner of stock
EWMStockOwner EWMStockOwner Character Field with Length 10
StockType StockType Stock Type
EWMStockType EWMStockType Stock Type
QuantityUnit QuantityUnit Unit of measure
ProductQuantity ProductQuantity Quantity
CompletionStatus CompletionStatus Status Value
GoodsReceiptStatus GoodsReceiptStatus Status Value
LastChangeTime LastChangeTime Time changed
EWMDelivLastChangeUTCDateTime EWMDelivLastChangeUTCDateTime Time Stamp
ShipFromParty _InboundDeliveyHeader ShipFromParty Busn. Partner
Carrier _InboundDeliveyHeader Carrier Service Agent
ShipFromPartyName _InboundDeliveyHeader ShipFromPartyName Ship-From Party Name
CarrierName _InboundDeliveyHeader CarrierName Carrier Name
NameOfEntitledToDisposeParty _DisposalParty BusinessPartnerName Extracted Customer Name
StockOwnerName _Owner BusinessPartnerName Extracted Customer Name
CurrentUTCTimestamp
ActualPutawayEndUTCDateTime
ActualGRStartUTCDateTime
PlannedGRStartUTCDateTime
ActualGREndUTCDateTime
PlannedGREndUTCDateTime
UnloadingEndUTCDateTime
InbDelivCompltnEndUTCDateTime
ActualArrivalInYardUTCDateTime
PlndArrivalInYardUTCDateTime
TransportationUnitAssgmtStatus
PlanningPutawayStatus
CheckToleranceStatus
GoodsMovementBlockStatus
QualityMgmtInspectionStatus
QualityMgmtInspPlngStatus
QualityMgmtCountPlngStatus
PutawayStatus
ValuationQtyAssignmentStatus
ValueAddedServiceOrderStatus
UnloadingStatus
TransitStatus
TransitProcedureStatus
TransportationPlanningStatus
OverallBlockStatus
ItemInconsistencyBlkStatus
TranspPlanBlockStatus
WarehouseActivityStatus
DisplayVolumeUnit _whseControl DisplayVolumeUnit
DisplayWeightUnit _whseControl DisplayWeightUnit
MeansOfTransport _Transportation EWMMeansOfTransport Means of Tr. ID
EWMMeansOfTransport _Transportation EWMMeansOfTransport Means of Tr. ID
MeansOfTransportType _Transportation EWMMeansOfTransportType Means of Trans.
EWMMeansOfTransportType _Transportation EWMMeansOfTransportType Means of Trans.
InbDelivItemCrtnUTCDateTime InbDelivItemCrtnUTCDateTime
PlndGREndWhseTmznDateTime PlndGREndWhseTmznDateTime
PlndGoodsReceiptWhseTmznYear
PlndGoodsReceiptWhseTmznMonth
PlndGoodsReceiptWhseTmznDate
PlndGoodsReceiptWhseTmznHour
PlndGoodsReceiptWhseTmznTime
UnloadingEndWhseTmznDateTime UnloadingEndWhseTmznDateTime
UnloadingEndWhseTmznYear
UnloadingEndWhseTmznMonth
UnloadingEndWhseTmznDate
UnloadingEndWhseTmznHour
UnloadingEndWhseTmznTime
PutawayEndWhseTmznDateTime PutawayEndWhseTmznDateTime
PutawayEndWhseTmznYear
PutawayEndWhseTmznMonth
PutawayEndWhseTmznDate
PutawayEndWhseTmznHour
PutawayEndWhseTmznTime
ActualGREndWhseTmznDateTime ActualGREndWhseTmznDateTime
GoodsReceiptEndWhseTmznYear
GoodsReceiptEndWhseTmznMonth
GoodsReceiptEndWhseTmznDate
GoodsReceiptEndWhseTmznHour
GoodsReceiptEndWhseTmznTime
InbDelivItmCmpltWhseTmznDteTme InbDelivItmCmpltWhseTmznDteTme
InbDelivCompltnEndWhseTmznYear
InbDelivCompltnEndWhseTmznMnth
InbDelivCompltnEndWhseTmznDate
InbDelivCompltnEndWhseTmznHour
InbDelivCompltnEndWhseTmznTime
InbDelivCrtnWhseTmznDateTime _InboundDeliveyHeader InbDelivCrtnWhseTmznDateTime
PlndDeliveryWhseTmznDateTime _InboundDeliveyHeader PlndDeliveryWhseTmznDateTime
ActualDeliveryWhseTmznDateTime _InboundDeliveyHeader ActualDeliveryWhseTmznDateTime
PlndArrvlInYardWhseTmznDteTme _InboundDeliveyHeader PlndArrvlInYardWhseTmznDteTme
ActlArrvlInYardWhseTmznDteTme _InboundDeliveyHeader ActlArrvlInYardWhseTmznDteTme
PlannedDeliveryWhseTmznYear _InboundDeliveyHeader PlannedDeliveryWhseTmznYear
PlannedDeliveryWhseTmznMonth _InboundDeliveyHeader PlannedDeliveryWhseTmznMonth
PlannedDeliveryWhseTmznDate _InboundDeliveyHeader PlannedDeliveryWhseTmznDate
PlannedDeliveryWhseTmznHour _InboundDeliveyHeader PlannedDeliveryWhseTmznHour
PlannedDeliveryWhseTmznTime _InboundDeliveyHeader PlannedDeliveryWhseTmznTime
ActualDeliveryWhseTmznYear _InboundDeliveyHeader ActualDeliveryWhseTmznYear
ActualDeliveryWhseTmznMonth _InboundDeliveyHeader ActualDeliveryWhseTmznMonth
ActualDeliveryWhseTmznDate _InboundDeliveyHeader ActualDeliveryWhseTmznDate
ActualDeliveryWhseTmznHour _InboundDeliveyHeader ActualDeliveryWhseTmznHour
ActualDeliveryWhseTmznTime _InboundDeliveyHeader ActualDeliveryWhseTmznTime
PlndArrvlInYardWhseTmznYear _InboundDeliveyHeader PlndArrvlInYardWhseTmznYear
PlndArrvlInYardWhseTmznMonth _InboundDeliveyHeader PlndArrvlInYardWhseTmznMonth
PlndArrvlInYardWhseTmznDate _InboundDeliveyHeader PlndArrvlInYardWhseTmznDate
PlndArrvlInYardWhseTmznHour _InboundDeliveyHeader PlndArrvlInYardWhseTmznHour
PlndArrvlInYardWhseTmznTime _InboundDeliveyHeader PlndArrvlInYardWhseTmznTime
ActlArrvlInYardWhseTmznYear _InboundDeliveyHeader ActlArrvlInYardWhseTmznYear
ActlArrvlInYardWhseTmznMonth _InboundDeliveyHeader ActlArrvlInYardWhseTmznMonth
ActlArrvlInYardWhseTmznDate _InboundDeliveyHeader ActlArrvlInYardWhseTmznDate
ActlArrvlInYardWhseTmznHour _InboundDeliveyHeader ActlArrvlInYardWhseTmznHour
ActlArrvlInYardWhseTmznTime _InboundDeliveyHeader ActlArrvlInYardWhseTmznTime
WhseTmznPlannedDeliverymins _InboundDeliveyHeader WhseTmznPlannedDeliverymins
WhseTmznPlndArrivalinYardmins _InboundDeliveyHeader WhseTmznPlndArrivalinYardmins
WhseTmznActualDeliverymins _InboundDeliveyHeader WhseTmznActualDeliverymins
WhseTmznActualArrvlinYardmins _InboundDeliveyHeader WhseTmznActualArrvlinYardmins
TimeZoneID _InboundDeliveyHeader TimeZoneID Time Zone
WhseTmznItemCreationmins
WhseTmznCompletionEndmins
WhseTmznGoodsReceiptEndmins
WhseTmznPutawayEndmins
WhseTmznUnloadingEndmins
ReceivingOffice _ReceivingOffice OrganizationalUnit Org. Unit ID
EWMDeliveryAdjustmentQuantity _QuantityAdjustment EWMDeliveryAdjustmentQuantity
_ItemStatus _ItemStatus
_whseControl _whseControl
_InboundDeliveyHeader _InboundDeliveyHeader
EWMWarehouseCurrentDate _InboundDeliveyHeader EWMWarehouseCurrentDate

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_EWM_InboundDeliveryItem.
-- 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: PEWMINBDELIVITEM

CREATE VIEW P_EWM_InboundDeliveryItem AS
SELECT
  InboundDeliveryUUID,
  InboundDeliveryItemUUID,
  Warehouse,
  EWMWarehouse,
  InboundDelivery,
  EWMInboundDelivery,
  InboundDeliveryItem,
  EWMInboundDeliveryItem,
  _InboundDeliveyHeader.InboundDeliveryDocumentType AS InboundDeliveryDocumentType,
  DeliveryDocumentCategory,
  DeliveryItemCategory,
  EWMInboundDeliveryItemCategory,
  InboundDeliveryItemType,
  EWMInboundDeliveryItemType,
  WarehouseProcessType,
  WarehouseDoor,
  StagingAreaGroup,
  StagingArea,
  StagingBay,
  GoodsMovementBin,
  Product,
  Batch,
  RequirementSegment,
  StockSegment,
  EntitledToDisposeParty,
  StockOwner,
  EWMStockOwner,
  StockType,
  EWMStockType,
  QuantityUnit,
  ProductQuantity,
  CompletionStatus,
  GoodsReceiptStatus,
  LastChangeTime,
  EWMDelivLastChangeUTCDateTime,
  _InboundDeliveyHeader.ShipFromParty AS ShipFromParty,
  _InboundDeliveyHeader.Carrier AS Carrier,
  _InboundDeliveyHeader.ShipFromPartyName AS ShipFromPartyName,
  _InboundDeliveyHeader.CarrierName AS CarrierName,
  _DisposalParty.BusinessPartnerName AS NameOfEntitledToDisposeParty,
  _Owner.BusinessPartnerName AS StockOwnerName,
  tstmp_current_utctimestamp() AS CurrentUTCTimestamp,
  _DeliveryItemDateTime[1:DeliveryDateTimeType = 'EPTAW' and DeliveryDateTimeCategory ='ACTUAL'].DeliveryRelatedEndDateTime AS ActualPutawayEndUTCDateTime,
  _DeliveryItemDateTime[1:DeliveryDateTimeType = 'SGOODSRECPT'and DeliveryDateTimeCategory = 'ACTUAL'].DeliveryRelatedStartDateTime AS ActualGRStartUTCDateTime,
  _DeliveryItemDateTime[1:DeliveryDateTimeType = 'SGOODSRECPT'and DeliveryDateTimeCategory = 'PLAN'].DeliveryRelatedStartDateTime AS PlannedGRStartUTCDateTime,
  _DeliveryItemDateTime[1:DeliveryDateTimeType = 'EGOODSRECPT' and DeliveryDateTimeCategory ='ACTUAL'].DeliveryRelatedEndDateTime AS ActualGREndUTCDateTime,
  _DeliveryItemDateTime[1:DeliveryDateTimeType = 'EGOODSRECPT' and DeliveryDateTimeCategory ='PLAN'].DeliveryRelatedEndDateTime AS PlannedGREndUTCDateTime,
  _ItemStatus[1:DeliveryStatusType = 'DUN'].ValidityEndUTCDateTime AS UnloadingEndUTCDateTime,
  _ItemStatus[1:DeliveryStatusType = 'DCO' and EWMDeliveryStatus = '9'].ValidityEndUTCDateTime AS InbDelivCompltnEndUTCDateTime,
  _InboundDeliveyHeader._DeliveryDateTime[1:DeliveryDateTimeType = 'TINYARD'and DeliveryDateTimeCategory = 'ACTUAL' ].DeliveryRelatedEndDateTime AS ActualArrivalInYardUTCDateTime,
  _InboundDeliveyHeader._DeliveryDateTime[1:DeliveryDateTimeType = 'TINYARD'and DeliveryDateTimeCategory = 'PLAN' ].DeliveryRelatedEndDateTime AS PlndArrivalInYardUTCDateTime,
  _ItemStatus[1:DeliveryStatusType = 'DTU'].EWMDeliveryStatus AS TransportationUnitAssgmtStatus,
  _ItemStatus[1:DeliveryStatusType = 'DEU'].EWMDeliveryStatus AS PlanningPutawayStatus,
  _ItemStatus[1:DeliveryStatusType = 'DTL'].EWMDeliveryStatus AS CheckToleranceStatus,
  _ItemStatus[1:DeliveryStatusType = 'DWG'].EWMDeliveryStatus AS GoodsMovementBlockStatus,
  _ItemStatus[1:DeliveryStatusType = 'DQE'].EWMDeliveryStatus AS QualityMgmtInspectionStatus,
  _ItemStatus[1:DeliveryStatusType = 'DQP'].EWMDeliveryStatus AS QualityMgmtInspPlngStatus,
  _ItemStatus[1:DeliveryStatusType = 'DQS'].EWMDeliveryStatus AS QualityMgmtCountPlngStatus,
  _ItemStatus[1:DeliveryStatusType = 'DPT'].EWMDeliveryStatus AS PutawayStatus,
  _ItemStatus[1:DeliveryStatusType = 'DVQ'].EWMDeliveryStatus AS ValuationQtyAssignmentStatus,
  _ItemStatus[1:DeliveryStatusType = 'DWV'].EWMDeliveryStatus AS ValueAddedServiceOrderStatus,
  _ItemStatus[1:DeliveryStatusType = 'DUN'].EWMDeliveryStatus AS UnloadingStatus,
  _ItemStatus[1:DeliveryStatusType = 'DTR'].EWMDeliveryStatus AS TransitStatus,
  _ItemStatus[1:DeliveryStatusType = 'DWN'].EWMDeliveryStatus AS TransitProcedureStatus,
  _ItemStatus[1:DeliveryStatusType = 'DTD'].EWMDeliveryStatus AS TransportationPlanningStatus,
  _ItemStatus[1:DeliveryStatusType = 'DBO'].EWMDeliveryStatus AS OverallBlockStatus,
  _ItemStatus[1:DeliveryStatusType = 'DBD'].EWMDeliveryStatus AS ItemInconsistencyBlkStatus,
  _ItemStatus[1:DeliveryStatusType = 'DBT'].EWMDeliveryStatus AS TranspPlanBlockStatus,
  _ItemStatus[1:DeliveryStatusType = 'DWA'].EWMDeliveryStatus AS WarehouseActivityStatus,
  _whseControl.DisplayVolumeUnit AS DisplayVolumeUnit,
  _whseControl.DisplayWeightUnit AS DisplayWeightUnit,
  _Transportation.EWMMeansOfTransport AS MeansOfTransport,
  _Transportation.EWMMeansOfTransport AS EWMMeansOfTransport,
  _Transportation.EWMMeansOfTransportType AS MeansOfTransportType,
  _Transportation.EWMMeansOfTransportType AS EWMMeansOfTransportType,
  InbDelivItemCrtnUTCDateTime,
  PlndGREndWhseTmznDateTime,
  cast(substring(cast(PlndGREndWhseTmznDateTime as abap.char( 17 )), 1, 4) as /scwm/de_datetime_year) AS PlndGoodsReceiptWhseTmznYear,
  cast(substring(cast(PlndGREndWhseTmznDateTime as abap.char( 17 )), 1, 6) as /scwm/de_datetime_mon) AS PlndGoodsReceiptWhseTmznMonth,
  cast(substring(cast(PlndGREndWhseTmznDateTime as abap.char( 17 )), 1, 8) as /scwm/de_datetime_date) AS PlndGoodsReceiptWhseTmznDate,
  cast(substring(cast(PlndGREndWhseTmznDateTime as abap.char( 17 )), 1, 10) as /scwm/de_datetime_hour) AS PlndGoodsReceiptWhseTmznHour,
  cast(substring(cast(PlndGREndWhseTmznDateTime as abap.char( 17 )), 9, 6) as /scwm/de_datetime_time) AS PlndGoodsReceiptWhseTmznTime,
  UnloadingEndWhseTmznDateTime,
  cast(substring(cast(UnloadingEndWhseTmznDateTime as abap.char( 17 )), 1, 4) as /scwm/de_datetime_year) AS UnloadingEndWhseTmznYear,
  cast(substring(cast(UnloadingEndWhseTmznDateTime as abap.char( 17 )), 1, 6) as /scwm/de_datetime_mon) AS UnloadingEndWhseTmznMonth,
  cast(substring(cast(UnloadingEndWhseTmznDateTime as abap.char( 17 )), 1, 8) as /scwm/de_datetime_date) AS UnloadingEndWhseTmznDate,
  cast(substring(cast(UnloadingEndWhseTmznDateTime as abap.char( 17 )), 1, 10) as /scwm/de_datetime_hour) AS UnloadingEndWhseTmznHour,
  cast(substring(cast(UnloadingEndWhseTmznDateTime as abap.char( 17 )), 9, 6) as /scwm/de_datetime_time) AS UnloadingEndWhseTmznTime,
  PutawayEndWhseTmznDateTime,
  cast(substring(cast(PutawayEndWhseTmznDateTime as abap.char( 17 )), 1, 4) as /scwm/de_datetime_year) AS PutawayEndWhseTmznYear,
  cast(substring(cast(PutawayEndWhseTmznDateTime as abap.char( 17 )), 1, 6) as /scwm/de_datetime_mon) AS PutawayEndWhseTmznMonth,
  cast(substring(cast(PutawayEndWhseTmznDateTime as abap.char( 17 )), 1, 8) as /scwm/de_datetime_date) AS PutawayEndWhseTmznDate,
  cast(substring(cast(PutawayEndWhseTmznDateTime as abap.char( 17 )), 1, 10) as /scwm/de_datetime_hour) AS PutawayEndWhseTmznHour,
  cast(substring(cast(PutawayEndWhseTmznDateTime as abap.char( 17 )), 9, 6) as /scwm/de_datetime_time) AS PutawayEndWhseTmznTime,
  ActualGREndWhseTmznDateTime,
  cast(substring(cast(ActualGREndWhseTmznDateTime as abap.char( 17 )), 1, 4) as /scwm/de_datetime_year) AS GoodsReceiptEndWhseTmznYear,
  cast(substring(cast(ActualGREndWhseTmznDateTime as abap.char( 17 )), 1, 6) as /scwm/de_datetime_mon) AS GoodsReceiptEndWhseTmznMonth,
  cast(substring(cast(ActualGREndWhseTmznDateTime as abap.char( 17 )), 1, 8) as /scwm/de_datetime_date) AS GoodsReceiptEndWhseTmznDate,
  cast(substring(cast(ActualGREndWhseTmznDateTime as abap.char( 17 )), 1, 10) as /scwm/de_datetime_hour) AS GoodsReceiptEndWhseTmznHour,
  cast(substring(cast(ActualGREndWhseTmznDateTime as abap.char( 17 )), 9, 6) as /scwm/de_datetime_time) AS GoodsReceiptEndWhseTmznTime,
  InbDelivItmCmpltWhseTmznDteTme,
  cast(substring(cast(InbDelivItmCmpltWhseTmznDteTme as abap.char( 17 )), 1, 4) as /scwm/de_datetime_year) AS InbDelivCompltnEndWhseTmznYear,
  cast(substring(cast(InbDelivItmCmpltWhseTmznDteTme as abap.char( 17 )), 1, 6) as /scwm/de_datetime_mon) AS InbDelivCompltnEndWhseTmznMnth,
  cast(substring(cast(InbDelivItmCmpltWhseTmznDteTme as abap.char( 17 )), 1, 8) as /scwm/de_datetime_date) AS InbDelivCompltnEndWhseTmznDate,
  cast(substring(cast(InbDelivItmCmpltWhseTmznDteTme as abap.char( 17 )), 1, 10) as /scwm/de_datetime_hour) AS InbDelivCompltnEndWhseTmznHour,
  cast(substring(cast(InbDelivItmCmpltWhseTmznDteTme as abap.char( 17 )), 9, 6) as /scwm/de_datetime_time) AS InbDelivCompltnEndWhseTmznTime,
  _InboundDeliveyHeader.InbDelivCrtnWhseTmznDateTime AS InbDelivCrtnWhseTmznDateTime,
  _InboundDeliveyHeader.PlndDeliveryWhseTmznDateTime AS PlndDeliveryWhseTmznDateTime,
  _InboundDeliveyHeader.ActualDeliveryWhseTmznDateTime AS ActualDeliveryWhseTmznDateTime,
  _InboundDeliveyHeader.PlndArrvlInYardWhseTmznDteTme AS PlndArrvlInYardWhseTmznDteTme,
  _InboundDeliveyHeader.ActlArrvlInYardWhseTmznDteTme AS ActlArrvlInYardWhseTmznDteTme,
  _InboundDeliveyHeader.PlannedDeliveryWhseTmznYear AS PlannedDeliveryWhseTmznYear,
  _InboundDeliveyHeader.PlannedDeliveryWhseTmznMonth AS PlannedDeliveryWhseTmznMonth,
  _InboundDeliveyHeader.PlannedDeliveryWhseTmznDate AS PlannedDeliveryWhseTmznDate,
  _InboundDeliveyHeader.PlannedDeliveryWhseTmznHour AS PlannedDeliveryWhseTmznHour,
  _InboundDeliveyHeader.PlannedDeliveryWhseTmznTime AS PlannedDeliveryWhseTmznTime,
  _InboundDeliveyHeader.ActualDeliveryWhseTmznYear AS ActualDeliveryWhseTmznYear,
  _InboundDeliveyHeader.ActualDeliveryWhseTmznMonth AS ActualDeliveryWhseTmznMonth,
  _InboundDeliveyHeader.ActualDeliveryWhseTmznDate AS ActualDeliveryWhseTmznDate,
  _InboundDeliveyHeader.ActualDeliveryWhseTmznHour AS ActualDeliveryWhseTmznHour,
  _InboundDeliveyHeader.ActualDeliveryWhseTmznTime AS ActualDeliveryWhseTmznTime,
  _InboundDeliveyHeader.PlndArrvlInYardWhseTmznYear AS PlndArrvlInYardWhseTmznYear,
  _InboundDeliveyHeader.PlndArrvlInYardWhseTmznMonth AS PlndArrvlInYardWhseTmznMonth,
  _InboundDeliveyHeader.PlndArrvlInYardWhseTmznDate AS PlndArrvlInYardWhseTmznDate,
  _InboundDeliveyHeader.PlndArrvlInYardWhseTmznHour AS PlndArrvlInYardWhseTmznHour,
  _InboundDeliveyHeader.PlndArrvlInYardWhseTmznTime AS PlndArrvlInYardWhseTmznTime,
  _InboundDeliveyHeader.ActlArrvlInYardWhseTmznYear AS ActlArrvlInYardWhseTmznYear,
  _InboundDeliveyHeader.ActlArrvlInYardWhseTmznMonth AS ActlArrvlInYardWhseTmznMonth,
  _InboundDeliveyHeader.ActlArrvlInYardWhseTmznDate AS ActlArrvlInYardWhseTmznDate,
  _InboundDeliveyHeader.ActlArrvlInYardWhseTmznHour AS ActlArrvlInYardWhseTmznHour,
  _InboundDeliveyHeader.ActlArrvlInYardWhseTmznTime AS ActlArrvlInYardWhseTmznTime,
  _InboundDeliveyHeader.WhseTmznPlannedDeliverymins AS WhseTmznPlannedDeliverymins,
  _InboundDeliveyHeader.WhseTmznPlndArrivalinYardmins AS WhseTmznPlndArrivalinYardmins,
  _InboundDeliveyHeader.WhseTmznActualDeliverymins AS WhseTmznActualDeliverymins,
  _InboundDeliveyHeader.WhseTmznActualArrvlinYardmins AS WhseTmznActualArrvlinYardmins,
  _InboundDeliveyHeader.TimeZoneID AS TimeZoneID,
  cast(substring(cast(InbDelivItemCrtnUTCDateTime as abap.char( 17 )), 11, 2) as abap.numc( 2 ) ) AS WhseTmznItemCreationmins,
  cast(substring(cast(InbDelivItmCmpltWhseTmznDteTme as abap.char( 17 )), 11, 2) as abap.numc( 2 ) ) AS WhseTmznCompletionEndmins,
  cast(substring(cast(ActualGREndWhseTmznDateTime as abap.char( 17 )), 11, 2) as abap.numc( 2 ) ) AS WhseTmznGoodsReceiptEndmins,
  cast(substring(cast(PutawayEndWhseTmznDateTime as abap.char( 17 )), 11, 2) as abap.numc( 2 ) ) AS WhseTmznPutawayEndmins,
  cast(substring(cast(UnloadingEndWhseTmznDateTime as abap.char( 17 )), 11, 2) as abap.numc( 2 ) ) AS WhseTmznUnloadingEndmins,
  _ReceivingOffice.OrganizationalUnit AS ReceivingOffice,
  _QuantityAdjustment.EWMDeliveryAdjustmentQuantity AS EWMDeliveryAdjustmentQuantity,
  _InboundDeliveyHeader.EWMWarehouseCurrentDate AS EWMWarehouseCurrentDate
FROM I_EWM_InbDeliveryItemBasic
LEFT OUTER JOIN P_EWM_ProcessCodeDelivQtyChg AS _QuantityAdjustment ON InboundDeliveryUUID = _QuantityAdjustment.DeliveryUUID AND InboundDeliveryItemUUID = _QuantityAdjustment.DeliveryItemUUID AND _QuantityAdjustment.DeliveryDocumentCategory = 'PDI'  -- association [0..1]
LEFT OUTER JOIN P_EWM_InboundDeliveryHeader AS _InboundDeliveyHeader ON InboundDeliveryUUID = _InboundDeliveyHeader.InboundDeliveryUUID  -- association [0..1]
LEFT OUTER JOIN I_EWM_WhseReqTransportation AS _Transportation ON InboundDeliveryUUID = _Transportation.EWMWarehouseRequestUUID AND _Transportation.EWMWhseRequestDocumentCategory = 'PDI'  -- association [0..1]
LEFT OUTER JOIN I_EWM_DeliveryBPLocation AS _ReceivingOffice ON InboundDeliveryUUID = _ReceivingOffice.OutboundDeliveryOrderUUID AND _ReceivingOffice.BusinessPartnerRole = 'SO' AND _ReceivingOffice.EWMDeliveryDocumentCategory = 'PDI'  -- association [0..1]
LEFT OUTER JOIN I_EWM_WarehouseControl_2 AS _whseControl ON EWMWarehouse = _whseControl.EWMWarehouse  -- association [0..1]
LEFT OUTER JOIN I_BusinessPartner AS _Owner ON StockOwner = _Owner.BusinessPartner  -- association [0..1]
LEFT OUTER JOIN I_BusinessPartner AS _DisposalParty ON EntitledToDisposeParty = _DisposalParty.BusinessPartner  -- association [0..1]
;