C_RO_SAFTFixedAssetTransCube

DDL: C_RO_SAFTFIXEDASSETTRANSCUBE SQL: CROSAFTFATRANCUB Type: view CONSUMPTION Package: GLO_FIN_IS_SAFT_AA_RO

RO SAFT Fixed Asset Transaction - Cube

C_RO_SAFTFixedAssetTransCube is a Consumption CDS View (Cube) that provides data about "RO SAFT Fixed Asset Transaction - Cube" in SAP S/4HANA. It reads from 1 data source (I_AssetBalanceCube) and exposes 58 fields with key fields CompanyCode, AssetDepreciationArea, MasterFixedAsset, FixedAsset, Ledger. Part of development package GLO_FIN_IS_SAFT_AA_RO.

Data Sources (1)

SourceAliasJoin Type
I_AssetBalanceCube I_AssetBalanceCube from

Parameters (5)

NameTypeDefault
P_AssetAccountingKeyFigureSet faa_key_figure_set
P_FiscalYear fis_gjahr
P_ToFiscalPeriod fis_period_to
P_KeyDate fagl_keydate
P_SelectedCurrencyBranch saft_aa_ro_curr_branch

Annotations (13)

NameValueLevelField
AbapCatalog.sqlViewName CROSAFTFATRANCUB view
VDM.viewType #CONSUMPTION view
Analytics.dataCategory #CUBE view
Analytics.internalName #LOCAL view
AbapCatalog.compiler.compareFilter true view
AbapCatalog.preserveKey true view
ObjectModel.usageType.sizeCategory #L view
ObjectModel.usageType.serviceQuality D view
ObjectModel.usageType.dataClass TRANSACTIONAL view
AccessControl.authorizationCheck #MANDATORY view
ClientHandling.algorithm #SESSION_VARIABLE view
Metadata.allowExtensions true view
EndUserText.label RO SAFT Fixed Asset Transaction - Cube view

Fields (58)

KeyFieldSource TableSource FieldDescription
KEY CompanyCode Values CompanyCode
KEY AssetDepreciationArea Values AssetDepreciationArea
KEY MasterFixedAsset Values MasterFixedAsset
KEY FixedAsset Values FixedAsset
KEY Ledger Values Ledger
KEY FiscalYear Values FiscalYear
KEY FiscalPeriod Values FiscalPeriod
KEY SubLedgerAcctLineItemType Values SubLedgerAcctLineItemType
KEY AssetAcctTransClassfctn Values AssetAcctTransClassfctn
KEY AssetAccountingKeyFigure Values AssetAccountingKeyFigure
KEY AssetAccountingKeyFigureSet Values AssetAccountingKeyFigureSet
KEY AccountingDocument Values AccountingDocument
KEY TransactionSubitem Values TransactionSubitem
KEY DebitCreditCode Values DebitCreditCode
AssetClass
ChartOfDepreciation Values ChartOfDepreciation
ControllingArea Values ControllingArea
LedgerGroup Values LedgerGroup
GroupMasterFixedAsset Values GroupMasterFixedAsset
GroupFixedAsset Values GroupFixedAsset
AccountingDocumentType AccountingDocumentType
AccountingDocumentCreationDate Values AccountingDocumentCreationDate
CreationTime Values CreationTime
PostingDate Values PostingDate
DocumentDate Values DocumentDate
AssetValueDate Values AssetValueDate
AssetTransactionType Values AssetTransactionType
AssignmentReference Values AssignmentReference
DocumentItemText Values DocumentItemText
ReferenceDocumentType Values ReferenceDocumentType
ReferenceDocument Values ReferenceDocument
LogicalSystem Values LogicalSystem
ReferenceDocumentContext Values ReferenceDocumentContext
IsReversal Values IsReversal
IsReversed Values IsReversed
BusinessArea Values BusinessArea
Segment Values Segment
FinancialAccountType Values FinancialAccountType
Fund Values Fund
FunctionalArea Values FunctionalArea
AcctgDocIsPostedPeriodically AcctgDocIsPostedPeriodically
DisplayCurrency Values DisplayCurrency
AmountInDisplayCurrency Values AmountInDisplayCurrency
AcqnProdnCostOnTransIsReset AcqnProdnCostOnTransIsReset
CompanyCodeCurrency
AmountInCompanyCodeCurrency
_CompanyCode _CompanyCode
_DepreciationArea _DepreciationArea
_MasterFixedAsset _MasterFixedAsset
_FixedAsset _FixedAsset
_Ledger _Ledger
_FiscalYear _FiscalYear
_SubLedgerAccLineItemType _SubLedgerAccLineItemType
_AssetKeyFigure _AssetKeyFigure
_AssetKeyFigureSet _AssetKeyFigureSet
_ChartOfDepreciation _ChartOfDepreciation
_AssetTransactionType _AssetTransactionType
_AccountingDocumentType _AccountingDocumentType

@AbapCatalog.sqlViewName: 'CROSAFTFATRANCUB'
@VDM.viewType: #CONSUMPTION
@Analytics: { dataCategory: #CUBE }
@Analytics.internalName: #LOCAL
@AbapCatalog.compiler.compareFilter: true
@AbapCatalog.preserveKey: true
@ObjectModel.usageType.sizeCategory: #L
@ObjectModel.usageType.serviceQuality: 'D'
@ObjectModel.usageType.dataClass: 'TRANSACTIONAL'
@AccessControl.authorizationCheck: #MANDATORY
@ClientHandling.algorithm: #SESSION_VARIABLE
@Metadata.allowExtensions:true
@EndUserText.label: 'RO SAFT Fixed Asset Transaction - Cube'
define view C_RO_SAFTFixedAssetTransCube
  with parameters
    P_AssetAccountingKeyFigureSet : faa_key_figure_set,
    P_FiscalYear                   : fis_gjahr,
    P_ToFiscalPeriod               : fis_period_to,
    P_KeyDate                      : fagl_keydate, //Reporting End Date

    P_SelectedCurrencyBranch       : saft_aa_ro_curr_branch

  as select from I_AssetBalanceCube( P_AssetAccountingKeyFigureSet:     :P_AssetAccountingKeyFigureSet,
                                     P_FiscalYear:                      :P_FiscalYear,
                                     P_FiscalPeriod:                    :P_ToFiscalPeriod,
                                     P_KeyDate:                         :P_KeyDate )                          as Values

  left outer to one join P_RO_SAFTAssetTransacTypeClfn
    on Values.AssetTransactionType = P_RO_SAFTAssetTransacTypeClfn.AssetTransactionType
  {
    @ObjectModel.foreignKey.association: '_CompanyCode'
    key Values.CompanyCode,
    @ObjectModel.foreignKey.association: '_DepreciationArea'
    key Values.AssetDepreciationArea,
    @ObjectModel.foreignKey.association: '_MasterFixedAsset'
    key Values.MasterFixedAsset,
    @ObjectModel.foreignKey.association: '_FixedAsset'
    key Values.FixedAsset,
    @ObjectModel.foreignKey.association: '_Ledger'
    key Values.Ledger,
    @ObjectModel.foreignKey.association: '_FiscalYear'
    key Values.FiscalYear,
    key Values.FiscalPeriod,
    @ObjectModel.foreignKey.association: '_SubLedgerAccLineItemType'
    key Values.SubLedgerAcctLineItemType,
    key Values.AssetAcctTransClassfctn,
    @ObjectModel.foreignKey.association: '_AssetKeyFigure'
    key Values.AssetAccountingKeyFigure,
    @ObjectModel.foreignKey.association: '_AssetKeyFigureSet'
    key Values.AssetAccountingKeyFigureSet,
    key Values.AccountingDocument,
//    key Values.LedgerGLLineItem,

    key Values.TransactionSubitem,
    key Values.DebitCreditCode,

      Values._FixedAsset.AssetClass,
      @ObjectModel.foreignKey.association: '_ChartOfDepreciation'
      Values.ChartOfDepreciation,
      Values.ControllingArea,
//      Values.Country,

//      Values.FinancialManagementArea,

//      @ObjectModel.foreignKey.association: '_FiscalYearVariant'

//      Values.FiscalYearVariant,

//      Values.LedgerFiscalYear,

//      Values.FiscalYearPeriod,

      Values.LedgerGroup,

      Values.GroupMasterFixedAsset,
      Values.GroupFixedAsset,
      @ObjectModel.foreignKey.association: '_AccountingDocumentType'
      AccountingDocumentType,
      Values.AccountingDocumentCreationDate,
      Values.CreationTime,
      Values.PostingDate,
      Values.DocumentDate,
      Values.AssetValueDate,
      @ObjectModel.foreignKey.association: '_AssetTransactionType'
      Values.AssetTransactionType,
      Values.AssignmentReference,
      Values.DocumentItemText,
      Values.ReferenceDocumentType,
      Values.ReferenceDocument,
      Values.LogicalSystem,
      Values.ReferenceDocumentContext,
      Values.IsReversal,
      Values.IsReversed,
      Values.BusinessArea,
      Values.Segment,
      Values.FinancialAccountType,
      Values.Fund,
//      Values.GrantID,

      Values.FunctionalArea,
//      Values.BudgetPeriod,


      //SAFTAssetTransactionType,

      cast( case when P_RO_SAFTAssetTransacTypeClfn.SAFTAssetTransactionType != ''
        then P_RO_SAFTAssetTransacTypeClfn.SAFTAssetTransactionType
           else case when ( Values.SubLedgerAcctLineItemType = '07205'   or    //Ordinary depr. posted periodically

                            Values.SubLedgerAcctLineItemType = '07206' ) and   //Special depr. posted periodically

                            Values.AssetAcctTransClassfctn = '06'
                   then cast( '030' as /ceecv/ro_sa_ast_trans_type )           //Depreciations

                   else P_RO_SAFTAssetTransacTypeClfn.SAFTAssetTransactionType
                end
      end as /ceecv/ro_sa_ast_trans_type preserving type ) as SAFTAssetTransactionType,

      cast( case when P_RO_SAFTAssetTransacTypeClfn.SAFTAssetValueType != ''
        then P_RO_SAFTAssetTransacTypeClfn.SAFTAssetValueType
           else case when ( Values.SubLedgerAcctLineItemType = '07205'   or    //Ordinary depr. posted periodically

                            Values.SubLedgerAcctLineItemType = '07206' ) and   //Special depr. posted periodically

                            Values.AssetAcctTransClassfctn = '06'
                   then cast( '40' as /ceecv/ro_sa_ast_val_type )              //Depreciations

                   else P_RO_SAFTAssetTransacTypeClfn.SAFTAssetValueType
                end
      end as /ceecv/ro_sa_ast_val_type preserving type ) as SAFTAssetValueType,

      AcctgDocIsPostedPeriodically,

     cast( case Values.AssetAccountingKeyFigure //AssetKeyFigureSetSpec.AssetAccountingKeyFigure

              when '0007701500' //Manually Posted Ordinary Depreciation

                then 'N1'
              when '0007701600' //Manually Posted Special Depreciation

                then 'S1'
              when '0007700500'  //Ordinary Depreciation Posted in UJE

                then 'N2'
              when '0007700600'  //Special Depreciation Posted in UJE

                then 'S2'
              else '' end as saft_aa_ro_ast_depr_type ) as AssetDepreciationType,

      Values.DisplayCurrency,
      @Semantics.amount.currencyCode: 'DisplayCurrency'
      Values.AmountInDisplayCurrency,

      @DefaultAggregation:#SUM
      @Semantics.amount.currencyCode: 'DisplayCurrency'
      case when Values.SubLedgerAcctLineItemType = '07000' or Values.SubLedgerAcctLineItemType = '07001' or //Cumulative Acquisition Costs or Cumulative Down Payments

                Values.SubLedgerAcctLineItemType = '07002' or Values.SubLedgerAcctLineItemType = '07003' or //Cumulative Investment Support or Cumulative Revaluation of Acquisition Costs

                Values.SubLedgerAcctLineItemType = '07008' or Values.SubLedgerAcctLineItemType = '07023' or //Cumulative Transfer of Reserves or Revaluation of Acquisition Costs Related to Prior Year

                Values.SubLedgerAcctLineItemType = '07028' or Values.SubLedgerAcctLineItemType = '07040' or //Transfer of Reserves Related to Prior Year or Acquisition Costs, Current Year

                Values.SubLedgerAcctLineItemType = '07041' or Values.SubLedgerAcctLineItemType = '07042' or //Down Payments Related to Current Year or Investment Support, Current Year

                Values.SubLedgerAcctLineItemType = '07043' or Values.SubLedgerAcctLineItemType = '07048' or //Revaluation of Current-Year Acquisition Costs or Transfer of Reserves Related to Current Year

                Values.SubLedgerAcctLineItemType = '07103' or Values.SubLedgerAcctLineItemType = '07108' or //Manually posted Revaluation of RV PY or Manually posted transfer of reseves PY

                Values.SubLedgerAcctLineItemType = '07123' or Values.SubLedgerAcctLineItemType = '07128' or //Manually posted revaluation RV PY in CY or Manually posted transfer of reseves PY in CY

                Values.SubLedgerAcctLineItemType = '07143' or Values.SubLedgerAcctLineItemType = '07148' or //Manually posted revaluation RV CY or Manually posted transfer of reseves CY

                Values.SubLedgerAcctLineItemType = '07203' or Values.SubLedgerAcctLineItemType = '07208'    //Revaluation of CY Acquisition Costs, Posted Periodically or Reserve, Posted Periodically

                then cast( Values.AmountInDisplayCurrency as fis_apcamount)
         else
           cast('0' as fis_apcamount)
         end as AcqnProdnAmtInDspCrcy,

      @DefaultAggregation:#SUM
      @Semantics.amount.currencyCode: 'DisplayCurrency'
      case when Values.SubLedgerAcctLineItemType = '07004' or Values.SubLedgerAcctLineItemType = '07005' or //Cumulative Revaluation of Ordinary Depreciation or Cumulative Ordinary Depreciation

                Values.SubLedgerAcctLineItemType = '07006' or Values.SubLedgerAcctLineItemType = '07007' or //Cumulative Special Depreciation or Cumulative Current-Value Depreciation

                Values.SubLedgerAcctLineItemType = '07024' or Values.SubLedgerAcctLineItemType = '07025' or //Revaluation of Ordinary Depreciation Related to Prior Year or Ordinary Depreciation Related to Prior Year

                Values.SubLedgerAcctLineItemType = '07026' or Values.SubLedgerAcctLineItemType = '07027' or //Special Depreciation Related to Prior Year or Unplanned Depreciation Related to Prior Year

                Values.SubLedgerAcctLineItemType = '07044' or Values.SubLedgerAcctLineItemType = '07045' or //Revaluation of Depreciation Related to Current Year or Ordinary Depreciation Related to Current Year

                Values.SubLedgerAcctLineItemType = '07046' or Values.SubLedgerAcctLineItemType = '07047' or //Special Depreciation Related to Current Year or Unplanned Depreciation Related to Current Year

                Values.SubLedgerAcctLineItemType = '07104' or Values.SubLedgerAcctLineItemType = '07105' or //Manually posted Revaluation of Depreciation PY or Manually posted ordinary depreciation PY

                Values.SubLedgerAcctLineItemType = '07106' or Values.SubLedgerAcctLineItemType = '07107' or //Manually posted special depreciation PY or Manually posted unplanned depreciation PY

                Values.SubLedgerAcctLineItemType = '07124' or Values.SubLedgerAcctLineItemType = '07125' or //Manually posted revaluation Depr PY in CY or Manually posted ordinary depreciation PY in CY

                Values.SubLedgerAcctLineItemType = '07126' or Values.SubLedgerAcctLineItemType = '07127' or //Manually posted special depreciation PY in CY or Manually posted unplanned depreciation PY in CY

                Values.SubLedgerAcctLineItemType = '07144' or Values.SubLedgerAcctLineItemType = '07145' or //Manually posted revaluation Depr CY or Manually posted ordinary depreciation CY

                Values.SubLedgerAcctLineItemType = '07146' or Values.SubLedgerAcctLineItemType = '07147' or //Manually posted special depreciation CY or Manually posted unplanned depreciation CY

                Values.SubLedgerAcctLineItemType = '07204' or Values.SubLedgerAcctLineItemType = '07205' or //Revaluation of Ordinary CY Depreciation, Posted Periodically or Ordinary Depreciation, Posted Periodically

                Values.SubLedgerAcctLineItemType = '07206' or Values.SubLedgerAcctLineItemType = '07207'    //Special Depreciation, Posted Periodically or Unplanned Depreciation, Posted Periodically

                     then cast( Values.AmountInDisplayCurrency as fis_valueadjamt)
         else
           cast('0' as fis_valueadjamt)
         end as ValueAdjustmentAmtInDspCrcy,

         @DefaultAggregation:#SUM
         @Semantics.amount.currencyCode: 'DisplayCurrency'
         case when Values.SubLedgerAcctLineItemType = '07900' or Values.SubLedgerAcctLineItemType = '07940' //Revenue from Asset Sale Related to Prior Year or Revenue Relating to Current Year Acquisitions

               then cast( Values.AmountInDisplayCurrency as fis_retirementrevenueamount)
           else
             cast('0' as fis_retirementrevenueamount)
           end as RetirementRevenueAmtInDspCrcy,
         AcqnProdnCostOnTransIsReset,

    //dummy fields for seamless activation on lower releases

    cast('' as vdm_v_company_code_currency) as CompanyCodeCurrency,
    @Semantics.amount.currencyCode: 'CompanyCodeCurrency'
    cast('0'  as fis_hsl) as AmountInCompanyCodeCurrency,

    // Associations

    _CompanyCode,
    _DepreciationArea,
    _MasterFixedAsset,
    _FixedAsset,
    _Ledger,
    _FiscalYear,
    _SubLedgerAccLineItemType,
    _AssetKeyFigure,
    _AssetKeyFigureSet,
    _ChartOfDepreciation,
//    _FiscalYearVariant,

    _AssetTransactionType,
    _AccountingDocumentType
  }

  where Values.AssetAcctTransClassfctn <> '00' //No balance carry forward items

    and Values.SelectedCurrencyBranch = $parameters.P_SelectedCurrencyBranch