I_RecipeFormulaItem

DDL: I_RECIPEFORMULAITEM SQL: IRCPFRMITM Type: view BASIC Package: VDM_PLMB_RFO

Recipe Formula Item

I_RecipeFormulaItem is a Basic CDS View that provides data about "Recipe Formula Item" in SAP S/4HANA. It reads from 1 data source (/plmb/rfo_frmitm) and exposes 30 fields with key field RcpFmlaItemUUID. It has 5 associations to related views. Part of development package VDM_PLMB_RFO.

Data Sources (1)

SourceAliasJoin Type
/plmb/rfo_frmitm /plmb/rfo_frmitm from

Associations (5)

CardinalityTargetAliasCondition
[0..1] I_SpecComponentType _ComponentType $projection.RcpFmlaItemComponentType = _ComponentType.SpecificationComponentType
[1..1] I_RecipeProcessElementAssgmt _RecipeProcessElementAssgmt $projection.RcpFmlaItemSourceFmlaItemUUID = _RecipeProcessElementAssgmt.RcpFmlaItemSourceFmlaItemUUID and $projection.recipeuuid = _RecipeProcessElementAssgmt.RecipeUUID
[1..1] I_Recipe _Recipe $projection.RcpFmlaUUID = _Recipe.RcpFmlaUUID
[1..1] I_Product _Product $projection.Material = _Product.Product
[1..*] I_RecipeStreamQuantity _RecipeStreamQuantity $projection.RcpFmlaItemUUID = _RecipeStreamQuantity.RcpFmlaItemUUID

Annotations (10)

NameValueLevelField
AbapCatalog.sqlViewName IRCPFRMITM view
AbapCatalog.compiler.compareFilter true view
AccessControl.authorizationCheck #PRIVILEGED_ONLY view
ClientHandling.algorithm #SESSION_VARIABLE view
ObjectModel.usageType.sizeCategory #L view
ObjectModel.usageType.serviceQuality #A view
ObjectModel.usageType.dataClass #MASTER view
VDM.lifecycle.contract.type #SAP_INTERNAL_API view
VDM.viewType #BASIC view
EndUserText.label Recipe Formula Item view

Fields (30)

KeyFieldSource TableSource FieldDescription
KEY RcpFmlaItemUUID rfo_item_guid
RcpFmlaUUID rfo_guid
RcpFmlaItemSourceFmlaItemUUID item_guid
RcpFmlaItemPosition
RcpFmlaItemAlternativeItemPos
RcpFmlaItemType item_type
SpecificationInternalID subrecn
Material material
RcpFmlaStreamUUID stream_id
RcpFmlaItemComponentType comp_type
RcpFmlaItemLowerLimit quant_low
RcpFmlaItemUpperLimit quant_high
RcpFmlaItemQuantity quant
RcpFmlaItemUnit uom
RcpFmlaItemExceptionCode exception_value
RcpFmlaItemScrapInPercent scrap
RcpFmlaItemOverrunInPercent overrun
RcpFmlaItemAlternativeItemUUID alt_item_guid
RcpFmlaItemQuantityInKilogram massabsfloat
RcpFmlaItemZeroSign zero_sign
RcpFmlaItemIsSelectedForCalc calculated
RcpFmlaItemExplosionRecipeUUID expl_rcp_guid
RcpFmlaCalculationType calc_type
RcpFmlaItemIsBalancingItem is_balancing_item
RecipeUUID _Recipe RecipeUUID
_Recipe _Recipe
_ComponentType _ComponentType
_RecipeProcessElementAssgmt _RecipeProcessElementAssgmt
_Product _Product
_RecipeStreamQuantity _RecipeStreamQuantity
@AbapCatalog.sqlViewName: 'IRCPFRMITM'
@AbapCatalog.compiler.compareFilter: true

@AccessControl.authorizationCheck: #PRIVILEGED_ONLY
/* Authorization cannot be handled in a date-independent manner, for consuming
   formula item data, I_RecipeFormulaItemForKeyDate should be used instead.

   To access a formula item the following authorizations should match:
    - Recipe header (PLM_RCPCVS) -> date-independent
    - Recipe header's PO Specification (C_SHES_TR2) -> date-dependent -> cannot be expressed in this view
    - Specification (C_SHES_TR2) -> date-dependent -> cannot be expressed in this view
*/
@ClientHandling.algorithm: #SESSION_VARIABLE

@ObjectModel.usageType.sizeCategory: #L
@ObjectModel.usageType.serviceQuality: #A
@ObjectModel.usageType.dataClass: #MASTER

@VDM.lifecycle.contract.type: #SAP_INTERNAL_API
@VDM.viewType: #BASIC

@EndUserText.label: 'Recipe Formula Item'
define view I_RecipeFormulaItem
  as select from /plmb/rfo_frmitm
  association [0..1] to I_SpecComponentType          as _ComponentType              on  $projection.RcpFmlaItemComponentType = _ComponentType.SpecificationComponentType
  association [1..1] to I_RecipeProcessElementAssgmt as _RecipeProcessElementAssgmt on  $projection.RcpFmlaItemSourceFmlaItemUUID = _RecipeProcessElementAssgmt.RcpFmlaItemSourceFmlaItemUUID
                                                                                    and $projection.recipeuuid                    = _RecipeProcessElementAssgmt.RecipeUUID
  association [1..1] to I_Recipe                     as _Recipe                     on  $projection.RcpFmlaUUID = _Recipe.RcpFmlaUUID
  association [1..1] to I_Product                    as _Product                    on  $projection.Material = _Product.Product
  association [1..*] to I_RecipeStreamQuantity       as _RecipeStreamQuantity       on  $projection.RcpFmlaItemUUID = _RecipeStreamQuantity.RcpFmlaItemUUID


{

  key rfo_item_guid                                                   as RcpFmlaItemUUID,
      rfo_guid                                                        as RcpFmlaUUID,
      item_guid                                                       as RcpFmlaItemSourceFmlaItemUUID, // reference to the original fmlaitem when copied


      cast( posnr as /plmb/rfo_frml_posnr_vdm preserving type )       as RcpFmlaItemPosition,
      cast( poscount as /plmb/rfo_frml_poscount_vdm preserving type ) as RcpFmlaItemAlternativeItemPos,
      item_type                                                       as RcpFmlaItemType,
      subrecn                                                         as SpecificationInternalID,
      material                                                        as Material,
      stream_id                                                       as RcpFmlaStreamUUID,
      comp_type                                                       as RcpFmlaItemComponentType,

      quant_low                                                       as RcpFmlaItemLowerLimit,
      quant_high                                                      as RcpFmlaItemUpperLimit,
      quant                                                           as RcpFmlaItemQuantity,
      uom                                                             as RcpFmlaItemUnit,
      exception_value                                                 as RcpFmlaItemExceptionCode,
      scrap                                                           as RcpFmlaItemScrapInPercent,
      overrun                                                         as RcpFmlaItemOverrunInPercent,

      alt_item_guid                                                   as RcpFmlaItemAlternativeItemUUID,

      massabsfloat                                                    as RcpFmlaItemQuantityInKilogram,
      zero_sign                                                       as RcpFmlaItemZeroSign,
      calculated                                                      as RcpFmlaItemIsSelectedForCalc,
      expl_rcp_guid                                                   as RcpFmlaItemExplosionRecipeUUID,
      calc_type                                                       as RcpFmlaCalculationType,
      is_balancing_item                                               as RcpFmlaItemIsBalancingItem,

      cast( case when alt_item_guid = hextobin('00000000000000000000000000000000')
        then 'X'
        else ''
      end as /plmb/rfo_use_for_calc preserving type )                 as RecipeFmlaItemAltvIsUsed,

      _Recipe.RecipeUUID,

      _Recipe,
      _ComponentType,
      _RecipeProcessElementAssgmt,
      _Product,
      _RecipeStreamQuantity
}