P_ARPCurRole

DDL: P_ARPCURROLE SQL: PARPCURROLE Type: view BASIC

P_ARPCurRole is a Basic CDS View in SAP S/4HANA. It reads from 1 data source (I_CompanyCode) and exposes 6 fields with key field CompanyCode. It has 4 associations to related views.

Data Sources (1)

SourceAliasJoin Type
I_CompanyCode _CompanyCode from

Associations (4)

CardinalityTargetAliasCondition
[0..1] t001a _CompanyCurrencyControl $projection.CompanyCode = _CompanyCurrencyControl.bukrs
[0..1] I_SAPClient _SAPClient _CompanyCode.mandt = _SAPClient.sapclient
[0..1] t005 _Countries _CompanyCode.Country = _Countries.land1
[0..1] t880 _GlobalCompanyData _CompanyCode.Company = _GlobalCompanyData.rcomp

Annotations (5)

NameValueLevelField
AbapCatalog.sqlViewName PARPCURROLE view
VDM.viewType #BASIC view
VDM.private true view
AccessControl.authorizationCheck #NOT_REQUIRED view
ClientHandling.algorithm #SESSION_VARIABLE view

Fields (6)

KeyFieldSource TableSource FieldDescription
KEY CompanyCode CompanyCode
CompanyCodeName CompanyCodeName
currelseendasAdditionalCurrency1
currelseendasAdditionalCurrency2
AdditionalCurrency1Role
AdditionalCurrency2Role
@AbapCatalog.sqlViewName: 'PARPCURROLE'
@VDM.viewType: #BASIC
@VDM.private: true
@AccessControl.authorizationCheck: #NOT_REQUIRED
@ClientHandling.algorithm: #SESSION_VARIABLE

define view P_ARPCurRole
  as select from I_CompanyCode as _CompanyCode

  association [0..1] to t001a       as _CompanyCurrencyControl on $projection.CompanyCode = _CompanyCurrencyControl.bukrs
  association [0..1] to I_SAPClient as _SAPClient              on _CompanyCode.mandt = _SAPClient.sapclient
  association [0..1] to t005        as _Countries              on _CompanyCode.Country = _Countries.land1
  association [0..1] to t880        as _GlobalCompanyData      on _CompanyCode.Company = _GlobalCompanyData.rcomp
{
  key CompanyCode,
      CompanyCodeName,

      case _CompanyCurrencyControl.curtp
          when '11' then _CompanyCode.Currency
          when '12' then _CompanyCode.Currency
          when '30' then _SAPClient.GroupCurrency
          when '31' then _SAPClient.GroupCurrency
          when '32' then _SAPClient.GroupCurrency
          when '40' then _Countries.curha
          when '50' then _Countries.curin
          when '60' then _GlobalCompanyData.curr
          else ''
      end                             as AdditionalCurrency1,

      case _CompanyCurrencyControl.curtp2
          when '11' then _CompanyCode.Currency
          when '12' then _CompanyCode.Currency
          when '30' then _SAPClient.GroupCurrency
          when '31' then _SAPClient.GroupCurrency
          when '32' then _SAPClient.GroupCurrency
          when '40' then _Countries.curha
          when '50' then _Countries.curin
          when '60' then _GlobalCompanyData.curr
          else ''
      end                             as AdditionalCurrency2,
      
      cast( _CompanyCurrencyControl.curtp  as fis_adl1_currole preserving type )  as AdditionalCurrency1Role,
      cast( _CompanyCurrencyControl.curtp2 as fis_adl2_currole preserving type )  as AdditionalCurrency2Role
}    
/*+[internal] {
"BASEINFO":
{
"FROM":
[
"I_COMPANYCODE",
"I_SAPCLIENT",
"T001A",
"T005",
"T880"
],
"ASSOCIATED":
[
"I_SAPCLIENT",
"T001A",
"T005",
"T880"
],
"BASE":
[],
"ANNO_REF":
[],
"SCALAR_FUNCTION":
[],
"VERSION":0,
"ANNOREF_EVALUATION_ERROR":""
}
}*/