cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Helper I
Helper I

Tablet App not showing all Items filtered by User

Hi,

 

My PowerApp Gallery is showing only one item, when i filter it by the current user. 

Without the filter the gallery shows all items.

 

i am using the following code:

SortByColumns(Filter('Deviation Report'; Author.DisplayName = User().FullName); "Created";Ascending)

and the Author.DisplayName is marked blue, saying 

Part of this filter formula can not be run remotely due to service restrictions

 

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Super User
Super User

Re: Tablet App not showing all Items filtered by User

I think the first step is to figure out why you aren't getting any results and then see if you need to do anything to address the blue dot.

 

The first thing you can do since it is easy is to remove "; StartsWith(ComplianceAssetId; TextSearchBox1.Text)" from the filter to verify the textbox search isn't causing the problem.

 

If you are still having an issue then try adding two labels to your gallery item and update the text property on one to Author.Email and the other to User().Email. Then put the search piece back and remove "Author.Email = CurrentUser.Email;" from the filter, so now it should be returning all items from your list. Once that is done you should be able to use the new labels to compare the actual Author and User email values. It is important to see if they are actually the same.

 

 



--------------------------------------------------------------------------------
If this post helps answer your question, please click on “Accept as Solution” to help other members find it more quickly. If you thought this post was helpful, please give it a Thumbs Up.

View solution in original post

5 REPLIES 5
Highlighted
Super User
Super User

Re: Tablet App not showing all Items filtered by User

The blue dot means your query isn't delegable. By default non-delegable queries are limited to the first 500 rows return by the data source before the query is applied. It is possible to increase the row limit to 2,000. If your list in SharePoint has more than 2,000 items then you are going to need another approach.

 

In SharePoint complex field types (Choice, Lookup, Person/Group, Date and Metadata) aren't delegable but there are functions in PowerApps that also aren't delegable like User(). In your case from the screenshot it looks like you are using both a Person field in SharePoint and the User() function.

 

Here is more information about non-delegable queries and how to increase the limit

PowerApps data row limit for non-delegable queries



--------------------------------------------------------------------------------
If this post helps answer your question, please click on “Accept as Solution” to help other members find it more quickly. If you thought this post was helpful, please give it a Thumbs Up.
Highlighted
Helper I
Helper I

Re: Tablet App not showing all Items filtered by User

thank you for the reply @Jeff_Thorpe,

 

my list is a test List with only 6 Items, so that shouldnt cause the issue.

 

But i am trying to filter my gallery by the current user.

Is there a better way to do this? As right now my gallery either shows only one item or none.

Highlighted
Super User
Super User

Re: Tablet App not showing all Items filtered by User

There is a better way to use User(). What you can do is create a variable in the OnStart or OnVisible of the screen to the value of User(). Example Set(gvCurrentUser, User())

 

Then you would gvCurrentUser in place of User(). This method is more efficient because it only makes one lookup call and then the results can be used anywhere in your code without making another lookup call.

 

Since you only have six items the formula you have should work even with the blue dot. You will want to test and make sure that Author.DisplayName and User().FullName are returning the user's name as expected. You might want to try comparing email addresses instead of Names.

 

Here is a blog post by @Meneghino that talks more about User() function and caching the value.

 

https://baizini-it.com/blog/index.php/2017/08/29/powerapps-user-function-cache-current-user-onstart/



--------------------------------------------------------------------------------
If this post helps answer your question, please click on “Accept as Solution” to help other members find it more quickly. If you thought this post was helpful, please give it a Thumbs Up.
Highlighted
Helper I
Helper I

Re: Tablet App not showing all Items filtered by User

Yes thank you,

 

i had read this article aswell, and i also tried it with the variable.

I still have the same issue.

 

the blue dots under Auther.Email = ; and i still cant see any items.

 

 

SortByColumns(Filter('Deviation Report'; Author.Email = CurrentUser.Email; StartsWith(ComplianceAssetId; TextSearchBox1.Text)); "Created"; If(SortDescending1; Ascending; Descending))

 

 

i checked the data of my record, its all entered correctly.

 

ClearCollect(LocalDeviationReport; 'Deviation Report')

 

I dont understand, why i cant see any filtered items

 

Highlighted
Super User
Super User

Re: Tablet App not showing all Items filtered by User

I think the first step is to figure out why you aren't getting any results and then see if you need to do anything to address the blue dot.

 

The first thing you can do since it is easy is to remove "; StartsWith(ComplianceAssetId; TextSearchBox1.Text)" from the filter to verify the textbox search isn't causing the problem.

 

If you are still having an issue then try adding two labels to your gallery item and update the text property on one to Author.Email and the other to User().Email. Then put the search piece back and remove "Author.Email = CurrentUser.Email;" from the filter, so now it should be returning all items from your list. Once that is done you should be able to use the new labels to compare the actual Author and User email values. It is important to see if they are actually the same.

 

 



--------------------------------------------------------------------------------
If this post helps answer your question, please click on “Accept as Solution” to help other members find it more quickly. If you thought this post was helpful, please give it a Thumbs Up.

View solution in original post

Helpful resources

Announcements
secondImage

Demo-Extravaganza 2020

Check out these cool Power Apps & vote on your favorite!

secondImage

Robotic Process Automation

Let's talk about the solution provided by Microsoft for Robotic Process Automation (RPA)

secondImage

Community Highlights

Check out whats happening in Power Apps

secondImage

Community User Group Member Badges

FIll out a quick form to claim your community user group member badge today!

Top Solution Authors
Top Kudoed Authors
Users online (5,774)