I_FunctionalLocationLabel

DDL: I_FUNCTIONALLOCATIONLABEL Type: view COMPOSITE Package: ILOM

Functional Location Label

I_FunctionalLocationLabel is a Composite CDS View (Dimension) that provides data about "Functional Location Label" in SAP S/4HANA. It reads from 1 data source (I_FunctionalLocation) and exposes 5 fields with key field FunctionalLocation. It has 4 associations to related views. Part of development package ILOM.

Data Sources (1)

SourceAliasJoin Type
I_FunctionalLocation I_FunctionalLocation from

Associations (4)

CardinalityTargetAliasCondition
[0..1] I_FlocLabelingState _FlocLabelingState _FlocLabelingState.AlternativeLabelingIsActive = 'X' or _FlocLabelingState.AlternativeLabelingIsActive = ''
[0..1] P_FlocUserLabel _FlocUserlabel _FlocUserlabel.FunctionalLocation = $projection.FunctionalLocation
[0..1] P_FlocPrimaryLabel _FlocPrimaryLabel _FlocPrimaryLabel.FunctionalLocation = $projection.FunctionalLocation
[0..1] I_FuncLocationLabelSearch _FuncLocationLabelSearch $projection.FunctionalLocation = _FuncLocationLabelSearch.FunctionalLocation and $projection.FunctionalLocLabelingSyst = _FuncLocationLabelSearch.FunctionalLocLabelingSyst and $projection.FunctionalLocationLabelName = _FuncLocationLabelSearch.FunctionalLocationLabelName

Annotations (11)

NameValueLevelField
EndUserText.label Functional Location Label view
Analytics.dataCategory #DIMENSION view
VDM.viewType #COMPOSITE view
AbapCatalog.sqlViewName IFUNCLOCLABEL view
AbapCatalog.compiler.compareFilter true view
AccessControl.authorizationCheck #NOT_REQUIRED view
ObjectModel.representativeKey FunctionalLocation view
ClientHandling.algorithm #SESSION_VARIABLE view
ObjectModel.usageType.dataClass #MASTER view
ObjectModel.usageType.serviceQuality #B view
ObjectModel.usageType.sizeCategory #L view

Fields (5)

KeyFieldSource TableSource FieldDescription
KEY FunctionalLocation FunctionalLocation
FuncnlLocUserLabelName _FlocUserlabel FunctionalLocationLabelName
FuncnlLocPrimaryLabelName _FlocPrimaryLabel FunctionalLocationLabelName
_FuncLocationLabelSearch _FuncLocationLabelSearch
_FunctionalLocationText _FunctionalLocationText
@EndUserText.label: 'Functional Location Label'
@Analytics: { dataCategory: #DIMENSION }
@VDM.viewType: #COMPOSITE
@AbapCatalog: { sqlViewName: 'IFUNCLOCLABEL', preserveKey }
@AbapCatalog.compiler.compareFilter: true
@AccessControl.authorizationCheck:#NOT_REQUIRED
@ObjectModel.representativeKey: 'FunctionalLocation'

@ClientHandling.algorithm: #SESSION_VARIABLE
@ObjectModel.usageType.dataClass: #MASTER
@ObjectModel.usageType.serviceQuality: #B
@ObjectModel.usageType.sizeCategory: #L

@Metadata: { allowExtensions, ignorePropagatedAnnotations }
@ObjectModel.supportedCapabilities: [#SQL_DATA_SOURCE]

define view I_FunctionalLocationLabel
  as select from I_FunctionalLocation
  association [0..1] to I_FlocLabelingState       as _FlocLabelingState       on  _FlocLabelingState.AlternativeLabelingIsActive = 'X'
                                                                              or  _FlocLabelingState.AlternativeLabelingIsActive = ''

  association [0..1] to P_FlocUserLabel           as _FlocUserlabel           on  _FlocUserlabel.FunctionalLocation = $projection.FunctionalLocation
  association [0..1] to P_FlocPrimaryLabel        as _FlocPrimaryLabel        on  _FlocPrimaryLabel.FunctionalLocation = $projection.FunctionalLocation

  // Use the calculated Functional Location Label and Labeling System to fetch a raw version of the Functional Location Label which can be used in HANA contains() statement

  association [0..1] to I_FuncLocationLabelSearch as _FuncLocationLabelSearch on  $projection.FunctionalLocation          = _FuncLocationLabelSearch.FunctionalLocation
                                                                              and $projection.FunctionalLocLabelingSyst   = _FuncLocationLabelSearch.FunctionalLocLabelingSyst
                                                                              and $projection.FunctionalLocationLabelName = _FuncLocationLabelSearch.FunctionalLocationLabelName
{

  key  FunctionalLocation,

      // --------------------------------------------------------------------------------------------------

      // Calculate the active Functional Location Label (if available)

      // --------------------------------------------------------------------------------------------------

      cast( case when _FlocLabelingState.AlternativeLabelingStatus = '2' and _FlocLabelingState.AlternativeLabelingIsActive = 'X' then  // 2 = Alternative Labeling is active

            coalesce( coalesce(_FlocUserlabel.FunctionalLocationLabelName, _FlocPrimaryLabel.FunctionalLocationLabelName), FunctionalLocation )
        when _FlocLabelingState.AlternativeLabelingStatus = '3' and _FlocLabelingState.AlternativeLabelingIsActive = '' then // 3 = Alternative Labeling is deactivated

            coalesce(_FlocPrimaryLabel.FunctionalLocationLabelName, FunctionalLocation)
        else          // 1 = Alternative Labeling has never been active (no entries in IFLOS table)

            FunctionalLocation
      end as  ilom_strno    )                       as FunctionalLocationLabelName,

      // --------------------------------------------------------------------------------------------------

      // Calculate the active Functional Location Labeling System (if available)

      // --------------------------------------------------------------------------------------------------

      cast( case when _FlocLabelingState.AlternativeLabelingStatus = '2' and _FlocLabelingState.AlternativeLabelingIsActive = 'X' then  // 2 = Alternative Labeling is active

            coalesce(coalesce(_FlocUserlabel.FunctionalLocLabelingSyst, _FlocPrimaryLabel.FunctionalLocLabelingSyst),'')
        when _FlocLabelingState.AlternativeLabelingStatus = '3' and _FlocLabelingState.AlternativeLabelingIsActive = '' then // 3 = Alternative Labeling is deactivated

            coalesce(_FlocPrimaryLabel.FunctionalLocLabelingSyst,'')
        else          // 1 = Alternative Labeling has never been active (no entries in IFLOS table)

            ''
      end as  ilom_alkey     )                      as FunctionalLocLabelingSyst,

      // For searching purposes

      _FlocUserlabel.FunctionalLocationLabelName    as FuncnlLocUserLabelName,
      _FlocPrimaryLabel.FunctionalLocationLabelName as FuncnlLocPrimaryLabelName,

      // Propagate the raw version version of the Functional Location Label to enable HANA search on the field

      _FuncLocationLabelSearch,
      _FunctionalLocationText
}