cancel
Showing results for 
Search instead for 
Did you mean: 

Properly filter SharePoint Yes/No column.

There is a well known "bug" when working with SharePoint list Yes/No column :

The Yes/No value can not be compare to boolean type true/false. 

 

Filter(SPList,YesNoColumn = true) will not return all the items with a Yes value .

 

The workaround is to use 1 or 0:

Filter(SPList,YesNoColumn = 1)

This will return all items with a true value, but the designer shows an error because we are comparing a boolean to a number. 

 

It would be great to fixe that, as a Yes/No column is indeed a boolean value, we need to be able to compare that to a boolean value in PowerApps. 

 

Théo

Status: New

Apologies resetting this status. Adding @GregLi and @Emma to update with accurate status. Both TopShelf ad Audrie-MSFT are not longer able to provide an update for Power Apps ideas. @GregLi & @Emma please provide inputs and/or comments. Thank you.

Comments
Frequent Visitor

How is it that the request is from 2018

Two years after, we are the 6 January 2021

 

And... 

SharePoint list Yes/No column (checkbox type)  :

The Yes/No value STILL cannot be compare to Boolean type true/false

 

Is there a planned estimated date to resolve this ?

Thanks

 

The work around seems to work but with error:

The workaround is to use 1 or 0:

Filter(SPList,YesNoColumn = 1)

This will return all items with a true value, but the designer shows an error because we are comparing a boolean to a number. 

 

It would be great to fixe that, as a Yes/No column is indeed a boolean value, we need to be able to compare that to a boolean value in PowerApps. 

 

Super User III

@Ritoxik 

Actually the workaround on it is just to use the following:

Filter(SPList,YesNoColumn)

This will return all records where the YesNoColumn is true.


What you still cannot do is the opposite of that...to get all items where the value is false.  Even using the 0 as you mention is problematic.

 

After all these years, we've just gotten used to it and always provide a numeric or text column to replace the boolean.

 

I believe the delay in getting this to actually be fixed is that there is currently sufficient workaround for it.

Helper I

still not fixed, disgraceful really.