I_BillOfMaterialComponent

DDL: I_BILLOFMATERIALCOMPONENT SQL: IBOMCOMPS Type: view COMPOSITE

Bill of Material Components

I_BillOfMaterialComponent is a Composite CDS View that provides data about "Bill of Material Components" in SAP S/4HANA. It reads from 1 data source (P_BOMItems) and exposes 114 fields with key fields BillOfMaterialCategory, BillOfMaterial, BillOfMaterialVariant, BillOfMaterialItemNodeNumber, BillOfMaterialItemUUID. It has 17 associations to related views.

Data Sources (1)

SourceAliasJoin Type
P_BOMItems valid_items from

Associations (17)

CardinalityTargetAliasCondition
[1..1] I_BillOfMaterialItemCategory _BOMItemCategory $projection.BillOfMaterialItemCategory = _BOMItemCategory.BillOfMaterialItemCategory
[0..1] I_BomItemCategoryText _BOMItemCategoryText $projection.BillOfMaterialItemCategory = _BOMItemCategoryText.BillOfMaterialItemCategory and _BOMItemCategoryText.Language = $session.system_language
[1..1] I_UnitOfMeasure _UnitOfMeasure $projection.BillOfMaterialItemUnit = _UnitOfMeasure.UnitOfMeasure
[1..1] I_Currency _Currency $projection.Currency = _Currency.Currency
[0..*] I_MaterialBOMLink _Mast $projection.BillOfMaterialCategory = _Mast.BillOfMaterialCategory and $projection.BillOfMaterial = _Mast.BillOfMaterial and $projection.BillOfMaterialVariant = _Mast.BillOfMaterialVariant
[0..1] I_DocumentBOMLink _Dost $projection.BillOfMaterialCategory = _Dost.BillOfMaterialCategory and $projection.BillOfMaterial = _Dost.BillOfMaterial and $projection.BillOfMaterialVariant = _Dost.BillOfMaterialVariant
[0..1] I_Prst _Prst $projection.BillOfMaterialCategory = _Prst.BillOfMaterialCategory and $projection.BillOfMaterial = _Prst.BillOfMaterial and $projection.BillOfMaterialVariant = _Prst.BillOfMaterialVariant
[0..1] I_SalesOrderBOMLink _Kdst $projection.BillOfMaterialCategory = _Kdst.BillOfMaterialCategory and $projection.BillOfMaterial = _Kdst.BillOfMaterial and $projection.BillOfMaterialVariant = _Kdst.BillOfMaterialVariant
[0..1] I_Eqst _Eqst $projection.BillOfMaterialCategory = _Eqst.BillOfMaterialCategory and $projection.BillOfMaterial = _Eqst.BillOfMaterial and $projection.BillOfMaterialVariant = _Eqst.BillOfMaterialVariant
[0..1] I_Tpst _Tpst $projection.BillOfMaterialCategory = _Tpst.BillOfMaterialCategory and $projection.BillOfMaterial = _Tpst.BillOfMaterial and $projection.BillOfMaterialVariant = _Tpst.BillOfMaterialVariant
[0..1] I_Stst _Stst $projection.BillOfMaterialCategory = _Stst.BillOfMaterialCategory and $projection.BillOfMaterial = _Stst.BillOfMaterial and $projection.BillOfMaterialVariant = _Stst.BillOfMaterialVariant
[0..1] I_Material _Material $projection.BillOfMaterialComponent = _Material.Material
[0..1] I_MaterialText _MaterialText $projection.BillOfMaterialComponent = _MaterialText.Material and _MaterialText.Language = $session.system_language
[0..1] I_MaterialText _MaterialTextEN $projection.BillOfMaterialComponent = _MaterialTextEN.Material and _MaterialTextEN.Language = 'E'
[0..1] I_DocumentInfoRecordDesc _DocumentText $projection.DocumentType = _DocumentText.DocumentInfoRecordDocType and $projection.DocNumber = _DocumentText.DocumentInfoRecordDocNumber and $projection.DocumentPart = _DocumentText.DocumentInfoRecordDocPart and $projection.DocumentVersion = _DocumentText.DocumentInfoRecordDocVersion and _DocumentText.Language = $session.system_language
[0..1] I_DocumentInfoRecordDesc _DocumentTextEN $projection.DocumentType = _DocumentTextEN.DocumentInfoRecordDocType and $projection.DocNumber = _DocumentTextEN.DocumentInfoRecordDocNumber and $projection.DocumentPart = _DocumentTextEN.DocumentInfoRecordDocPart and $projection.DocumentVersion = _DocumentTextEN.DocumentInfoRecordDocVersion and _DocumentTextEN.Language = 'E'
[0..1] I_ClfnClassVH _Class $projection.ClassNumber = _Class.Class and $projection.ClassType = _Class.ClassType

Annotations (14)

NameValueLevelField
AbapCatalog.sqlViewName IBOMCOMPS view
ClientHandling.type #INHERITED view
ClientHandling.algorithm #SESSION_VARIABLE view
VDM.viewType #COMPOSITE view
ObjectModel.usageType.serviceQuality #D view
ObjectModel.usageType.sizeCategory #L view
ObjectModel.usageType.dataClass #TRANSACTIONAL view
AbapCatalog.compiler.compareFilter true view
AccessControl.authorizationCheck #CHECK view
AccessControl.personalData.blocking #NOT_REQUIRED view
EndUserText.label Bill of Material Components view
ObjectModel.createEnabled true view
Search.searchable false view
AbapCatalog.preserveKey true view

Fields (114)

KeyFieldSource TableSource FieldDescription
KEY BillOfMaterialCategory P_BOMItems BillOfMaterialCategory
KEY BillOfMaterial P_BOMItems BillOfMaterial
KEY BillOfMaterialVariant P_BOMItems BillOfMaterialVariant
KEY BillOfMaterialItemNodeNumber P_BOMItems BillOfMaterialItemNodeNumber
KEY BillOfMaterialItemUUID P_BOMItems BillOfMaterialItemUUID
BillOfMaterialVersion P_BOMItems BillOfMaterialVersion
BOMItemInternalChangeCount
ValidityStartDate P_BOMItems ValidityStartDate
ValidityEndDate P_BOMItems ValidityEndDate
EngineeringChangeDocument P_BOMItems ChangeNumberFrom
ChgToEngineeringChgDocument
InheritedNodeNumberForBOMItem P_BOMItems InheritedNodeNumberForBOMItem
InheritedNodeNumberVersionBOM P_BOMItems InheritedNodeNumberVersionBOM
BOMItemRecordCreationDate
BOMItemCreatedByUser P_BOMItems BOMItemCreatedByUser
BOMItemLastChangeDate P_BOMItems BOMItemLastChangeDate
BOMItemLastChangedByUser P_BOMItems BOMItemLastChangedByUser
BillOfMaterialComponent P_BOMItems BillOfMaterialComponent
MaterialName
BillOfMaterialItemCategory P_BOMItems BillOfMaterialItemCategory
BillOfMaterialItemNumber P_BOMItems BillOfMaterialItemNumber
IsAssembly
IsSubItem P_BOMItems IsSubItem
BOMItemSorter P_BOMItems BOMItemSorter
FixedQuantity P_BOMItems FixedQuantity
BOMItemHasFixedQuantity P_BOMItems BOMItemHasFixedQuantity
PurchasingGroup P_BOMItems PurchasingGroup
Currency P_BOMItems Currency
MaterialComponentPrice P_BOMItems MaterialComponentPrice
IdentifierBOMItem P_BOMItems IdentifierBOMItem
MaterialPriceUnitQty P_BOMItems MaterialPriceUnitQty
ComponentScrapInPercent P_BOMItems ComponentScrapInPercent
OperationScrapInPercent P_BOMItems OperationScrapInPercent
IsNetScrap P_BOMItems IsNetScrap
NumberOfVariableSizeItem P_BOMItems NumberOfVariableSizeItem
QuantityVariableSizeItem P_BOMItems QuantityVariableSizeItem
UnitOfMeasureForVarSizeItem P_BOMItems UnitOfMeasureForVarSizeItem
FormulaKey P_BOMItems FormulaKey
BOMItemDescription P_BOMItems BOMItemDescription
BOMItemText2 P_BOMItems BOMItemText2
LongTextLanguage P_BOMItems LongTextLanguage
MaterialGroup P_BOMItems MaterialGroup
DocumentType P_BOMItems DocumentType
DocNumber P_BOMItems DocNumber
DocumentVersion P_BOMItems DocumentVersion
DocumentPart P_BOMItems DocumentPart
ClassNumber P_BOMItems ClassNumber
ClassType P_BOMItems ClassType
ResultingItemCategory P_BOMItems ResultingItemCategory
DependencyObjectNumber P_BOMItems DependencyObjectNumber
ObjectType P_BOMItems ObjectType
IsClassificationRelevant P_BOMItems IsClassificationRelevant
IsBulkMaterial P_BOMItems IsBulkMaterial
BOMItemIsSparePart P_BOMItems BOMItemIsSparePart
BOMItemIsSalesRelevant P_BOMItems BOMItemIsSalesRelevant
IsProductionRelevant P_BOMItems IsProductionRelevant
BOMItemIsPlantMaintRelevant P_BOMItems BOMItemIsPlantMaintRelevant
BOMItemIsCostingRelevant P_BOMItems BOMItemIsCostingRelevant
IsEngineeringRelevant P_BOMItems IsEngineeringRelevant
SpecialProcurementType P_BOMItems SpecialProcurementType
IsBOMRecursiveAllowed P_BOMItems IsBOMRecursiveAllowed
OperationLeadTimeOffset P_BOMItems OperationLeadTimeOffset
OpsLeadTimeOffsetUnit P_BOMItems OpsLeadTimeOffsetUnit
IsMaterialProvision P_BOMItems IsMaterialProvision
BOMIsRecursive P_BOMItems BOMIsRecursive
DocumentIsCreatedByCAD P_BOMItems DocumentIsCreatedByCAD
DistrKeyCompConsumption P_BOMItems DistrKeyCompConsumption
DeliveryDurationInDays P_BOMItems DeliveryDurationInDays
Creditor P_BOMItems Creditor
CostElement P_BOMItems CostElement
Size1 P_BOMItems Size1
Size2 P_BOMItems Size2
Size3 P_BOMItems Size3
UnitOfMeasureForSize1To3 P_BOMItems UnitOfMeasureForSize1To3
GoodsReceiptDuration P_BOMItems GoodsReceiptDuration
PurchasingOrganization P_BOMItems PurchasingOrganization
RequiredComponent P_BOMItems RequiredComponent
MultipleSelectionAllowed P_BOMItems MultipleSelectionAllowed
ProdOrderIssueLocation P_BOMItems ProdOrderIssueLocation
MaterialIsCoProduct P_BOMItems MaterialIsCoProduct
ExplosionType P_BOMItems ExplosionType
FollowUpGroup P_BOMItems FollowUpGroup
DiscontinuationGroup P_BOMItems DiscontinuationGroup
IsConfigurableBOM P_BOMItems IsConfigurableBOM
ReferencePoint P_BOMItems ReferencePoint
LeadTimeOffset P_BOMItems LeadTimeOffset
IsSoftwareComponent P_BOMItems IsSoftwareComponent
ProductionSupplyArea P_BOMItems ProductionSupplyArea
IsDeleted P_BOMItems IsDeleted
IsALE P_BOMItems IsALE
AlternativeItemGroup P_BOMItems AlternativeItemGroup
AlternativeItemPriority P_BOMItems AlternativeItemPriority
AlternativeItemStrategy P_BOMItems AlternativeItemStrategy
UsageProbabilityPercent P_BOMItems UsageProbabilityPercent
BillOfMaterialItemCategoryDesc _BOMItemCategoryText BillOfMaterialItemCategoryDesc
MaterialComponentIsPhantomItem
IsPhantomItem
LastChangeDateTime P_BOMItems LastChangeDateTime
IsPMAssemblyRelevant P_BOMItems IsPMAssemblyRelevant
OrigSalesOrderBOMItmCategory P_BOMItems OrigSalesOrderBOMItmCategory
OrigSalesOrderBOM P_BOMItems OrigSalesOrderBOM
OrigSalesOrderBOMItmNodeNumber P_BOMItems OrigSalesOrderBOMItmNodeNumber
OrigSalesOrderBOMItmNumber P_BOMItems OrigSalesOrderBOMItmNumber
PreliminaryMaterial P_BOMItems PreliminaryMaterial
_BOMItemCategory _BOMItemCategory
_UnitOfMeasure _UnitOfMeasure
_Currency _Currency
_Mast _Mast
_Dost _Dost
_Prst _Prst
_Kdst _Kdst
_Eqst _Eqst
_Tpst _Tpst
_Stst _Stst
@AbapCatalog.sqlViewName: 'IBOMCOMPS'
@ClientHandling.type : #INHERITED
@ClientHandling.algorithm : #SESSION_VARIABLE
@VDM.viewType: #COMPOSITE
@ObjectModel.usageType: {serviceQuality: #D, sizeCategory: #L, dataClass: #TRANSACTIONAL}
@AbapCatalog.compiler.compareFilter: true
@AccessControl.authorizationCheck: #CHECK
@AccessControl.personalData.blocking: #NOT_REQUIRED
@EndUserText.label: 'Bill of Material Components'
@ObjectModel.createEnabled: true
@Search.searchable: false
@AbapCatalog.preserveKey:true

define view I_BillOfMaterialComponent
  as select from P_BOMItems as valid_items
  association [1..1] to I_BillOfMaterialItemCategory as _BOMItemCategory on  $projection.BillOfMaterialItemCategory = _BOMItemCategory.BillOfMaterialItemCategory
  association [0..1] to I_BomItemCategoryText as _BOMItemCategoryText                on  $projection.BillOfMaterialItemCategory = _BOMItemCategoryText.BillOfMaterialItemCategory
                                                                                     and _BOMItemCategoryText.Language = $session.system_language
  //association [0..1] to I_Material                   as _Material        on  $projection.BillOfMaterialComponent = _Material.Material

  association [1..1] to I_UnitOfMeasure              as _UnitOfMeasure   on  $projection.BillOfMaterialItemUnit = _UnitOfMeasure.UnitOfMeasure
  //association [1..1] to I_BillOfMaterialUsage        as _BillOfMaterialVariantUsage on  $projection.billofmaterialvariantusage = _BillOfMaterialVariantUsage.BillOfMaterialVariantUsage

  association [1..1] to I_Currency                   as _Currency        on  $projection.Currency = _Currency.Currency
  association [0..*] to I_MaterialBOMLink            as _Mast            on  $projection.BillOfMaterialCategory = _Mast.BillOfMaterialCategory
                                                                         and $projection.BillOfMaterial         = _Mast.BillOfMaterial
                                                                         and $projection.BillOfMaterialVariant  = _Mast.BillOfMaterialVariant
  association [0..1] to I_DocumentBOMLink            as _Dost            on  $projection.BillOfMaterialCategory = _Dost.BillOfMaterialCategory
                                                                         and $projection.BillOfMaterial         = _Dost.BillOfMaterial
                                                                         and $projection.BillOfMaterialVariant  = _Dost.BillOfMaterialVariant
  association [0..1] to I_Prst                       as _Prst            on  $projection.BillOfMaterialCategory = _Prst.BillOfMaterialCategory
                                                                         and $projection.BillOfMaterial         = _Prst.BillOfMaterial
                                                                         and $projection.BillOfMaterialVariant  = _Prst.BillOfMaterialVariant
  association [0..1] to I_SalesOrderBOMLink          as _Kdst            on  $projection.BillOfMaterialCategory = _Kdst.BillOfMaterialCategory
                                                                         and $projection.BillOfMaterial         = _Kdst.BillOfMaterial
                                                                         and $projection.BillOfMaterialVariant  = _Kdst.BillOfMaterialVariant
  association [0..1] to I_Eqst                       as _Eqst            on  $projection.BillOfMaterialCategory = _Eqst.BillOfMaterialCategory
                                                                         and $projection.BillOfMaterial         = _Eqst.BillOfMaterial
                                                                         and $projection.BillOfMaterialVariant  = _Eqst.BillOfMaterialVariant
  association [0..1] to I_Tpst                       as _Tpst            on  $projection.BillOfMaterialCategory = _Tpst.BillOfMaterialCategory
                                                                         and $projection.BillOfMaterial         = _Tpst.BillOfMaterial
                                                                         and $projection.BillOfMaterialVariant  = _Tpst.BillOfMaterialVariant
  association [0..1] to I_Stst                       as _Stst            on  $projection.BillOfMaterialCategory = _Stst.BillOfMaterialCategory
                                                                         and $projection.BillOfMaterial         = _Stst.BillOfMaterial
                                                                         and $projection.BillOfMaterialVariant  = _Stst.BillOfMaterialVariant
  association [0..1] to I_Material                    as _Material       on  $projection.BillOfMaterialComponent = _Material.Material
  association [0..1] to I_MaterialText                as _MaterialText   on  $projection.BillOfMaterialComponent = _MaterialText.Material
                                                                                      and _MaterialText.Language              = $session.system_language
  association [0..1] to I_MaterialText                as _MaterialTextEN              on  $projection.BillOfMaterialComponent = _MaterialTextEN.Material
                                                                                      and _MaterialTextEN.Language            = 'E'

   association [0..1] to I_DocumentInfoRecordDesc      as _DocumentText                on  $projection.DocumentType    = _DocumentText.DocumentInfoRecordDocType
                                                                                      and $projection.DocNumber       = _DocumentText.DocumentInfoRecordDocNumber
                                                                                      and $projection.DocumentPart    = _DocumentText.DocumentInfoRecordDocPart
                                                                                      and $projection.DocumentVersion = _DocumentText.DocumentInfoRecordDocVersion
                                                                                      and _DocumentText.Language      = $session.system_language

  association [0..1] to I_DocumentInfoRecordDesc      as _DocumentTextEN              on  $projection.DocumentType    = _DocumentTextEN.DocumentInfoRecordDocType
                                                                                      and $projection.DocNumber       = _DocumentTextEN.DocumentInfoRecordDocNumber
                                                                                      and $projection.DocumentPart    = _DocumentTextEN.DocumentInfoRecordDocPart
                                                                                      and $projection.DocumentVersion = _DocumentTextEN.DocumentInfoRecordDocVersion
                                                                                      and _DocumentTextEN.Language    = 'E'
  association [0..1] to I_ClfnClassVH                 as _Class                       on  $projection.ClassNumber = _Class.Class
                                                                                      and $projection.ClassType   = _Class.ClassType                                                                                
                                                                                                                                                                    
                                                                                                                                                            
{
  key valid_items.BillOfMaterialCategory,
      //@ObjectModel.readOnly: true

  key valid_items.BillOfMaterial,
      //@ObjectModel.readOnly: true

  key valid_items.BillOfMaterialVariant,
      //@ObjectModel.readOnly: true

  key valid_items.BillOfMaterialItemNodeNumber,
      //@ObjectModel.readOnly: true

  key valid_items.BillOfMaterialItemUUID,
  
      valid_items.BillOfMaterialVersion,
      //@ObjectModel.readOnly: true

      --@EndUserText.label: ''
      valid_items.BOMItemInternalChangeCount,
      //@ObjectModel.readOnly: true

      @Semantics.businessDate.from: true
      valid_items.ValidityStartDate,     
      //@ObjectModel.readOnly: true

      @Semantics.businessDate.to: true
 /*     case when valid_items.BillOfMaterialVersion = ''  or valid_items.ValidityStartDate = '00000000' 
      then
      cast( valid_items.ValidityEndDate as datub preserving type )
      else cast('99991231' as datub )
      end as ValidityEndDate, */      
      valid_items.ValidityEndDate, 
      //@ObjectModel.readOnly: true

      valid_items.ChangeNumberFrom                                 as EngineeringChangeDocument,
      //@ObjectModel.readOnly: true

      cast( valid_items.ChangeNumberTo as aenra preserving type )  as ChgToEngineeringChgDocument,
      //@ObjectModel.readOnly: true

      valid_items.InheritedNodeNumberForBOMItem,
      @ObjectModel.readOnly: true
      valid_items.InheritedNodeNumberVersionBOM,
      --@ObjectModel.readOnly: true
      //valid_items.BOMItemNodeCount,

     // @ObjectModel.readOnly: true

      valid_items.BOMItemRecordCreationDate,
      //@ObjectModel.readOnly: true

      valid_items.BOMItemCreatedByUser,
      valid_items.BOMItemLastChangeDate,
      valid_items.BOMItemLastChangedByUser,
      @Search: {defaultSearchElement: true, ranking: #HIGH, fuzzinessThreshold: 0.8}
      valid_items.BillOfMaterialComponent,
      ' '                                                          as MaterialName, // To be removed

      @ObjectModel.foreignKey.association: '_BOMItemCategory'
      valid_items.BillOfMaterialItemCategory,
      valid_items.BillOfMaterialItemNumber,
      @Semantics.unitOfMeasure: true
      @ObjectModel.foreignKey.association: '_UnitOfMeasure'
      case when _BOMItemCategory.FixedItemCategory = 'R'
      then UnitOfMeasureForVarSizeItem
      else valid_items.BillOfMaterialItemUnit
      end                                                          as BillOfMaterialItemUnit,
      @Semantics.quantity.unitOfMeasure: 'BillOfMaterialItemUnit'
      @DefaultAggregation :#NONE
      case when _BOMItemCategory.FixedItemCategory = 'R'
      then NumberOfVariableSizeItem
      else valid_items.BillOfMaterialItemQuantity
      end                                                          as BillOfMaterialItemQuantity,
      cast( valid_items.IsAssembly as stlkz preserving type )      as IsAssembly,
      //'' as AssemblyIndicator,

      valid_items.IsSubItem,

      valid_items.BOMItemSorter,
      valid_items.FixedQuantity,
      valid_items.BOMItemHasFixedQuantity,
      valid_items.PurchasingGroup,
      @Semantics.currencyCode: true
      @ObjectModel.foreignKey.association: '_Currency'
      valid_items.Currency,
      @Semantics.amount.currencyCode : 'Currency'
      @DefaultAggregation :#NONE
      valid_items.MaterialComponentPrice,
      valid_items.IdentifierBOMItem,
      valid_items.MaterialPriceUnitQty,
      valid_items.ComponentScrapInPercent,
      valid_items.OperationScrapInPercent,
      valid_items.IsNetScrap,
      valid_items.NumberOfVariableSizeItem,
       case when _BOMItemCategory.FixedItemCategory = 'R'
      then BillOfMaterialItemUnit
      else valid_items.UnitOfMeasureForVarSizeItem
      end                                                          as VariableSizeCompUnitOfMeasure,
       valid_items.QuantityVariableSizeItem,
      valid_items.UnitOfMeasureForVarSizeItem,
      valid_items.FormulaKey,
      //valid_items.BOMItemDescription,

      cast ( case 
            when _BOMItemCategory.FixedItemCategory = 'L' or _BOMItemCategory.FixedItemCategory = 'C' or _BOMItemCategory.FixedItemCategory = 'I'
               then
               case when _MaterialText.MaterialName is not null or _MaterialText.MaterialName <> ''
               then _MaterialText.MaterialName
               else _MaterialTextEN.MaterialName
               end
            when _BOMItemCategory.FixedItemCategory = 'T'
               then valid_items.BOMItemDescription
            when _BOMItemCategory.FixedItemCategory = 'R' and  (valid_items.BillOfMaterialComponent is not null)
               then
               case when _MaterialText.MaterialName is not null or _MaterialText.MaterialName <> ''
               then _MaterialText.MaterialName
               else _MaterialTextEN.MaterialName
               end
            when _BOMItemCategory.FixedItemCategory = 'R' and  (valid_items.BillOfMaterialComponent = '')
               then valid_items.BOMItemDescription
            when _BOMItemCategory.FixedItemCategory = 'D'
               then
               case when _DocumentText.DocumentDescription is not null or _DocumentText.DocumentDescription <> ''
               then _DocumentText.DocumentDescription
               else _DocumentTextEN.DocumentDescription
               end
            when _BOMItemCategory.FixedItemCategory = 'K'
               then
               case when _Class._ClassDescription[1:Language = $session.system_language].ClassDescription is not null
                        or _Class._ClassDescription[1:Language = $session.system_language].ClassDescription <> ''
                    then _Class._ClassDescription[1:Language = $session.system_language].ClassDescription
                    else _Class._ClassDescription[1:Language = 'E'].ClassDescription
               end
            when _BOMItemCategory.FixedItemCategory = 'N' and (valid_items.BillOfMaterialComponent <> '')
               then
               case when _MaterialText.MaterialName is not null or _MaterialText.MaterialName <> ''
               then _MaterialText.MaterialName
               else _MaterialTextEN.MaterialName
               end
            when _BOMItemCategory.FixedItemCategory = 'N' and  (valid_items.BillOfMaterialComponent = '')
               then valid_items.BOMItemDescription
            when _BOMItemCategory.FixedItemCategory = 'P' and (valid_items.BillOfMaterialComponent <> '')
               then
                case when _MaterialText.MaterialName is not null or _MaterialText.MaterialName <> ''
               then _MaterialText.MaterialName
                else _MaterialTextEN.MaterialName
               end
            when _BOMItemCategory.FixedItemCategory = 'P' and  (valid_items.BillOfMaterialComponent = '')
               then valid_items.BOMItemDescription
            when _BOMItemCategory.FixedItemCategory = 'S' and (valid_items.BillOfMaterialComponent <> '')
               then
            case when _MaterialText.MaterialName is not null or _MaterialText.MaterialName <> ''
               then _MaterialText.MaterialName
               else _MaterialTextEN.MaterialName
               end              
       end as ojtxp ) as ComponentDescription ,
      valid_items.BOMItemDescription,
      valid_items.BOMItemText2,
      valid_items.LongTextLanguage,
      valid_items.MaterialGroup,
      valid_items.DocumentType,
      valid_items.DocNumber,
      valid_items.DocumentVersion,
      valid_items.DocumentPart,
      valid_items.ClassNumber,
      valid_items.ClassType,
      valid_items.ResultingItemCategory,
      valid_items.DependencyObjectNumber,
      valid_items.ObjectType,
      valid_items.IsClassificationRelevant,
      valid_items.IsBulkMaterial,
      valid_items.BOMItemIsSparePart  , 
      valid_items.BOMItemIsSalesRelevant,
      valid_items.IsProductionRelevant,
      valid_items.BOMItemIsPlantMaintRelevant,
      valid_items.BOMItemIsCostingRelevant,
      valid_items.IsEngineeringRelevant,
      valid_items.SpecialProcurementType,
      valid_items.IsBOMRecursiveAllowed,
      valid_items.OperationLeadTimeOffset,
      valid_items.OpsLeadTimeOffsetUnit,
      valid_items.IsMaterialProvision,
      valid_items.BOMIsRecursive,
      valid_items.DocumentIsCreatedByCAD,
      valid_items.DistrKeyCompConsumption,
      valid_items.DeliveryDurationInDays,
      valid_items.Creditor,
      valid_items.CostElement,
      valid_items.Size1,
      valid_items.Size2,
      valid_items.Size3,
      valid_items.UnitOfMeasureForSize1To3,
      valid_items.GoodsReceiptDuration,
      valid_items.PurchasingOrganization,
      valid_items.RequiredComponent,
      valid_items.MultipleSelectionAllowed,
      valid_items.ProdOrderIssueLocation,
      valid_items.MaterialIsCoProduct,
      valid_items.ExplosionType,
      valid_items.FollowUpGroup,
      valid_items.DiscontinuationGroup,
      valid_items.IsConfigurableBOM,
      valid_items.ReferencePoint,
      valid_items.LeadTimeOffset,
      valid_items.IsSoftwareComponent,
      valid_items.ProductionSupplyArea,
      valid_items.IsDeleted,
      valid_items.IsALE,
//Alternative Item Fields

      valid_items.AlternativeItemGroup,
      valid_items.AlternativeItemPriority,
      valid_items.AlternativeItemStrategy,
      valid_items.UsageProbabilityPercent,     
      _BOMItemCategoryText.BillOfMaterialItemCategoryDesc as BillOfMaterialItemCategoryDesc,
      cast ( valid_items.IsPhantomItem as dumps preserving type )  as MaterialComponentIsPhantomItem,
      cast ( valid_items.IsPhantomItem as dumps preserving type )  as IsPhantomItem,
      valid_items.LastChangeDateTime                               as LastChangeDateTime,
      valid_items.IsPMAssemblyRelevant,
      
       valid_items.OrigSalesOrderBOMItmCategory,
       valid_items.OrigSalesOrderBOM,
       valid_items.OrigSalesOrderBOMItmNodeNumber,
       valid_items.OrigSalesOrderBOMItmNumber,
       valid_items.PreliminaryMaterial,
      // valid_items.BOMItemGroup,

      _BOMItemCategory,
      //_Material,

      _UnitOfMeasure,
      _Currency,
      //_BillOfMaterialVariantUsage,

      _Mast,
      _Dost,
      _Prst,
      _Kdst,
      _Eqst,
      _Tpst,
      _Stst

    
}
/*+[internal] {
"BASEINFO":
{
"FROM":
[
"I_BILLOFMATERIALITEMCATEGORY",
"I_BOMITEMCATEGORYTEXT",
"I_CLFNCLASSDESCRIPTION",
"I_CLFNCLASSVH",
"I_DOCUMENTINFORECORDDESC",
"I_MATERIALTEXT",
"P_BOMITEMS"
],
"ASSOCIATED":
[
"I_BILLOFMATERIALITEMCATEGORY",
"I_BOMITEMCATEGORYTEXT",
"I_CLFNCLASSVH",
"I_CURRENCY",
"I_DOCUMENTBOMLINK",
"I_DOCUMENTINFORECORDDESC",
"I_EQST",
"I_MATERIAL",
"I_MATERIALBOMLINK",
"I_MATERIALTEXT",
"I_PRST",
"I_SALESORDERBOMLINK",
"I_STST",
"I_TPST",
"I_UNITOFMEASURE"
],
"BASE":
[],
"ANNO_REF":
[],
"SCALAR_FUNCTION":
[],
"VERSION":0,
"ANNOREF_EVALUATION_ERROR":""
}
}*/