cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Regular Visitor

SOLVED (not a bug) - BUG: Or conditions in Filter statements are throwing an error (started a few days ago)

SOLVED - It turns out, it's not the Or function that's causing the issue, it's that a bit column value that used to be evaluated correctly when standing by itself (e.g., If(IsActive, true, false)) now needs to be written with the '=' sign (e.g., IsActive = true).

 

----------------------------------------------------------------

I have an app that uses Filter statemements in the Items property of some dropdown controls. I have been using Or conditions in the Filter statement successfully for a number of months, but all of a sudden, the controls that had been working are throwing an error. This feels like a bug since it used to work and the MS documentation for using Or conditions in Filter statements hasn't changed recently. I've tried using both the Or function and the || syntax, and they both cause the error. the And function and the && syntax are still working as before.

Here's an example of a statment that was working for the past several months, but now throws an error.

Filter(
Sort(
'[sts].[v_Project]',
Name
),
ClientId = varGlobalSelectedClientId,
Or((IsActive = varGlobalActiveOnly), IsActive)
)

1 ACCEPTED SOLUTION

Accepted Solutions
Community Support
Community Support

Hi @brickt ,

Have you solved your problem?

Could you please show more details about the error message within your app?

 

If you have solved your problem, please go ahead to click "Accept as Solution" to identify this thread has been solved.

 

On your side, please also consisder modify your formula as below:

Filter(
       Sort(
            '[sts].[v_Project]',
             Name
        ),
        ClientId = varGlobalSelectedClientId,
        IsActive = varGlobalActiveOnly ||  IsActive = true
)

Please take a try with above solution, then check if the issue is solved.

 

Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

1 REPLY 1
Community Support
Community Support

Hi @brickt ,

Have you solved your problem?

Could you please show more details about the error message within your app?

 

If you have solved your problem, please go ahead to click "Accept as Solution" to identify this thread has been solved.

 

On your side, please also consisder modify your formula as below:

Filter(
       Sort(
            '[sts].[v_Project]',
             Name
        ),
        ClientId = varGlobalSelectedClientId,
        IsActive = varGlobalActiveOnly ||  IsActive = true
)

Please take a try with above solution, then check if the issue is solved.

 

Best regards,

Community Support Team _ Kris Dai
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Helpful resources

Announcements
New Badges

New Solution Badges!

Check out our new profile badges recognizing authored solutions!

New Power Super Users

Congratulations!

We are excited to announce the Power Apps Super Users!

Power Apps Community Call

Power Apps Community Call: February

Did you miss the call? Check out the Power Apps Community Call here.

Microsoft Ignite

Microsoft Ignite

Join digitally, March 2–4, 2021 to explore new tech that's ready to implement. Experience the keynote in mixed reality through AltspaceVR!

Top Solution Authors
Top Kudoed Authors
Users online (24,280)