P_ARPCurRole

DDL: P_ARPCURROLE SQL: PARPCURROLE Type: view BASIC Package: FINS_FIS_APAR_APPS

Currencies based on currency role for archived line items

P_ARPCurRole is a Basic CDS View that provides data about "Currencies based on currency role for archived line items" in SAP S/4HANA. It reads from 1 data source (I_CompanyCode) and exposes 4 fields with key field CompanyCode. It has 4 associations to related views. Part of development package FINS_FIS_APAR_APPS.

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 (4)

KeyFieldSource TableSource FieldDescription
KEY CompanyCode CompanyCode
CompanyCodeName CompanyCodeName
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,

      cast(
        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 fis_hwae2 )                           as AdditionalCurrency1,

      cast(
        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 fis_hwae3 )                           as AdditionalCurrency2,
      
      cast( _CompanyCurrencyControl.curtp  as fis_adl1_currole preserving type )  as AdditionalCurrency1Role,
      cast( _CompanyCurrencyControl.curtp2 as fis_adl2_currole preserving type )  as AdditionalCurrency2Role
}