P_RSHUserStatusBasic

DDL: P_RSHUSERSTATUSBASIC SQL: PRSHUSB Type: view BASIC

P_RSHUserStatusBasic is a Basic CDS View in SAP S/4HANA. It reads from 2 data sources (jest, jsto) and exposes 9 fields with key fields StatusObject, StatusCode, StatusProfile. It has 2 associations to related views.

Data Sources (2)

SourceAliasJoin Type
jest jest from
jsto jsto inner

Associations (2)

CardinalityTargetAliasCondition
[0..1] I_UserStatus _UserStatus _UserStatus.UserStatus = jest.stat and _UserStatus.StatusProfile = jsto.stsma
[0..1] I_StatusProfile _StatusProfile $projection.StatusProfile = _StatusProfile.StatusProfile

Annotations (10)

NameValueLevelField
AbapCatalog.sqlViewName PRSHUSB view
AbapCatalog.compiler.compareFilter true view
AbapCatalog.preserveKey true view
AccessControl.authorizationCheck #NOT_REQUIRED view
VDM.private true view
VDM.viewType #BASIC view
ClientHandling.algorithm #SESSION_VARIABLE view
ObjectModel.usageType.serviceQuality #C view
ObjectModel.usageType.sizeCategory #XL view
ObjectModel.usageType.dataClass #TRANSACTIONAL view

Fields (9)

KeyFieldSource TableSource FieldDescription
KEY StatusObject jest objnr
KEY StatusCode jest stat
KEY StatusProfile jsto stsma
obtyp jsto obtyp
MasterLanguage _StatusProfile MasterLanguage
UserStatusNameSessionLang
UserStatusShortNameSessionLang
_UserStatus _UserStatus
_StatusProfile _StatusProfile
@AbapCatalog.sqlViewName: 'PRSHUSB'
@AbapCatalog.compiler.compareFilter: true
@AbapCatalog.preserveKey: true
@AccessControl.authorizationCheck: #NOT_REQUIRED

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

@ClientHandling.algorithm: #SESSION_VARIABLE
@ObjectModel.usageType: {
  serviceQuality: #C,
  sizeCategory : #XL,
  dataClass: #TRANSACTIONAL
}
/*
CONTRACT*************************************************************************************************************************************

Specification:            The view retrieves the status object of the PM Order or Operation maintained in user logon language, along with all 
                          active user status codes. 
Requires:                 NA
Ensures:                  that only the active user status of the order or operations will be returned
Owners:                   GG
Contributors:               
Unit Test required Y/N:     
Additional comments        None

END OF CONTRACT******************************************************************************************************************************
*/
define view P_RSHUserStatusBasic as select from jest
          inner join jsto on jest.objnr = jsto.objnr 
          association [0..1] to I_UserStatus as _UserStatus on  _UserStatus.UserStatus = jest.stat  
                                                             and _UserStatus.StatusProfile = jsto.stsma 

  association [0..1] to I_StatusProfile as _StatusProfile on  $projection.StatusProfile = _StatusProfile.StatusProfile

{

  key jest.objnr as StatusObject,
  key jest.stat  as StatusCode,
  key jsto.stsma as StatusProfile,
  
    jsto.obtyp,

   _StatusProfile.MasterLanguage,
  
   _UserStatus._UserStatusText[ 1:Language = $session.system_language ].UserStatusName as UserStatusNameSessionLang,
   _UserStatus._UserStatusText[ 1:Language = $session.system_language ].UserStatusShortName as UserStatusShortNameSessionLang,
   
   _UserStatus,

   _StatusProfile

} where jest.inact = '' 
   and  jest.stat like 'E%'
   and (jsto.obtyp = 'ORI' or jsto.obtyp = 'OVG' )
/*+[internal] {
"BASEINFO":
{
"FROM":
[
"I_STATUSPROFILE",
"I_USERSTATUS",
"I_USERSTATUSTEXT",
"JEST",
"JSTO"
],
"ASSOCIATED":
[
"I_STATUSPROFILE",
"I_USERSTATUS"
],
"BASE":
[],
"ANNO_REF":
[],
"SCALAR_FUNCTION":
[],
"VERSION":0,
"ANNOREF_EVALUATION_ERROR":""
}
}*/