I_DepdntResvnQuickView

DDL: I_DEPDNTRESVNQUICKVIEW SQL: IDEPDNTRESVQV Type: view COMPOSITE Package: ODATA_PP_DD_ORD_DET

Dependent Requirement and Order Reservation Details

I_DepdntResvnQuickView is a Composite CDS View that provides data about "Dependent Requirement and Order Reservation Details" in SAP S/4HANA. It reads from 4 data sources (I_ProductSupplyPlanning, I_ProductSupplyPlanning, I_ReservationItem, I_ReservationItem) and exposes 123 fields with key fields Reservation, ReservationItem, RecordType, ReservationItem, RecordType. It has 4 associations to related views. Part of development package ODATA_PP_DD_ORD_DET.

Data Sources (4)

SourceAliasJoin Type
I_ProductSupplyPlanning marc inner
I_ProductSupplyPlanning marc inner
I_ReservationItem resb from
I_ReservationItem resb union_all

Associations (4)

CardinalityTargetAliasCondition
[0..1] I_PlannedOrderQuickView _plaf $projection.PlannedOrder = _plaf.PlannedOrder
[0..1] I_Order _Order resb.ReferenceOrder = _Order.OrderID
[0..1] I_RoundingPrfText _RoundingProfile $projection.RoundingProfile = _RoundingProfile.MaterialRoundingProfile and $projection.Plant = _RoundingProfile.Plant
[0..1] I_ProductionOrderQuickView _afpo resb.ReferenceOrder = _afpo.OrderID and _afpo.ManufacturingOrderItem = '0001'

Annotations (11)

NameValueLevelField
AbapCatalog.sqlViewName IDEPDNTRESVQV view
AbapCatalog.compiler.compareFilter true view
AbapCatalog.preserveKey true view
AccessControl.authorizationCheck #CHECK view
EndUserText.label Dependent Requirement and Order Reservation Details view
VDM.viewType #COMPOSITE view
ClientHandling.algorithm #SESSION_VARIABLE view
ObjectModel.usageType.serviceQuality #X view
ObjectModel.usageType.sizeCategory #XXL view
ObjectModel.usageType.dataClass #MIXED view
AccessControl.personalData.blocking #BLOCKED_DATA_EXCLUDED view

Fields (123)

KeyFieldSource TableSource FieldDescription
KEY Reservation I_ReservationItem Reservation
KEY ReservationItem I_ReservationItem ReservationItem
KEY RecordType I_ReservationItem RecordType
RequirementType I_ReservationItem RequirementType
RequirementDate I_ReservationItem MatlCompRequirementDate
Material I_ReservationItem Material
Plant I_ReservationItem Plant
PlannedOrder I_ReservationItem PlannedOrder
ManufacturingOrder I_ReservationItem ReferenceOrder
BaseUnit I_ReservationItem BaseUnit
CommittedQuantity I_ReservationItem ConfdQtyForATPInBaseUoM
WithdrawnQuantity I_ReservationItem ResvnItmWithdrawnQtyInBaseUnit
MRPElementOpenQuantity
ParentComponent
ParentPlant
MRPController
MRPControllerName
InternalContactPersonName
InternalContactPhoneNumber
InternalContactEmailAddress
ProductionSupervisor
ProductionSupervisorName
OrderedQuantity
OrderType
OrderTypeName
BasicStartDate
BasicEndDate
MaterialGoodsReceiptDuration
TotalQuantity
MRPElementPlannedScrapQuantity
GoodsReceiptQty
PlndOrderPlannedScrapQtyasOpenQuantity
ProductionPlant
ProductionPlantName
ProductionVersion
ProductionVersionText
ProductionLine
ProductionLineText
SalesOrder
SalesOrderItem
Customer
CustomerName
WBSElement
WBSElementInternalID
InHouseProductionTime I_ProductSupplyPlanning InHouseProductionTime
TotalReplenishmentLeadTime I_ProductSupplyPlanning TotalReplenishmentLeadTime
MinimumLotSizeQuantity I_ProductSupplyPlanning MinimumLotSizeQuantity
MaximumLotSizeQuantity I_ProductSupplyPlanning MaximumLotSizeQuantity
LotSizeRoundingQuantity I_ProductSupplyPlanning LotSizeRoundingQuantity
RoundingProfile I_ProductSupplyPlanning RoundingProfile
MaterialRoundingProfileName
PlannedOrderOpeningDate
MaterialProcurementType
MaterialProcurementTypeName
MfgOrderReleasedCode
MfgOrderScheduledReleaseDate
MfgOrderScheduledStartDate
MfgOrderScheduledEndDate
ExpectedDeviationQuantity
ManufacturingOrderImportance
ManufacturingOrderCategory
Reservation
KEY ReservationItem I_ReservationItem ReservationItem
KEY RecordType I_ReservationItem RecordType
RequirementType I_ReservationItem RequirementType
RequirementDate I_ReservationItem MatlCompRequirementDate
Material I_ReservationItem Material
Plant I_ReservationItem Plant
PlannedOrder I_ReservationItem PlannedOrder
ManufacturingOrder I_ReservationItem ReferenceOrder
BaseUnit I_ReservationItem BaseUnit
CommittedQuantity I_ReservationItem ConfdQtyForATPInBaseUoM
WithdrawnQuantity I_ReservationItem ResvnItmWithdrawnQtyInBaseUnit
MRPElementOpenQuantity
ParentComponent _afpo Material
ParentPlant _afpo MRPPlant
MRPController _afpo MRPController
MRPControllerName _afpo MRPControllerName
InternalContactPersonName _afpo InternalContactPersonName
InternalContactPhoneNumber _afpo InternalContactPhoneNumber
InternalContactEmailAddress _afpo InternalContactEmailAddress
ProductionSupervisor _afpo ProductionSupervisor
ProductionSupervisorName _afpo ProductionSupervisorName
OrderedQuantity I_ReservationItem ResvnItmRequiredQtyInBaseUnit
OrderType _afpo ManufacturingOrderType
OrderTypeName _afpo ManufacturingOrderTypeName
BasicStartDate _afpo MfgOrderPlannedStartDate
BasicEndDate _afpo MfgOrderPlannedEndDate
MaterialGoodsReceiptDuration _afpo MaterialGoodsReceiptDuration
TotalQuantity _afpo MfgOrderPlannedTotalQty
MRPElementPlannedScrapQuantity _afpo MfgOrderPlannedScrapQty
GoodsReceiptQty _afpo MfgOrderItemGoodsReceiptQty
OpenQuantity _afpo MRPElementOpenQuantity
ProductionPlant _afpo ProductionPlant
ProductionPlantName _afpo ProductionPlantName
ProductionVersion _afpo ProductionVersion
ProductionVersionText _afpo ProductionVersionText
ProductionLine _afpo ProductionLine
ProductionLineText
SalesOrder _afpo SalesOrder
SalesOrderItem _afpo SalesOrderItem
Customer
CustomerName
WBSElement
WBSElementInternalID
InHouseProductionTime I_ProductSupplyPlanning InHouseProductionTime
TotalReplenishmentLeadTime I_ProductSupplyPlanning TotalReplenishmentLeadTime
MinimumLotSizeQuantity I_ProductSupplyPlanning MinimumLotSizeQuantity
MaximumLotSizeQuantity I_ProductSupplyPlanning MaximumLotSizeQuantity
LotSizeRoundingQuantity I_ProductSupplyPlanning LotSizeRoundingQuantity
RoundingProfile I_ProductSupplyPlanning RoundingProfile
MaterialRoundingProfileName
PlannedOrderOpeningDate
MaterialProcurementType
MaterialProcurementTypeName
MfgOrderReleasedCode _afpo MfgOrderReleasedCode
MfgOrderScheduledReleaseDate _afpo MfgOrderScheduledReleaseDate
MfgOrderScheduledStartDate _afpo MfgOrderScheduledStartDate
MfgOrderScheduledEndDate _afpo MfgOrderScheduledEndDate
ExpectedDeviationQuantity _afpo ExpectedDeviationQuantity
ManufacturingOrderImportance _afpo ManufacturingOrderImportance
ManufacturingOrderCategory _afpo ManufacturingOrderCategory
_Order _Order
@AbapCatalog.sqlViewName: 'IDEPDNTRESVQV'
@AbapCatalog.compiler.compareFilter: true
@AbapCatalog.preserveKey: true
@AccessControl.authorizationCheck: #CHECK
@EndUserText.label: 'Dependent Requirement and Order Reservation Details'
@VDM.viewType: #COMPOSITE
@ClientHandling.algorithm: #SESSION_VARIABLE
@ObjectModel.usageType: {serviceQuality: #X, sizeCategory: #XXL, dataClass: #MIXED}
@AccessControl.personalData.blocking: #BLOCKED_DATA_EXCLUDED
define view I_DepdntResvnQuickView
  as select from I_ReservationItem       as resb
    inner join   I_ProductSupplyPlanning as marc on  resb.Material = marc.Product
                                                 and resb.Plant    = marc.Plant
                                               
  association [0..1] to I_PlannedOrderQuickView    as _plaf            on  $projection.PlannedOrder = _plaf.PlannedOrder
                                                                                                                                           
  association [0..1] to I_Order                    as _Order           on  resb.ReferenceOrder = _Order.OrderID
  association [0..1] to I_RoundingPrfText          as _RoundingProfile on  $projection.RoundingProfile = _RoundingProfile.MaterialRoundingProfile
                                                                       and $projection.Plant           = _RoundingProfile.Plant
                                                                       

{
      //Common Fields

  key resb.Reservation,
  key resb.ReservationItem,
  key resb.RecordType,
      resb.RequirementType,
      resb.MatlCompRequirementDate                                             as RequirementDate,
      resb.Material,
      resb.Plant,
      resb.PlannedOrder,
      resb.ReferenceOrder                                                      as ManufacturingOrder,
      @Semantics.unitOfMeasure: true
      resb.BaseUnit,
      @Semantics.quantity.unitOfMeasure: 'BaseUnit'
      resb.ConfdQtyForATPInBaseUoM                                             as CommittedQuantity,
      @Semantics.quantity.unitOfMeasure: 'BaseUnit'
      resb.ResvnItmWithdrawnQtyInBaseUnit                                      as WithdrawnQuantity,
      @Semantics.quantity.unitOfMeasure: 'BaseUnit'
      resb.ResvnItmRequiredQtyInBaseUnit - resb.ResvnItmWithdrawnQtyInBaseUnit as MRPElementOpenQuantity,

      
      _plaf(P_MRPElementCategory:'PA').Material                                as ParentComponent,

      
      _plaf(P_MRPElementCategory:'PA').MRPPlant                                as ParentPlant,

      _plaf(P_MRPElementCategory : 'PA').MRPController                         as MRPController,

      _plaf(P_MRPElementCategory : 'PA').MRPControllerName                     as MRPControllerName,

      _plaf(P_MRPElementCategory : 'PA').InternalContactPersonName             as InternalContactPersonName,

      _plaf(P_MRPElementCategory : 'PA').InternalContactPhoneNumber            as InternalContactPhoneNumber,

      _plaf(P_MRPElementCategory : 'PA').InternalContactEmailAddress           as InternalContactEmailAddress,

      _plaf(P_MRPElementCategory : 'PA').ProductionSupervisor                  as ProductionSupervisor,

      _plaf(P_MRPElementCategory : 'PA').ProductionSupervisorName              as ProductionSupervisorName,

      _plaf(P_MRPElementCategory : 'PA').PlndOrderPlannedTotalQty              as OrderedQuantity,

      _plaf(P_MRPElementCategory:'PA').PlannedOrderType                        as OrderType,

      _plaf(P_MRPElementCategory:'PA').PlannedOrderTypeName                    as OrderTypeName,

      _plaf(P_MRPElementCategory:'PA').PlndOrderPlannedStartDate               as BasicStartDate,

      _plaf(P_MRPElementCategory:'PA').PlndOrderPlannedEndDate                 as BasicEndDate,

      _plaf(P_MRPElementCategory:'PA').MaterialGoodsReceiptDuration            as MaterialGoodsReceiptDuration,

      _plaf(P_MRPElementCategory:'PA').PlndOrderPlannedTotalQty                as TotalQuantity,

      _plaf(P_MRPElementCategory:'PA').PlndOrderPlannedScrapQty                as MRPElementPlannedScrapQuantity,

      _plaf(P_MRPElementCategory:'PA').GoodsReceiptQty                         as GoodsReceiptQty,

      resb.ResvnItmRequiredQtyInBaseUnit - 
      _plaf(P_MRPElementCategory:'PA').PlndOrderPlannedScrapQty - 
      _plaf(P_MRPElementCategory:'PA').PlndOrderPlannedScrapQty                as OpenQuantity,
      
      _plaf(P_MRPElementCategory:'PA').ProductionPlant                         as ProductionPlant,

      _plaf(P_MRPElementCategory:'PA').ProductionPlantName                     as ProductionPlantName,

      _plaf(P_MRPElementCategory:'PA').ProductionVersion                       as ProductionVersion,

      _plaf(P_MRPElementCategory:'PA').ProductionVersionText                   as ProductionVersionText,
      
      _plaf(P_MRPElementCategory:'PA').ProductionLine                          as ProductionLine,
      
      _plaf(P_MRPElementCategory:'PA')._ProductionLineText.WorkCenterText      as ProductionLineText,
      
     _plaf(P_MRPElementCategory:'PA').SalesOrder                               as SalesOrder,

       _plaf(P_MRPElementCategory:'PA').SalesOrderItem                         as SalesOrderItem,

      _plaf(P_MRPElementCategory:'PA').Customer                                as Customer,

      _plaf(P_MRPElementCategory:'PA').BPCustomerName                          as CustomerName,

      cast( _plaf(P_MRPElementCategory:'PA').WBSElement as ps_s4_posid )       as WBSElement,
      
      cast( _plaf(P_MRPElementCategory:'PA').WBSElementInternalID as ps_s4_pspnr )  as WBSElementInternalID,                                                           

      marc.InHouseProductionTime,
      marc.TotalReplenishmentLeadTime,
      marc.MinimumLotSizeQuantity,
      marc.MaximumLotSizeQuantity,
      marc.LotSizeRoundingQuantity,
      marc.RoundingProfile,
      _RoundingProfile[1:Language = $session.system_language].MaterialRoundingProfileName,


      //PLAF Fields

      _plaf(P_MRPElementCategory:'PA').PlannedOrderOpeningDate,
      _plaf(P_MRPElementCategory:'PA').MaterialProcurementType,
      _plaf(P_MRPElementCategory:'PA').MaterialProcurementTypeName,

      //MFG Order Fields

      '' as      MfgOrderReleasedCode,
      cast('' as mfgorderscheduledreleasedate) as      MfgOrderScheduledReleaseDate,
      cast('' as mfgorderscheduledstartdate) as      MfgOrderScheduledStartDate,
      cast('' as mfgorderscheduledenddate) as      MfgOrderScheduledEndDate,
      cast( 0 as co_mimez) as      ExpectedDeviationQuantity,
      cast('' as orderimportancecode) as      ManufacturingOrderImportance,
      cast('' as manufacturingordercategory) as      ManufacturingOrderCategory,
      
      _Order
      
}
where
  (
       resb.RequirementType                =  'SB'
  )
  and  resb.ReservationItmIsMarkedForDeltn <> 'X'
union all 
select from I_ReservationItem       as resb
inner join   I_ProductSupplyPlanning as marc on  resb.Material = marc.Product
                                                 and resb.Plant    = marc.Plant
association [0..1] to I_ProductionOrderQuickView as _afpo            on  resb.ReferenceOrder = _afpo.OrderID
                                                                       and _afpo.ManufacturingOrderItem   = '0001'
 association [0..1] to I_Order                    as _Order           on  resb.ReferenceOrder = _Order.OrderID
  association [0..1] to I_RoundingPrfText          as _RoundingProfile on  $projection.RoundingProfile = _RoundingProfile.MaterialRoundingProfile
                                                                       and $projection.Plant           = _RoundingProfile.Plant
{
    //Common Fields

  key resb.Reservation,
  key resb.ReservationItem,
  key resb.RecordType,
      resb.RequirementType,
      resb.MatlCompRequirementDate                                             as RequirementDate,
      resb.Material,
      resb.Plant,
      resb.PlannedOrder,
      resb.ReferenceOrder                                                      as ManufacturingOrder,
      @Semantics.unitOfMeasure: true
      resb.BaseUnit,
      @Semantics.quantity.unitOfMeasure: 'BaseUnit'
      resb.ConfdQtyForATPInBaseUoM                                             as CommittedQuantity,
      @Semantics.quantity.unitOfMeasure: 'BaseUnit'
      resb.ResvnItmWithdrawnQtyInBaseUnit                                      as WithdrawnQuantity,
      @Semantics.quantity.unitOfMeasure: 'BaseUnit'
      resb.ResvnItmRequiredQtyInBaseUnit - resb.ResvnItmWithdrawnQtyInBaseUnit as MRPElementOpenQuantity,

      _afpo.Material                                                           as ParentComponent,

      _afpo.MRPPlant                                                           as ParentPlant,

      _afpo.MRPController                                                      as MRPController,

      _afpo.MRPControllerName                                                  as MRPControllerName,

      _afpo.InternalContactPersonName                                          as InternalContactPersonName,

      _afpo.InternalContactPhoneNumber                                         as InternalContactPhoneNumber,

      _afpo.InternalContactEmailAddress                                        as InternalContactEmailAddress,

      _afpo.ProductionSupervisor                                               as ProductionSupervisor,

      _afpo.ProductionSupervisorName                                           as ProductionSupervisorName,

      resb.ResvnItmRequiredQtyInBaseUnit                                       as OrderedQuantity,
      
      _afpo.ManufacturingOrderType                                             as OrderType,

      _afpo.ManufacturingOrderTypeName                                         as OrderTypeName,

      _afpo.MfgOrderPlannedStartDate                                           as BasicStartDate,

      _afpo.MfgOrderPlannedEndDate                                             as BasicEndDate,

      _afpo.MaterialGoodsReceiptDuration                                       as MaterialGoodsReceiptDuration,

      _afpo.MfgOrderPlannedTotalQty                                            as TotalQuantity,

      _afpo.MfgOrderPlannedScrapQty                                            as MRPElementPlannedScrapQuantity,

      _afpo.MfgOrderItemGoodsReceiptQty                                        as GoodsReceiptQty,

      _afpo.MRPElementOpenQuantity                                             as OpenQuantity,
      
      _afpo.ProductionPlant                                                    as ProductionPlant,

      _afpo.ProductionPlantName                                                as ProductionPlantName,

      _afpo.ProductionVersion                                                  as ProductionVersion,

      _afpo.ProductionVersionText                                              as ProductionVersionText,
      
      _afpo.ProductionLine                                                     as ProductionLine,
      
      _afpo._ProductionLineText.WorkCenterText                                 as ProductionLineText,
      
      _afpo.SalesOrder                                                         as SalesOrder,

      _afpo.SalesOrderItem                                                     as SalesOrderItem,

      ''                                                                       as Customer,

      ''                                                                       as CustomerName,

      cast( _afpo.WBSElement as ps_s4_posid )                                  as WBSElement,
      
      cast( _afpo.WBSElementInternalID as ps_s4_pspnr )                        as WBSElementInternalID,                                                           

      marc.InHouseProductionTime,
      marc.TotalReplenishmentLeadTime,
      marc.MinimumLotSizeQuantity,
      marc.MaximumLotSizeQuantity,
      marc.LotSizeRoundingQuantity,
      marc.RoundingProfile,
      _RoundingProfile[1:Language = $session.system_language].MaterialRoundingProfileName,


      //PLAF Fields

      cast('' as pertr) as PlannedOrderOpeningDate,
      cast('' as pph_sobes) as MaterialProcurementType,
      cast('' as materialprocurementtypename) as MaterialProcurementTypeName,

      //MFG Order Fields

      _afpo.MfgOrderReleasedCode,
      _afpo.MfgOrderScheduledReleaseDate,
      _afpo.MfgOrderScheduledStartDate,
      _afpo.MfgOrderScheduledEndDate,
      _afpo.ExpectedDeviationQuantity,
      _afpo.ManufacturingOrderImportance,
      _afpo.ManufacturingOrderCategory,

      _Order
}
where
  (
   resb.RequirementType                =  'AR'
  )
  and  resb.ReservationItmIsMarkedForDeltn <> 'X'