Application Type


There is a overview table in the screen. There are many doctors. Each doctor can see his own requests in the overview table once he logs in. There is a super user who can see all the requests of all the doctors. Suppose, there are 2 doctors. First doctor has 5 requests and 2nd doctor has 3 requests. Now super user should see total 8 requests. How to put a filter condition for this in the aggregate?

Each request should have doctor's information and you filter by that information. If it is a super user you don't use that filter. Something like this in aggregate: If(isSuperUser, true, doctorId = getUserId())

Hello, in your condition we should use "or"

requests .doctorId = GetUserId() or Check_Adimin_role()


You can do one thing you can provide the roles in the database and according to that roles and user id you can use if condition to access as per the roles.

Thanks and Regards,

Vibhor Agarwal


Hi @Gayathri Gali ,

You should fetch data according to roles for example check user login first if it's doctor then fetch request by that perticular doctor id and if it's super user then fetch all the requests. 

By doing this you no need to use any case condition on screen level



Hello Gayathri,

You have to retrieve logged-in user role first then you can use that in your aggregate.

Step1: Check user role if admin, using Data fetch action(just check for Admin role):


Now, your aggregate filter condition should be like this:

Overview.DoctorId = GetUserId() OR IsAppAdmin

Best Regards.

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.