P_MaintObjStatusLatestChg

DDL: P_MAINTOBJSTATUSLATESTCHG Type: view COMPOSITE

P_MaintObjStatusLatestChg is a Composite CDS View in SAP S/4HANA. It reads from 1 data source (I_StatusObjectStatusChange_2) and exposes 4 fields with key fields StatusObject, StatusCode.

Data Sources (1)

SourceAliasJoin Type
I_StatusObjectStatusChange_2 I_StatusObjectStatusChange_2 from

Annotations (7)

NameValueLevelField
AbapCatalog.sqlViewName PMNTOBJSTLASTCHG view
AbapCatalog.preserveKey true view
AbapCatalog.compiler.compareFilter true view
ClientHandling.algorithm #SESSION_VARIABLE view
AccessControl.authorizationCheck #NOT_REQUIRED view
VDM.private true view
VDM.viewType #COMPOSITE view

Fields (4)

KeyFieldSource TableSource FieldDescription
KEY StatusObject StatusObject
KEY StatusCode StatusCode
StatusIsInactive StatusIsInactive
StatusObjectStatusChangeNumber
@AbapCatalog:
{ 
  sqlViewName: 'PMNTOBJSTLASTCHG',
  preserveKey: true,
  compiler.compareFilter:true
}
@ClientHandling.algorithm: #SESSION_VARIABLE
@AccessControl.authorizationCheck: #NOT_REQUIRED

@VDM.private: true
@VDM.viewType: #COMPOSITE

define view P_MaintObjStatusLatestChg
  -- Select the highest change number of a status object / code / inactive
  as select from I_StatusObjectStatusChange_2
{
  key StatusObject,
  key StatusCode,
      StatusIsInactive,
      max(StatusObjectStatusChangeNumber) as StatusObjectStatusChangeNumber
}
group by
  StatusObject,
  StatusCode,
  StatusIsInactive
/*+[internal] {
"BASEINFO":
{
"FROM":
[
"I_STATUSOBJECTSTATUSCHANGE_2"
],
"ASSOCIATED":
[],
"BASE":
[],
"ANNO_REF":
[],
"VERSION":0,
"ANNOREF_EVALUATION_ERROR":""
}
}*/