A_ProductionOrderComponent_3

DDL: A_PRODUCTIONORDERCOMPONENT_3 Type: view_entity COMPOSITE

Production Order Components Extended

A_ProductionOrderComponent_3 is a Composite CDS View that provides data about "Production Order Components Extended" in SAP S/4HANA. It reads from 1 data source (I_MfgOrderOperationComponent) and exposes 69 fields with key fields Reservation, ReservationItem, ReservationRecordType. It has 1 association to related views.

Data Sources (1)

SourceAliasJoin Type
I_MfgOrderOperationComponent I_MfgOrderOperationComponent from

Associations (1)

CardinalityTargetAliasCondition
[1..1] E_ReservationDocumentItem _Extension $projection.Reservation = _Extension.Reservation and $projection.ReservationItem = _Extension.ReservationItem and $projection.ReservationRecordType = _Extension.RecordType

Annotations (10)

NameValueLevelField
AccessControl.authorizationCheck #CHECK view
EndUserText.label Production Order Components Extended view
VDM.viewType #COMPOSITE view
AccessControl.personalData.blocking #NOT_REQUIRED view
Metadata.ignorePropagatedAnnotations true view
ObjectModel.updateEnabled true view
ObjectModel.usageType.serviceQuality #C view
ObjectModel.usageType.sizeCategory #XL view
ObjectModel.usageType.dataClass #TRANSACTIONAL view
VDM.lifecycle.contract.type #PUBLIC_REMOTE_API view

Fields (69)

KeyFieldSource TableSource FieldDescription
KEY Reservation Reservation
KEY ReservationItem ReservationItem
KEY ReservationRecordType RecordType
MaterialGroup MaterialGroup
Material Material
Plant Plant
ManufacturingOrderCategory ManufacturingOrderCategory
ManufacturingOrderType ManufacturingOrderType
ManufacturingOrder
ManufacturingOrderSequence ManufacturingOrderSequence
ManufacturingOrderOperation
ProductionPlant ProductionPlant
OrderInternalBillOfOperations OrderInternalBillOfOperations
MatlCompRequirementDate MatlCompRequirementDate
MatlCompRequirementTime MatlCompRequirementTime
MaterialIsDirectlyProduced MaterialIsDirectlyProduced
ReservationIsFinallyIssued ReservationIsFinallyIssued
MatlCompIsMarkedForDeletion
IsBulkMaterialComponent IsBulkMaterialComponent
MatlCompIsMarkedForBackflush MatlCompIsMarkedForBackflush
MaterialCompIsCostRelevant MaterialCompIsCostRelevant
RequirementType RequirementType
WBSElementInternalID WBSElementInternalID_2
OrderComponentLongText _LongText OrderComponentLongText
SalesOrder SalesOrder
SalesOrderItem SalesOrderItem
MatlCompFreeDefinedAttribute SortField
BillOfMaterialCategory BillOfMaterialCategory
BOMItem BOMItem
BOMItemCategory BOMItemCategory
BillOfMaterialItemNumber
BOMItemDescription BOMItemDescription BOM Item Text
StorageLocation StorageLocation
Batch Batch
GoodsMovementType GoodsMovementType
SupplyArea SupplyArea
GoodsRecipientName GoodsRecipientName
UnloadingPointName UnloadingPointName
InventorySpecialStockType InventorySpecialStockType
MaterialStaging MaterialStaging
VariableSizeDimension1 VariableSizeDimension1
VariableSizeDimension2 VariableSizeDimension2
VariableSizeDimension3 VariableSizeDimension3
VariableSizeDimensionUnit VariableSizeDimensionUnit
MaterialCompIsAlternativeItem MaterialCompIsAlternativeItem
AlternativeItemGroup AlternativeItemGroup
AlternativeItemStrategy AlternativeItemStrategy
AlternativeItemPriority AlternativeItemPriority
UsageProbabilityPercent UsageProbabilityPercent
MaterialComponentIsPhantomItem MaterialComponentIsPhantomItem
LeadTimeOffset LeadTimeOffset
QuantityIsFixed QuantityIsFixed
IsNetScrap IsNetScrap
ComponentScrapInPercent ComponentScrapInPercent
OperationScrapInPercent OperationScrapInPercent
BaseUnit BaseUnit
BaseUnitISOCode _BaseUnit UnitOfMeasureISOCode
BaseUnitSAPCode _BaseUnit UnitOfMeasureSAPCode
RequiredQuantity RequiredQuantity
WithdrawnQuantity WithdrawnQuantity
ConfirmedAvailableQuantity ConfirmedAvailableQuantity
MaterialCompOriginalQuantity MaterialCompOriginalQuantity
EntryUnit EntryUnit
EntryUnitISOCode _EntryUnit UnitOfMeasureISOCode
EntryUnitSAPCode _EntryUnit UnitOfMeasureSAPCode
GoodsMovementEntryQty GoodsMovementEntryQty
Currency Currency
WithdrawnQuantityAmount WithdrawnQuantityAmount
LastChangeTimeendasLastChangeDateTime
@AccessControl.authorizationCheck: #CHECK
@EndUserText.label: 'Production Order Components Extended'
@VDM.viewType: #COMPOSITE
@AccessControl.personalData.blocking: #NOT_REQUIRED
@Metadata.ignorePropagatedAnnotations: true
@ObjectModel.updateEnabled: true
@ObjectModel.usageType: {serviceQuality: #C, sizeCategory: #XL, dataClass: #TRANSACTIONAL}
@VDM.lifecycle.contract.type: #PUBLIC_REMOTE_API

define view entity A_ProductionOrderComponent_3
  as select from I_MfgOrderOperationComponent
  association [1..1] to E_ReservationDocumentItem as _Extension // Extensibility CE 2102

  on  $projection.Reservation           = _Extension.Reservation
  and $projection.ReservationItem       = _Extension.ReservationItem
  and $projection.ReservationRecordType = _Extension.RecordType

{
      // Key

      @ObjectModel.sapObjectNodeTypeReference: 'ReservationDocument'
  key Reservation,
  key ReservationItem,
  key RecordType                                                                                     as ReservationRecordType,

      // Material data

      MaterialGroup,
      Material,
      Plant,

      // Order and Operation data

      @ObjectModel.sapObjectNodeTypeReference: 'ManufacturingOrderCategory'
      ManufacturingOrderCategory,
      @ObjectModel.sapObjectNodeTypeReference: 'ManufacturingOrderType'
      ManufacturingOrderType,
      @ObjectModel.sapObjectNodeTypeReference: 'ProductionOrder'
      cast(ManufacturingOrder                             as vdm_manufacturingorder preserving type) as ManufacturingOrder,
      ManufacturingOrderSequence,
      cast( ManufacturingOrderOperation as vdm_vornr preserving type )                               as ManufacturingOrderOperation,
      ProductionPlant,
      OrderInternalBillOfOperations,

      // Date and Time

      MatlCompRequirementDate,
      MatlCompRequirementTime,
      MaterialIsDirectlyProduced,                                                                                                    // New field in OP2023.FPS03


      // Attributes

      ReservationIsFinallyIssued,
      cast( MatlCompIsMarkedForDeletion as /plmb/lkenz preserving type )                             as MatlCompIsMarkedForDeletion, // CE2208

      IsBulkMaterialComponent,
      MatlCompIsMarkedForBackflush,
      MaterialCompIsCostRelevant,
      RequirementType,                                                                                                               // New field in OP2023.FPS03

      WBSElementInternalID_2                                                                         as WBSElementInternalID,        // New field in OP2023.FPS03


      // Text

      @Semantics.text:true
      _LongText.OrderComponentLongText, // CE2008


      // Assignments

      @ObjectModel.sapObjectNodeTypeReference: 'SalesOrder'
      SalesOrder,
      SalesOrderItem,
      SortField                                                                                      as MatlCompFreeDefinedAttribute, // Solves ATC error with different length for GFN SortField


      // Assignments BOM

      BillOfMaterialCategory,

      BOMItem,
      BOMItemCategory,
      cast ( BillOfMaterialItemNumber as vdm_sposn preserving type )                                 as BillOfMaterialItemNumber,
      @EndUserText.label: 'BOM Item Text'
      @Semantics.text: true
      BOMItemDescription,

      // Goods Movement data

      @ObjectModel.sapObjectNodeTypeReference: 'StorageLocation'
      StorageLocation,
      Batch,
      case when BatchSplitType = ' '                      // LCOMKF4R

            and MaterialComponentIsPhantomItem = ' '      // resb-dumps

            and MatlCompIsTextItem             = ' '      // resb-txtps

            and MaterialIsDirectlyProcured     <> 'X'     // resb-dbskz NE 'F'

           then _ProductPlant2.IsInternalBatchManaged     // resb-xchar

           else BatchSplitType end                                                                   as BatchSplitType,
      @ObjectModel.sapObjectNodeTypeReference: 'GoodsMovementType'
      GoodsMovementType,
      SupplyArea,
      @Semantics.text: true
      GoodsRecipientName,
      @Semantics.text: true
      UnloadingPointName,
      InventorySpecialStockType,                                                                                                     // New field in OP2023.FPS03


      // Assignments WM

      MaterialStaging,                                                                                                               // New field in OP2023.FPS03


      // Variable-size comp. data

      @Semantics.quantity.unitOfMeasure: 'VariableSizeDimensionUnit'
      VariableSizeDimension1,                                                                                                        // New field in OP2023.FPS03

      @Semantics.quantity.unitOfMeasure: 'VariableSizeDimensionUnit'
      VariableSizeDimension2,                                                                                                        // New field in OP2023.FPS03

      @Semantics.quantity.unitOfMeasure: 'VariableSizeDimensionUnit'
      VariableSizeDimension3,                                                                                                        // New field in OP2023.FPS03

      VariableSizeDimensionUnit,                                                                                                     // New field in OP2023.FPS03


      // Alternative item data - added with CE2011

      MaterialCompIsAlternativeItem,
      AlternativeItemGroup,
      AlternativeItemStrategy,
      AlternativeItemPriority,
      UsageProbabilityPercent,

      // Phantom assembly

      MaterialComponentIsPhantomItem,

      // Lead-Time offset

      LeadTimeOffset,

      // Quantities and UoM

      QuantityIsFixed,
      IsNetScrap,
      ComponentScrapInPercent,
      OperationScrapInPercent,
      BaseUnit,
      _BaseUnit.UnitOfMeasureISOCode                                                                 as BaseUnitISOCode, // CE2105

      _BaseUnit.UnitOfMeasureSAPCode                                                                 as BaseUnitSAPCode, // CE2105

      @Semantics.quantity.unitOfMeasure: 'BaseUnit'
      RequiredQuantity,
      @Semantics.quantity.unitOfMeasure: 'BaseUnit'
      WithdrawnQuantity,
      @Semantics.quantity.unitOfMeasure: 'BaseUnit'
      ConfirmedAvailableQuantity,
      @Semantics.quantity.unitOfMeasure: 'BaseUnit'
      MaterialCompOriginalQuantity,
      EntryUnit,
      _EntryUnit.UnitOfMeasureISOCode                                                                as EntryUnitISOCode,
      _EntryUnit.UnitOfMeasureSAPCode                                                                as EntryUnitSAPCode,
      @Semantics.quantity.unitOfMeasure: 'EntryUnit'
      GoodsMovementEntryQty,

      // Amount and Currency

      @ObjectModel.sapObjectNodeTypeReference: 'Currency'
      Currency,
      @Semantics.amount.currencyCode: 'Currency'
      WithdrawnQuantityAmount,

      // eTag for Update CE2201

      @Semantics.durationInSeconds: true
      @Semantics.dateTime: false
      case I_MfgOrderOperationComponent._MfgOrder.LastChangeDate
        when '00000000' then  // not changed yet, use create

          concat(I_MfgOrderOperationComponent._MfgOrder.MfgOrderCreationDate,
                 I_MfgOrderOperationComponent._MfgOrder.MfgOrderCreationTime)
        else
          concat(I_MfgOrderOperationComponent._MfgOrder.LastChangeDate,
                 I_MfgOrderOperationComponent._MfgOrder.LastChangeTime)
        end                                                                                          as LastChangeDateTime

}
where
  ManufacturingOrderCategory = '10';