I_PPM_AUTHZNBYUSERROLEH

CDS View

Project Authorizations by User Role

I_PPM_AUTHZNBYUSERROLEH is a CDS View in S/4HANA. Project Authorizations by User Role. 2 CDS views read from this table.

CDS Views using this table (2)

ViewTypeJoinVDMDescription
I_EntProjACLByUserRoleRead view inner BASIC Permitted Access by UserRole-ACL with read
I_EntProjElmntUsrRoleRead view from BASIC Permitted Access by UserRole-ACL with read
@AbapCatalog.sqlViewName: 'IPPMAUTHZNUSRRLH'
@VDM.viewType: #BASIC

@AbapCatalog.compiler.compareFilter: true

@AccessControl.authorizationCheck:      #NOT_REQUIRED
@AccessControl.personalData.blocking:   #BLOCKED_DATA_EXCLUDED

@ClientHandling.algorithm:#SESSION_VARIABLE

@ObjectModel: {
   supportedCapabilities: [ #CDS_MODELING_ASSOCIATION_TARGET ],
   modelingPattern: [ #NONE ],
   usageType: {
       serviceQuality:  #A,
       dataClass:       #MIXED,
       sizeCategory:    #L
   }
}
@Metadata.ignorePropagatedAnnotations: true
@VDM.lifecycle.contract.type:  #PUBLIC_LOCAL_API
@EndUserText.label: 'Project Authorizations by User Role'
//PPM Object Authorization for a user by role assignment inclduing inherited authorizations


define view I_PPM_AuthznByUserRoleH 
as select from  aco_role  as RoleAuth
      // get all inherited authorizations  by join with table containing all inherited_from objects

    inner join /s4ppm/auth_ref  as hier on RoleAuth.object_id = hier.inherited_from
    inner join agr_users as UserRole 
            on      RoleAuth.role_id    = UserRole.agr_name
             and    UserRole.exclude    = ''
             and    UserRole.from_dat  <= $session.system_date
             and    UserRole.to_dat    >= $session.system_date
    
// with reference user support we need something like this    

//    left outer join agr_users as UserRole 

//            on      RoleAuth.role_id    = UserRole.agr_name

//             and    UserRole.exclude    = ''

//             and    UserRole.from_dat  <= $session.system_date

//             and    UserRole.to_dat    >= $session.system_date

//    left outer join Agr_Users_Usrefus as RefUserRole

//            on      RoleAuth.role_id    = RefUserRole.role_name

//             and    RefUserRole.valid_from  <= $session.system_date

//             and    RefUserRole.valid_to    >= $session.system_date            

  {
  
    key hier.object_id      as ReferencedObjectUUID,
    key RoleAuth.activity   as Activity,
    key UserRole.uname      as UserID,
//    key RefUserRole.user_name as UserID1,

    key RoleAuth.role_id    as AuthorizationRoleID,
        hier.object_type    as ObjectType
  
  }

/*+[internal] {
"BASEINFO":
{
"FROM":
[
"/S4PPM/AUTH_REF",
"ACO_ROLE",
"AGR_USERS"
],
"ASSOCIATED":
[],
"BASE":
[],
"ANNO_REF":
[],
"VERSION":0,
"ANNOREF_EVALUATION_ERROR":""
}
}*/