C_PurchasingCategoryTranST

DDL: C_PURCHASINGCATEGORYTRANST SQL: CPURCATTRANST Type: view CONSUMPTION

Translate Purchasing Categories

C_PurchasingCategoryTranST is a Consumption CDS View that provides data about "Translate Purchasing Categories" in SAP S/4HANA. It reads from 2 data sources (I_PurchasingCategory, I_PurchasingCatTranslationSts) and exposes 24 fields with key fields PurgCatUUID, PurchasingCategory, PurgCatTranslationTgtLang, PurgCatTranslationTgtLangSts. It has 6 associations to related views.

Data Sources (2)

SourceAliasJoin Type
I_PurchasingCategory I_PurchasingCategory from
I_PurchasingCatTranslationSts PurchasingCatTranslationSts inner

Associations (6)

CardinalityTargetAliasCondition
[0..1] I_PurchasingCategoryValueHelp _PurchasingCategoryValueHelp $projection.PurchasingCategory = _PurchasingCategoryValueHelp.PurchasingCategory
[0..1] C_TransPurCatLastChangedByVH _TransPurCatLastChangedByVH $projection.LastChangedByUser = _TransPurCatLastChangedByVH.UserID
[0..1] C_TransPurgCatTransStsVH _PurgCatTgtTransStsValueHelp $projection.PurgCatTranslationTgtLangSts = _PurgCatTgtTransStsValueHelp.SLCTranslationStatus
[0..1] C_TransPurgCatTransStsVH _PurgCatOvrlTransStsVH $projection.PurgCatTranslationOvrlStatus = _PurgCatOvrlTransStsVH.SLCTranslationStatus
[0..1] I_User _CreatedByUser _CreatedByUser.UserID = $projection.CreatedByUser
[0..1] I_User _LastChangedByUser _LastChangedByUser.UserID = $projection.LastChangedByUser

Annotations (13)

NameValueLevelField
ClientHandling.algorithm #SESSION_VARIABLE view
AbapCatalog.compiler.compareFilter true view
ObjectModel.usageType.dataClass #MIXED view
ObjectModel.usageType.serviceQuality #C view
ObjectModel.usageType.sizeCategory #L view
AccessControl.authorizationCheck #CHECK view
AccessControl.personalData.blocking #REQUIRED view
AbapCatalog.sqlViewName CPURCATTRANST view
VDM.viewType #CONSUMPTION view
EndUserText.label Translate Purchasing Categories view
Search.searchable true view
UI.headerInfo.typeName Purchasing Category Description view
UI.headerInfo.typeNamePlural Purchasing Category Descriptions view

Fields (24)

KeyFieldSource TableSource FieldDescription
KEY PurgCatUUID I_PurchasingCategory PurgCatUUID
KEY PurchasingCategory PurchasingCategory
KEY PurgCatTranslationTgtLang I_PurchasingCatTranslationSts PurgCatTranslationTgtLang
KEY PurgCatTranslationTgtLangSts I_PurchasingCatTranslationSts PurgCatTranslationTgtLangSts
PurgCatTitle
PurgCatName PurgCatName
PurgCatDescription
Language
CreatedByUser CreatedByUser
CreatedByUserFullName
CreationDateTime CreationDateTime
LastChangedByUser
LastChangedByUserFullName
LastChangeDateTime LastChangeDateTime
PurgCatTranslationOvrlStatus
PurgCatIsInactive PurgCatIsInactive
UICT_IsReadOnly
_Language
_PurgCatTranslationTgtLang I_PurchasingCatTranslationSts _PurgCatTranslationTgtLang
_TransPurCatLastChangedByVH _TransPurCatLastChangedByVH
_PurgCatOvrlTransStsVH _PurgCatOvrlTransStsVH
_PurgCatTgtTransStsValueHelp _PurgCatTgtTransStsValueHelp
_PurchasingCategoryValueHelp _PurchasingCategoryValueHelp
_InactiveStatus _InactiveStatus
@ClientHandling.algorithm: #SESSION_VARIABLE
@AbapCatalog.compiler.compareFilter: true
@ObjectModel.usageType.dataClass:  #MIXED
@ObjectModel.usageType.serviceQuality: #C
@ObjectModel.usageType.sizeCategory: #L
@ObjectModel.semanticKey: [ 'PurchasingCategory','PurgCatName' ]

@AccessControl.authorizationCheck: #CHECK
@AccessControl.personalData.blocking: #REQUIRED
@AbapCatalog.sqlViewName: 'CPURCATTRANST'

@VDM.viewType: #CONSUMPTION
@EndUserText.label: 'Translate Purchasing Categories'

@Search.searchable: true

@UI.headerInfo: {
      typeName: 'Purchasing Category Description',
      typeNamePlural: 'Purchasing Category Descriptions'
}

define view C_PurchasingCategoryTranST
  as select from I_PurchasingCategory
    inner join   I_PurchasingCatTranslationSts as PurchasingCatTranslationSts on  I_PurchasingCategory.PurgCatUUID                         =  PurchasingCatTranslationSts.PurgCatUUID
                                                                              and PurchasingCatTranslationSts.PurgCatTranslationTgtLangSts <> '00'

  //associations for Value Helps

  association [0..1] to I_PurchasingCategoryValueHelp as _PurchasingCategoryValueHelp on $projection.PurchasingCategory = _PurchasingCategoryValueHelp.PurchasingCategory
  association [0..1] to C_TransPurCatLastChangedByVH  as _TransPurCatLastChangedByVH  on $projection.LastChangedByUser = _TransPurCatLastChangedByVH.UserID
  association [0..1] to C_TransPurgCatTransStsVH      as _PurgCatTgtTransStsValueHelp on $projection.PurgCatTranslationTgtLangSts = _PurgCatTgtTransStsValueHelp.SLCTranslationStatus
  association [0..1] to C_TransPurgCatTransStsVH      as _PurgCatOvrlTransStsVH       on $projection.PurgCatTranslationOvrlStatus = _PurgCatOvrlTransStsVH.SLCTranslationStatus
  association [0..1] to I_User                    as _CreatedByUser               on _CreatedByUser.UserID = $projection.CreatedByUser
  association [0..1] to I_User                    as _LastChangedByUser           on _LastChangedByUser.UserID = $projection.LastChangedByUser

{
      @UI.hidden: true
  key I_PurchasingCategory.PurgCatUUID                                                                                                                                                                                                          as PurgCatUUID,

      @UI.selectionField.position:10
      @Consumption.valueHelp: '_PurchasingCategoryValueHelp'
      @ObjectModel: { foreignKey.association: '_PurchasingCategoryValueHelp' }
      @ObjectModel.text.element:  [ 'PurgCatTitle' ]
      @Search: { defaultSearchElement: true, ranking: #HIGH, fuzzinessThreshold: 0.7 }
  key PurchasingCategory,

      @UI.textArrangement: #TEXT_ONLY
      @UI.selectionField.position:20
      @Search: { defaultSearchElement: true, ranking: #HIGH, fuzzinessThreshold: 0.7 }
      @ObjectModel: { foreignKey.association: '_PurgCatTranslationTgtLang' }
  key PurchasingCatTranslationSts.PurgCatTranslationTgtLang                                                                                                                                                                                               as PurgCatTranslationTgtLang,

      @UI.selectionField.position:30
      @UI.textArrangement: #TEXT_ONLY
      @Search: { defaultSearchElement: true, ranking: #HIGH, fuzzinessThreshold: 0.7 }
      @ObjectModel: { foreignKey.association: '_PurgCatTgtTransStsValueHelp' }
  key PurchasingCatTranslationSts.PurgCatTranslationTgtLangSts                                                                                                                                                                                            as PurgCatTranslationTgtLangSts,


      @UI.hidden: true
      @ObjectModel: {
        readOnly: true,
        virtualElement,
        virtualElementCalculatedBy: 'cl_slc_puc_translate_calc_exit'}
      cast('' as /srmsmc/purchasing_cat_name )                                                                                    as PurgCatTitle,


      /* ####### Workaround Namensuche ####### */

      @UI.hidden: true
      @Search: { defaultSearchElement: true, ranking: #HIGH, fuzzinessThreshold: 0.8 }
      PurgCatName,

      @UI.hidden: true
      @Search: { defaultSearchElement: true, ranking: #HIGH, fuzzinessThreshold: 0.8 }
      _PurchasingCategoryDesc[1: Language =  $session.system_language].PurgCatDescription,                                                                                                                                                        

      /* ##################################### */

      @UI.textArrangement: #TEXT_ONLY
      @Consumption.filter.hidden: true
      @ObjectModel: { foreignKey.association: '_Language' }
      cast( I_PurchasingCategory.Language as /srmsmc/original_lang_langu preserving type )                                                                                                                                                                as Language,

      @ObjectModel.text.element: ['CreatedByUserFullName']
      @Consumption.filter.hidden: true
      CreatedByUser,

      @UI.hidden: true
      @Search: { defaultSearchElement: true, ranking: #HIGH, fuzzinessThreshold: 0.8 }
      cast( _CreatedByUser.UserDescription as /srmsmc/created_by_user_desc preserving type)                                                                                                                                                              as CreatedByUserFullName,

      @Consumption.filter.selectionType: #INTERVAL
      CreationDateTime,

      @UI.selectionField.position:40
      @ObjectModel: { foreignKey.association: '_TransPurCatLastChangedByVH' }
      @Consumption.valueHelp: '_TransPurCatLastChangedByVH'
      @ObjectModel.text.element: [ 'LastChangedByUserFullName' ]
      cast( I_PurchasingCategory.LastChangedByUser as vdm_lastchangedbyuserid preserving type )                                                                                                                                                           as LastChangedByUser,

      @UI.hidden: true
      @Search: { defaultSearchElement: true, ranking: #HIGH, fuzzinessThreshold: 0.8 }
      cast( _LastChangedByUser.UserDescription as /srmsmc/last_changed_by_desc preserving type)                                                                                                                                                          as LastChangedByUserFullName,

      @Consumption.filter.selectionType: #INTERVAL
      LastChangeDateTime,

      /* ####### Status ####### */

      @UI.textArrangement: #TEXT_ONLY
      @ObjectModel: { foreignKey.association: '_PurgCatOvrlTransStsVH' }
      @Consumption.filter.hidden: true
      cast ( PurgCatTranslationOvrlStatus as /srmsmc/overall_transl_status )                                                                                                                                                                              as PurgCatTranslationOvrlStatus,

      @ObjectModel: { text.association: '_InactiveStatus', foreignKey.association: '_InactiveStatus'}
      @UI.textArrangement: #TEXT_ONLY
      PurgCatIsInactive,

      @UI.hidden: true
      @ObjectModel: {
             readOnly: true,
             virtualElement,
             virtualElementCalculatedBy: 'cl_slc_puc_translate_calc_exit' }
      @Semantics.booleanIndicator: true
      cast( '' as abap.char( 1 )  )                                                                                                                                                                       as UICT_IsReadOnly,

      /*----------------------------------------------------------------------------
      Associations
      */  --------------------------------------------------------------------------
      @Consumption.filter.hidden: true
      I_PurchasingCategory._Language,
      @Consumption.filter.hidden: true
      PurchasingCatTranslationSts._PurgCatTranslationTgtLang,
      @Consumption.filter.hidden: true
      _TransPurCatLastChangedByVH,
      @Consumption.filter.hidden: true
      _PurgCatOvrlTransStsVH,
      @Consumption.filter.hidden: true
      _PurgCatTgtTransStsValueHelp,
      @Consumption.filter.hidden: true
      _PurchasingCategoryValueHelp,
      @Consumption.filter.hidden: true
      _InactiveStatus

}
where
  PurgCatTranslationOvrlStatus != '00'
/*+[internal] {
"BASEINFO":
{
"FROM":
[
"I_PURCHASINGCATEGORY",
"I_PURCHASINGCATEGORYDESC",
"I_PURCHASINGCATTRANSLATIONSTS",
"I_USER"
],
"ASSOCIATED":
[
"C_TRANSPURCATLASTCHANGEDBYVH",
"C_TRANSPURGCATTRANSSTSVH",
"I_INACTIVESTATUS",
"I_LANGUAGE",
"I_PURCHASINGCATEGORYVALUEHELP",
"I_USER"
],
"BASE":
[
"I_PURCHASINGCATEGORY",
"I_PURCHASINGCATTRANSLATIONSTS"
],
"ANNO_REF":
[],
"SCALAR_FUNCTION":
[],
"VERSION":0,
"ANNOREF_EVALUATION_ERROR":""
}
}*/