cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Hayes3d
Advocate IV
Advocate IV

!IsEmpty for a nested table in collection returns all items

I'm working on an app for on-call from a SharePoint list. The "On Call" column in the list is a multi-select choice field.

 

I tried to pull all of the data into a collection as the data is small and to reduce calls back to the site for filtering. In doing so, that column becomes a table within the collection.

 

Trying to use: Filter(ColTeamMembers,!IsEmpty(ColTeamMembers.'On Call')) returns every row in the collection. I did a CountRows(ThisItem.'On Call') and most of them are a 0. What am I missing?

1 ACCEPTED SOLUTION

Accepted Solutions
RandyHayes
Super User III
Super User III

@Hayes3d 

IsEmpty can be very misleading in these situations.  The reality is that there is information in that column that will make IsEmpty believe there is something there based on how you collect the information.

Your best bet on the filter formula will be something like this:

Filter(ColTeamMembers, CountRows('On Call')<>0)

I hope that is helpful for you.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

View solution in original post

3 REPLIES 3
RandyHayes
Super User III
Super User III

@Hayes3d 

IsEmpty can be very misleading in these situations.  The reality is that there is information in that column that will make IsEmpty believe there is something there based on how you collect the information.

Your best bet on the filter formula will be something like this:

Filter(ColTeamMembers, CountRows('On Call')<>0)

I hope that is helpful for you.

_____________________________________________________________________________________
Digging it? - Click on the Thumbs Up below. Solved your problem? - Click on Accept as Solution below. Others seeking the same answers will be happy you did.
Check out my PowerApps Videos too! And, follow me on Twitter @RandyHayes

View solution in original post

v-yuxima-msft
Community Support
Community Support

Hi @Hayes3d 

 

Do yo test with @RandyHayes 's suggestion?

And do you solve your issue?If yes,please accept it as solution.

 

Best Regards.

Yumia

This worked great Randy!

Helpful resources

Announcements
PA User Group

Welcome to the User Group Public Preview

Check out new user group experience and if you are a leader please create your group

secondImage

Demo Extravaganza is Back!

We are excited to announce that Demo Extravaganza for 2021 has started!

MBAS on Demand

Microsoft Business Applications Summit sessions

On-demand access to all the great content presented by the product teams and community members! #MSBizAppsSummit #CommunityRocks

Power Apps June 2021

June Power Apps Community Call

Don't miss the call this month on June 16th - 8a PDT

Top Solution Authors
Top Kudoed Authors
Users online (61,213)