Free Trial

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.

Custom filter not working with more than 2 'AND' conditions

AHymore
6 - Meteoroid

I am trying to filter on 3 'AND' conditions and the custom filter is not working as expected. 

 

!IsNull([`Dec2])
AND !IsNull([Inv #])
AND [Vendor_Site]IN('YES')

 

When I comment out the 3rd condition the filter works as it should. I have tested each condition by themselves and they are working appropriately, it's just when I add a third condition that the filter messes up. 

 

Any thoughts as to why this is occurring and how I can correct it?

8 REPLIES 8
IraWatt
17 - Castor
17 - Castor

Hey @AHymore,

Can you show an example of it not working and what you were expecting? Typically, you would write the above as:

!IsNull([`Dec2])
AND !IsNull([Inv #])
AND [Vendor_Site] = "YES"

But your way should still be fine.

 

Luke_C
17 - Castor
17 - Castor

Hi @AHymore 

 

Can you share some sample data and the expected output? I ran a quick test with some mocked-up data and it seems to be working, but maybe I'm not clear on your expected output.

Felipe_Ribeir0
16 - Nebula

Hi @AHymore 

 

Could you share a sample of the input/expected output? Looking at what you said, i think that you could have some problem with the logic build (what you want the filter to do is not what is written for it to do).

 

Maybe the last sentence should be an OR to give you the expected result?

 

(!IsNull([`Dec2])
AND !IsNull([Inv #]))
OR [Vendor_Site]IN('YES')

pmyers
Alteryx
Alteryx

Mine, too, works as expected with sample data. I'm happy to take a look at the workflow if you can share it.

 

pmyers_0-1667408768910.png

 

AHymore
6 - Meteoroid

Please see example attached! Thank you all for your help!

 

I should also mention that I am using a Crew macro tool (Dynamic Formula) so I cannot separate the 3 expressions as the expression is built in an excel file by the business to allow them autonomy to update as needed as opposed to having to open a request to do it.

Inactive User
Not applicable

.

Felipe_Ribeir0
16 - Nebula

Hi @AHymore 

 

You do not have any rows that match the condition of the formula ( Column Dec2 different of null, Inv # different of null and Vendor_Site equal YES, ALL at the same time).

 

Because of that, none rows passed the filter.

 

Which row do you want to pass the filter? So i can change the formula to do it.

AHymore
6 - Meteoroid

@Felipe_Ribeir0  - You are right. I went back and checked my larger dataset again and it is actually working. I guess I need to add some sort of order of operations or iterative macro along with the crew macro to run it in order.

 

Thanks again for all of your help community!

Labels
Top Solution Authors