I_MaintNotifCauseCodeGroup is a Basic CDS View that provides data about "Catalog Code Group" in SAP S/4HANA. It reads from 1 data source (qpgr) and exposes 5 fields with key fields InspectionCatalog, InspectionCodeGroup. It has 2 associations to related views.
@AbapCatalog.sqlViewName: 'IPMCAUSECODEGRP'
@AbapCatalog.compiler.compareFilter: true@AbapCatalog.preserveKey: true@ClientHandling.algorithm: #SESSION_VARIABLE@AccessControl.authorizationCheck: #CHECK@EndUserText.label: 'Catalog Code Group'
@VDM: {
viewType: #BASIC
}@ObjectModel.supportedCapabilities:
[ #SQL_DATA_SOURCE, #CDS_MODELING_DATA_SOURCE, #CDS_MODELING_ASSOCIATION_TARGET ]@ObjectModel.representativeKey: 'InspectionCodeGroup'
@ObjectModel.usageType: { serviceQuality: #A, sizeCategory: #S, dataClass: #CUSTOMIZING }@Metadata.ignorePropagatedAnnotations: truedefineview I_MaintNotifCauseCodeGroup asselectfrom qpgr
association [1..1] to I_Inspectioncatalog as _InspectionCatalog
on $projection.InspectionCatalog = _InspectionCatalog.InspectionCatalog
association [1..*] to I_Inspectioncodegrouptext as _Text
on $projection.InspectionCatalog = _Text.InspectionCatalog
and $projection.InspectionCodeGroup = _Text.InspectionCodeGroup
{
@ObjectModel.foreignKey.association: '_InspectionCatalog'
key qpgr.katalogart as InspectionCatalog,
@ObjectModel.text: {
association: '_Text'
}key qpgr.codegruppe as InspectionCodeGroup,
// DB field has three values, but field shall be indicator
// @Semantics.booleanIndicator: true // It is boolean, but we cannot tag it, due to static code check
case qpgr.inaktiv
when ' ' thencast( ' ' as vdm_qm_codegroupisinactive preserving type )
elsecast( 'X' as vdm_qm_codegroupisinactive preserving type )
endas CodeGroupIsInactive,
qpgr.status as CodeGroupStatus,
// qpgr.ersteller as MaintCatalogCodeGroupCreatedBy,
// qpgr.e_datum as MaintCatalogCodeGroupCreatedOn,
// qpgr.aenderer as MaintCatalogCodeGroupChangedBy,
// qpgr.a_datum as MaintCatalogCodeGroupChangedOn ,
// qpgr.inaktiv as MaintCatalogCodeGroupStatus,
// @Semantics.booleanIndicator: true// qpgr.verwendung as MaintCatalogCodeGroupIsUsed,
//Associations
_InspectionCatalog,
_Text
}
where katalogart = '5'
and status = '2'
/*+[internal] {
"BASEINFO":
{
"FROM":
[
"QPGR"
],
"ASSOCIATED":
[
"I_INSPECTIONCATALOG",
"I_INSPECTIONCODEGROUPTEXT"
],
"BASE":
[],
"ANNO_REF":
[],
"VERSION":0,
"ANNOREF_EVALUATION_ERROR":""
}
}*/