C_ChmlCmplncPrimMatl

DDL: C_CHMLCMPLNCPRIMMATL Type: view COMPOSITE Package: EHFND_CNS_CCI

Chemical Compliance Primary Material

C_ChmlCmplncPrimMatl is a Composite CDS View (Dimension) that provides data about "Chemical Compliance Primary Material" in SAP S/4HANA. It reads from 1 data source (I_ChmlCmplncInfo) and exposes 14 fields. It has 2 associations to related views. Part of development package EHFND_CNS_CCI.

Data Sources (1)

SourceAliasJoin Type
I_ChmlCmplncInfo ChemicalComplianceInfo from

Associations (2)

CardinalityTargetAliasCondition
[1..1] I_ChmlCmplncInfo _ChmlCmplncInfo _ChmlCmplncInfo.ChmlCmplncInfoUUID = $projection.ChmlCmplncInfoUUID -- provide additional product data via exposed
[1..1] I_Product _MaterialData PrimaryMaterial.Material = _MaterialData.Product

Annotations (13)

NameValueLevelField
EndUserText.label Chemical Compliance Primary Material view
AbapCatalog.sqlViewName CCCMATLPRIM view
AbapCatalog.compiler.compareFilter true view
AccessControl.authorizationCheck #MANDATORY view
AccessControl.personalData.blocking #NOT_REQUIRED view
ClientHandling.algorithm #SESSION_VARIABLE view
VDM.viewType #COMPOSITE view
ObjectModel.representativeKey ChmlCmplncInfoUUID view
ObjectModel.usageType.dataClass #MIXED view
ObjectModel.usageType.sizeCategory #L view
ObjectModel.usageType.serviceQuality #C view
Analytics.dataCategory #DIMENSION view
Metadata.allowExtensions true view

Fields (14)

KeyFieldSource TableSource FieldDescription
ChmlCmplncInfoUUID
MaterialasMaterial
ProductNameasMaterialName
SpecificationasChmlCmplncInfoCombinedID
ChmlCmplncInfoType I_ChmlCmplncInfo ChmlCmplncInfoType
ChmlCmplncInternalName I_ChmlCmplncInfo ChmlCmplncInternalName
MaterialIsSold MaterialIsSold
MaterialIsSourced MaterialIsSourced
MaterialIsTransported MaterialIsTransported
MaterialIsDisposed MaterialIsDisposed
MaterialIsEmissionRelevant MaterialIsEmissionRelevant
ProdStewardshipRespUnit ProdStewardshipRespUnit
_ChmlCmplncInfo _ChmlCmplncInfo
_MaterialData _MaterialData
@EndUserText.label: 'Chemical Compliance Primary Material'

@AbapCatalog:
{
  sqlViewName: 'CCCMATLPRIM',
  compiler.compareFilter: true
}

@AccessControl:
{
  authorizationCheck: #MANDATORY,
  // blocking of personal data not required (no personal data fields exposed for material)

  personalData.blocking: #NOT_REQUIRED
}

@ClientHandling.algorithm: #SESSION_VARIABLE

@VDM.viewType: #COMPOSITE

@ObjectModel:
{
  semanticKey:  [ 'Material' ],
  representativeKey: 'ChmlCmplncInfoUUID',
  usageType:
  {
    dataClass: #MIXED,
    sizeCategory: #L,
    serviceQuality: #C
  }

}
@Analytics:{
    dataCategory: #DIMENSION
}
@Metadata.allowExtensions:true
define view C_ChmlCmplncPrimMatl
  --Select data from master table 'Chemical Compliance Info'
  as select from           I_ChmlCmplncInfo             as ChemicalComplianceInfo

  --Is Researched DTEL Text
    left outer to one join I_ChmlCmplncIsResearchedText as ProdIsResearchedText on ProdIsResearchedText.Language = $session.system_language

  --Join data from primary material assignment
    left outer to one join I_ChmlCmplncMatlAssgmt       as PrimaryMaterial      on  ChemicalComplianceInfo.ChmlCmplncInfoUUID = PrimaryMaterial.ChmlCmplncInfoUUID
                                                                                and PrimaryMaterial.MatlAssgmtIsPrimary       = 'X'
  --Join data from product name
    left outer to one join I_ProductText                as MaterialData         on  PrimaryMaterial.Material = MaterialData.Product
                                                                                and MaterialData.Language    = $session.system_language

  association [1..1] to I_ChmlCmplncInfo as _ChmlCmplncInfo on _ChmlCmplncInfo.ChmlCmplncInfoUUID = $projection.ChmlCmplncInfoUUID


  -- provide additional product data via exposed association
  association [1..1] to I_Product        as _MaterialData   on PrimaryMaterial.Material = _MaterialData.Product
{
      --UUID of Chemical Compliance Info
      @ObjectModel.text.element: [ 'ChmlCmplncInfoCombinedName' ]
  key ChemicalComplianceInfo.ChmlCmplncInfoUUID,

      --Material
      PrimaryMaterial.Material                                                   as Material,

      --Material Name
      MaterialData.ProductName                                                   as MaterialName,

      case ChmlCmplncProdIsResearched
        when 'X' then
           cast(
             concat_with_space( concat_with_space( coalesce( MaterialData.ProductName, ChemicalComplianceInfo.ChmlCmplncInternalName ), '-', 2 ),
                                ProdIsResearchedText.ChmlCmplncRnDSampleText, 2 )
           as ehfnd_cci_product_name )
        when '' then
          cast( coalesce( MaterialData.ProductName, ChemicalComplianceInfo.ChmlCmplncInternalName ) as ehfnd_cci_product_name )
      end                                                                        as ChmlCmplncInfoCombinedName,

      -- Needed in PCE monitor app like Initiating object ID
      coalesce( PrimaryMaterial.Material, ChemicalComplianceInfo.Specification ) as ChmlCmplncInfoCombinedID,


      ChemicalComplianceInfo.ChmlCmplncInfoType,

      ChemicalComplianceInfo.ChmlCmplncInternalName,

      --Roles and Responsible Unit for DCL
      MaterialIsProduced,
      MaterialIsSold,
      MaterialIsSourced,
      MaterialIsTransported,
      MaterialIsDisposed,
      MaterialIsEmissionRelevant,

      ProdStewardshipRespUnit,

      /* Associations */
      _ChmlCmplncInfo,
      _MaterialData
}