Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

CDS DCL Authorization

Former Member
0 Likes
1,177

Hello,

first of all as a Student I am brand new in ABAP and any programming language.

I created a simple ALV-Grid with authority check and it was'nt a big of a deal. Now i try to convert the "old" program into a cds view.

I managed to code the Data Definition and now I stuck with the authorization:

Here the Code from my DCL Source:

@EndUserText.label:'CDS_TEST'
@MappingRole:true
 define role Z_PSP_TEST{
 grant select on Z_PSP
 where(c.werks) =
 aspectpfcg_auth(ZCO_MDP,
 werks,
 actvt='03');
}

My issue now is in line 4: I named the define role the same way I did it with my define view but it says that no unique key was defined for entity

any advise?

greeting Dustin

1 REPLY 1