I_DefectLocationCodeGroup

DDL: I_DEFECTLOCATIONCODEGROUP SQL: IDEFLOCCODEGRP Type: view BASIC

Defect Location Code Group

I_DefectLocationCodeGroup is a Basic CDS View that provides data about "Defect Location Code Group" in SAP S/4HANA. It reads from 1 data source (qpgr) and exposes 5 fields with key fields DefectLocationCatalog, DefectLocationCodeGroup. It has 2 associations to related views.

Data Sources (1)

SourceAliasJoin Type
qpgr qpgr from

Associations (2)

CardinalityTargetAliasCondition
[1..1] I_DefectLocationCatalog _DefectLocationCatalog $projection.DefectLocationCatalog = _DefectLocationCatalog.DefectLocationCatalog
[0..*] I_DefectLocationCodeGroupText _Text $projection.DefectLocationCatalog = _Text.DefectLocationCatalog and $projection.DefectLocationCodeGroup = _Text.DefectLocationCodeGroup

Annotations (13)

NameValueLevelField
AbapCatalog.sqlViewName IDEFLOCCODEGRP view
AbapCatalog.compiler.compareFilter true view
AbapCatalog.preserveKey true view
ClientHandling.algorithm #SESSION_VARIABLE view
AccessControl.authorizationCheck #CHECK view
VDM.viewType #BASIC view
VDM.lifecycle.contract.type #PUBLIC_LOCAL_API view
ObjectModel.representativeKey DefectLocationCodeGroup view
ObjectModel.usageType.serviceQuality #A view
ObjectModel.usageType.sizeCategory #S view
ObjectModel.usageType.dataClass #CUSTOMIZING view
EndUserText.label Defect Location Code Group view
Metadata.ignorePropagatedAnnotations true view

Fields (5)

KeyFieldSource TableSource FieldDescription
KEY DefectLocationCatalog
KEY DefectLocationCodeGroup
CodeGroupStatus qpgr status
_DefectLocationCatalog _DefectLocationCatalog
_Text _Text
@AbapCatalog.sqlViewName: 'IDEFLOCCODEGRP'
@AbapCatalog.compiler.compareFilter: true
@AbapCatalog.preserveKey: true
@ClientHandling.algorithm: #SESSION_VARIABLE
@AccessControl.authorizationCheck: #CHECK
@VDM: {
    viewType:#BASIC,
    lifecycle.contract.type: #PUBLIC_LOCAL_API
}
@ObjectModel: {
    representativeKey: 'DefectLocationCodeGroup',
    usageType: { serviceQuality: #A, sizeCategory: #S, dataClass: #CUSTOMIZING }
}
@EndUserText.label: 'Defect Location Code Group'
@Metadata.ignorePropagatedAnnotations: true
define view I_DefectLocationCodeGroup as select from qpgr 

    association [1..1] to I_DefectLocationCatalog as _DefectLocationCatalog on $projection.DefectLocationCatalog = _DefectLocationCatalog.DefectLocationCatalog    
    association [0..*] to I_DefectLocationCodeGroupText as _Text on $projection.DefectLocationCatalog = _Text.DefectLocationCatalog and
                                                                    $projection.DefectLocationCodeGroup = _Text.DefectLocationCodeGroup
    
{
    @ObjectModel.foreignKey.association: '_DefectLocationCatalog'
    key cast( katalogart as vdm_qfeocat preserving type )        as DefectLocationCatalog,
    @ObjectModel.text.association: '_Text'
    key cast( qpgr.codegruppe as vdm_qfeogrp preserving type )   as DefectLocationCodeGroup ,
    
    
    // DB field has three values, but field shall be indicator

    @Semantics.booleanIndicator: true
    case qpgr.inaktiv
      when ' ' then cast( ' ' as vdm_qm_codegroupisinactive preserving type )
      else cast( 'X' as vdm_qm_codegroupisinactive preserving type )
    end                                                          as CodeGroupIsInactive,
  
    qpgr.status                                                  as CodeGroupStatus,
  
    //Associations

    _DefectLocationCatalog,
    _Text
  
} where //katalogart = 'B' or //Object Parts

        katalogart = 'E'    //Defect Locations              

 /*+[internal] {
"BASEINFO":
{
"FROM":
[
"QPGR"
],
"ASSOCIATED":
[
"I_DEFECTLOCATIONCATALOG",
"I_DEFECTLOCATIONCODEGROUPTEXT"
],
"BASE":
[],
"ANNO_REF":
[],
"VERSION":0,
"ANNOREF_EVALUATION_ERROR":""
}
}*/