C_ProdCmplncServiceRequestProd

DDL: C_PRODCMPLNCSERVICEREQUESTPROD SQL: CPCMPLSERVREQPVH Type: view CONSUMPTION

Product Compliance Service Requests Prod

C_ProdCmplncServiceRequestProd is a Consumption CDS View that provides data about "Product Compliance Service Requests Prod" in SAP S/4HANA. It reads from 1 data source (I_ChmlCmplncInfo) and exposes 12 fields with key field ChmlCmplncInfoUUID. It has 3 associations to related views.

Data Sources (1)

SourceAliasJoin Type
I_ChmlCmplncInfo _ChmlCmplncInfo from

Associations (3)

CardinalityTargetAliasCondition
[0..1] C_ChmlCmplncPrimMatl _PrimeMatReferenced $projection.ChmlCmplncInfoUUID = _PrimeMatReferenced.ChmlCmplncInfoUUID -- Document information to show the language (used in virtual elements coding for filtering)
[0..*] C_ProdCmplncProdReqSftyDataSht _SftyDataSht $projection.ChmlCmplncInfoUUID = _SftyDataSht.ChmlCmplncInfoUUID -- Data bucket information via a Custom Entity (ABAP Implementation - so only accessible via OData / SADL)
[0..*] C_ProdCmplncProdReqSendData _SendData $projection.ChmlCmplncInfoUUID = _SendData.ChmlCmplncInfoUUID

Annotations (12)

NameValueLevelField
EndUserText.label Product Compliance Service Requests Prod view
AbapCatalog.sqlViewName CPCMPLSERVREQPVH view
AbapCatalog.compiler.compareFilter true view
AbapCatalog.preserveKey true view
AccessControl.authorizationCheck #MANDATORY view
AccessControl.personalData.blocking #NOT_REQUIRED view
VDM.viewType #CONSUMPTION view
ClientHandling.algorithm #SESSION_VARIABLE view
ObjectModel.usageType.dataClass #MASTER view
ObjectModel.usageType.sizeCategory #L view
ObjectModel.usageType.serviceQuality #D view
Search.searchable true view

Fields (12)

KeyFieldSource TableSource FieldDescription
KEY ChmlCmplncInfoUUID I_ChmlCmplncInfo ChmlCmplncInfoUUID
ChmlCompositionUUID _Composition ChmlCompositionUUID
PhysChmlPrptyUUID _PhysChemProperty PhysChmlPrptyUUID
PCSftyPrptyUUID _SftyRelated PCSftyPrptyUUID
ChmlCmplncInfoCombinedName _PrimeMatReferenced ChmlCmplncInfoCombinedName
Material _PrimeMatReferenced Material
ProductGroup
ProductGroupNameasProductGroupName
ProdCmplncServiceReqIsExisting
_SftyDataSht _SftyDataSht
_SendData _SendData
_ProductGroup_2
@EndUserText.label: 'Product Compliance Service Requests Prod'
@AbapCatalog.sqlViewName: 'CPCMPLSERVREQPVH'
@AbapCatalog.compiler.compareFilter: true
@AbapCatalog.preserveKey: true
@AccessControl.authorizationCheck: #MANDATORY
// blocking of personal data not required (no personal data fields exposed for material; user can not be blocked)

@AccessControl.personalData.blocking: #NOT_REQUIRED

@VDM.viewType: #CONSUMPTION
@ClientHandling.algorithm: #SESSION_VARIABLE

@ObjectModel:
{
  usageType:
  {
    dataClass: #MASTER,
    sizeCategory: #L, // <= 10 000 000

    serviceQuality: #D // <= 20 msec

  }
}

@Search.searchable: true
define view C_ProdCmplncServiceRequestProd
  as select from           I_ChmlCmplncInfo           as _ChmlCmplncInfo

    left outer to one join I_ChmlComposition          as _Composition             on  _Composition.ChmlCmplncInfoUUID      = _ChmlCmplncInfo.ChmlCmplncInfoUUID
                                                                                  and _Composition.ChmlCompositionStatus   = 'RE'
                                                                                  and _Composition.ChmlCompositionType     = 'ANALYTIC1'

//    left outer to one join I_ChmlComposition          as _CompositionIp           on  _CompositionIp.ChmlCmplncInfoUUID      = _ChmlCmplncInfo.ChmlCmplncInfoUUID

//                                                                                  and _CompositionIp.ChmlCompositionStatus   = 'IP'

//                                                                                  and _CompositionIp.ChmlCompositionType     = 'ANALYTIC1'



    left outer to one join I_PhysicalChemicalProperty as _PhysChemProperty        on  _PhysChemProperty.ChmlCmplncInfoUUID = _ChmlCmplncInfo.ChmlCmplncInfoUUID
                                                                                  and _PhysChemProperty.PCPrptyProcgSts    = 'RE'

//    left outer to one join I_PhysicalChemicalProperty as _PhysChemPropertyIp      on  _PhysChemPropertyIp.ChmlCmplncInfoUUID = _ChmlCmplncInfo.ChmlCmplncInfoUUID

//                                                                                  and _PhysChemPropertyIp.PCPrptyProcgSts    = 'IP'



    left outer to one join I_PCSftyProperty           as _SftyRelated             on  _SftyRelated.ChmlCmplncInfoUUID = _ChmlCmplncInfo.ChmlCmplncInfoUUID
                                                                                  and _SftyRelated.PCPrptyProcgSts    = 'RE'

//    left outer to one join I_PCSftyProperty           as _SftyRelatedIp           on  _SftyRelatedIp.ChmlCmplncInfoUUID = _ChmlCmplncInfo.ChmlCmplncInfoUUID

//                                                                                  and _SftyRelatedIp.PCPrptyProcgSts    = 'IP'


  // used to filter existing service requests on the create dialog

    left outer to one join P_LatestSrvcReqForProduct  as _LatestSrvcReqForProduct on _LatestSrvcReqForProduct.ChmlCmplncInfoUUID = _ChmlCmplncInfo.ChmlCmplncInfoUUID

  -- Combined name of CCI
  association [0..1] to C_ChmlCmplncPrimMatl           as _PrimeMatReferenced on $projection.ChmlCmplncInfoUUID = _PrimeMatReferenced.ChmlCmplncInfoUUID
  -- Document information to show the language (used in virtual elements coding for filtering)
  association [0..*] to C_ProdCmplncProdReqSftyDataSht as _SftyDataSht        on $projection.ChmlCmplncInfoUUID = _SftyDataSht.ChmlCmplncInfoUUID
  -- Data bucket information via a Custom Entity (ABAP Implementation - so only accessible via OData / SADL)
  association [0..*] to C_ProdCmplncProdReqSendData    as _SendData           on $projection.ChmlCmplncInfoUUID = _SendData.ChmlCmplncInfoUUID

{
  key _ChmlCmplncInfo.ChmlCmplncInfoUUID,

      _Composition.ChmlCompositionUUID,

      _PhysChemProperty.PhysChmlPrptyUUID,

      _SftyRelated.PCSftyPrptyUUID,

      // Diaglog Select Product for Request Creation

      // product name

      _PrimeMatReferenced.ChmlCmplncInfoCombinedName,
      // number

      _PrimeMatReferenced.Material,
      // product group

      //@ObjectModel.text.association: '_PrimeMatReferenced._MaterialData._ProductGroupText'

      _PrimeMatReferenced._MaterialData.ProductGroup,

      --Description of Product Group
      @Search.ranking: #HIGH
      @ObjectModel.readOnly: true
      @Search.defaultSearchElement: true
      //      @Semantics.text: true

      _PrimeMatReferenced._MaterialData._ProductGroup_2._ProductGroupText[1: Language = $session.system_language ].ProductGroupName as ProductGroupName,

      // Dialog Confirm Request Creation

      // analytical composition released date

//      _Composition.ReleaseDateTime                                                                                                  as AnalyticCmpstnReleaseDateTime,

      // physical-chemical properties released date

//      _PhysChemProperty.ValidityStartDateTime                                                                                       as PhysChemPrptyReleaseDateTime,

      // safety-related properties released date

//      _SftyRelated.ValidityStartDateTime                                                                                            as PCSftyPrptyReleaseDateTime,


      cast ( case when _LatestSrvcReqForProduct.LastChangeDateTime is null then ' ' else 'X' end as ehfnd_boolean preserving type ) as ProdCmplncServiceReqIsExisting,
//      cast ( case when _PhysChemPropertyIp.PhysChmlPrptyUUID  is null then ' ' else 'X' end as ehfnd_boolean preserving type )      as PhysChemPropertyIsInProgress,

//      cast ( case when _CompositionIp.ChmlCompositionUUID     is null then ' ' else 'X' end as ehfnd_boolean preserving type )      as CompositionIsInProgress,

//      cast ( case when _SftyRelatedIp.PCSftyPrptyUUID         is null then ' ' else 'X' end as ehfnd_boolean preserving type )      as PCSftyPrptyIsInProgress,


      _SftyDataSht,
      @ObjectModel.filter.enabled: false
      _SendData,
      _PrimeMatReferenced._MaterialData._ProductGroup_2
}
where
  _ChmlCmplncInfo.ChmlCmplncInfoType = 'BU'
/*+[internal] {
"BASEINFO":
{
"FROM":
[
"C_CHMLCMPLNCPRIMMATL",
"I_CHMLCMPLNCINFO",
"I_CHMLCOMPOSITION",
"I_PCSFTYPROPERTY",
"I_PHYSICALCHEMICALPROPERTY",
"I_PRODUCT",
"I_PRODUCTGROUPTEXT_2",
"I_PRODUCTGROUP_2",
"P_LATESTSRVCREQFORPRODUCT"
],
"ASSOCIATED":
[
"C_CHMLCMPLNCPRIMMATL",
"C_PRODCMPLNCPRODREQSENDDATA",
"C_PRODCMPLNCPRODREQSFTYDATASHT",
"I_PRODUCTGROUP_2"
],
"BASE":
[
"I_PRODUCT"
],
"ANNO_REF":
[],
"SCALAR_FUNCTION":
[],
"VERSION":0,
"ANNOREF_EVALUATION_ERROR":""
}
}*/