@AbapCatalog:{
sqlViewName: 'PCSGRPSTR',
compiler.compareFilter: true,
preserveKey: true
}
@AccessControl.authorizationCheck: #NOT_REQUIRED
@Metadata:{
ignorePropagatedAnnotations:true
}
@ClientHandling.algorithm: #SESSION_VARIABLE
@ObjectModel: {
usageType: {
dataClass: #MASTER,
serviceQuality: #B,
sizeCategory: #S
}
}
@VDM:{
viewType: #BASIC,
private: true
}
@EndUserText.label: 'Consolidation Group Structure'
/*+[hideWarning] { "IDS" : [ "CALCULATED_FIELD_CHECK" ] } */
define view P_CnsldtnGroupStructure
as select from fincs_grpstr as _Source
inner join I_CnsldtnVersion as _CnsldtnVersionJ on _CnsldtnVersionJ.ConsolidationStructureVersion = _Source.strvs
association [1..1] to I_CnsldtnVersion as _CnsldtnVersion on $projection.ConsolidationVersion = _CnsldtnVersion.ConsolidationVersion
association [1..1] to I_CnsldtnGroup_3 as _CnsldtnGroup on $projection.ConsolidationGroup = _CnsldtnGroup.ConsolidationGroup
association [1..1] to I_CnsldtnUnit_4 as _CnsldtnUnit on $projection.ConsolidationUnit = _CnsldtnUnit.ConsolidationUnit
association [0..*] to I_CnsldtnGroupStrucMethAssgmt as _CnsldtnGroupStrucMethAssgmt on $projection.ConsolidationGroup = _CnsldtnGroupStrucMethAssgmt.ConsolidationGroup
and $projection.ConsolidationUnit = _CnsldtnGroupStrucMethAssgmt.ConsolidationUnit
and $projection.ConsolidationVersion = _CnsldtnGroupStrucMethAssgmt.ConsolidationVersion
and $projection.GroupStrucFromFiscalYearPeriod = _CnsldtnGroupStrucMethAssgmt.GroupStrucFromFiscalYearPeriod
//association for setting determination
//--> must not be exposed
association [0..1] to I_CnsldtnInvmtUtilznSetting as _CnsldtnInvmtUtilznSetting on _Source.dimen = _CnsldtnInvmtUtilznSetting.ConsolidationDimension
{
@ObjectModel.foreignKey.association: '_CnsldtnGroup'
key cast(_Source.congr as fincs_consolidationgroup preserving type ) as ConsolidationGroup,
@ObjectModel.foreignKey.association: '_CnsldtnUnit'
key cast(_Source.bunit as fincs_consolidationunit preserving type ) as ConsolidationUnit,
@ObjectModel.foreignKey.association: '_CnsldtnVersion'
key _CnsldtnVersionJ.ConsolidationVersion,
@Semantics.fiscal.yearPeriod: true
key cast(_Source.fromyearper as fincs_groupstrucfromfyp ) as GroupStrucFromFiscalYearPeriod,
@Semantics.fiscal.yearPeriod: true
cast(_Source.toyearper as fincs_groupstructofyp ) as GroupStrucToFiscalYearPeriod,
cast(_Source.fyear as fincs_yearoffirstconsolidation preserving type ) as YearOfFirstConsolidation,
cast(_Source.fperi as fincs_periodoffirstcnsldtn preserving type ) as PeriodOfFirstConsolidation,
cast( concat(_Source.fyear,_Source.fperi ) as fincs_firstcnsldtnfyp ) as FirstCnsldtnFiscalYearPeriod,
cast(_Source.feflg as fincs_firstcnsldtnatendofperd preserving type ) as FirstCnsldtnIsAtEndOfPeriod,
cast(_Source.lyear as fincs_yearofdivestiture preserving type ) as YearOfDivestiture,
cast(_Source.lperi as fincs_periodofdivestiture preserving type ) as PeriodOfDivestiture,
cast( concat(_Source.lyear,_Source.lperi ) as fincs_divestiturefyp ) as DivestitureFiscalYearPeriod,
cast(_Source.lbflg as fincs_divestitureatbeginofperd preserving type ) as DivestitureIsAtBeginOfPeriod,
cast(' ' as fincs_investmentmethod preserving type ) as ConsolidationMethod, //obsolete field --> moved to dedicated method assignment dependency type
cast('' as fincs_accountingtechnique preserving type ) as AccountingTechnique, //obsolete field --> moved to dedicated method assignment dependency type
//only enable setting in case merger activities are allowed by the customizing
cast(
case
when _CnsldtnInvmtUtilznSetting.CnsldtnMergerActiesAreAllowed is not initial
then _Source.lmergerflg
else ''
end as fincs_divestitureduetomerger preserving type ) as DivestitureIsDueToMerger,
@UI.hidden: true
_Source.etag as ETag,
/* Associations */
_CnsldtnVersion,
_CnsldtnGroup,
_CnsldtnUnit,
_CnsldtnGroupStrucMethAssgmt
}
where
_Source.dimen = 'Y1'
/*+[internal] {
"BASEINFO":
{
"FROM":
[
"I_CNSLDTNINVMTUTILZNSETTING",
"I_CNSLDTNVERSION",
"FINCS_GRPSTR"
],
"ASSOCIATED":
[
"I_CNSLDTNGROUPSTRUCMETHASSGMT",
"I_CNSLDTNGROUP_3",
"I_CNSLDTNINVMTUTILZNSETTING",
"I_CNSLDTNUNIT_4",
"I_CNSLDTNVERSION"
],
"BASE":
[],
"ANNO_REF":
[],
"SCALAR_FUNCTION":
[],
"VERSION":0,
"ANNOREF_EVALUATION_ERROR":""
}
}*/