Help

Re: Simple conditional work does not work, does anyone know why?

Solved
Jump to Solution
279 0
cancel
Showing results for 
Search instead for 
Did you mean: 

I have two rollup field I need to evaluate and for some reason I can't get it to work.

Field1: {rollupStockMinimum}

Field2: {rollupNonStockMinimum}

Field1 is empty, but Field2 is not.

I only want the formular to do something when there are something in both fields.

I've tried with this very simple formular

 

 

IF(AND(Field1, Field2), True, False)

 

 

 Screenshot 2024-04-07 at 17.00.06.png

However for some reason it evaluates to 'True' despite Field1 being empty

Screenshot 2024-04-07 at 16.59.18.png

I've tried to just do IF(Field1, "True", "False") where it evaluates to False.

What is it I'm missing or don't understand?

2 Solutions

Accepted Solutions
TheTimeSavingCo
18 - Pluto
18 - Pluto

Try doing this instead:

AND(
  {Field1} != "",
  {Field2} != ""
)

Seems to work

Screenshot 2024-04-08 at 10.15.21 AM.png

 

See Solution in Thread

AlliAlosa
10 - Mercury
10 - Mercury

 

For rolling up text, I usually use something like

ARRAYJOIN(ARRAYCOMPACT(ARRAYUNIQUE(values)))

ARRAYCOMPACT() will get rid of any null values, and ARRAYJOIN() converts the whole thing into a string. Using only ARRAYUNIQUE() might make the field appear empty, but under the hood it’s actually an array of an empty value, which - confusingly enough - counts as a non-empty value in a rollup field’s result.

See Solution in Thread

7 Replies 7

Can you share what rollup you're using?

TheTimeSavingCo
18 - Pluto
18 - Pluto

Try doing this instead:

AND(
  {Field1} != "",
  {Field2} != ""
)

Seems to work

Screenshot 2024-04-08 at 10.15.21 AM.png

 

Just an ArrayUnique with a filter. I wonder if the filter some has anything to do with it?

No sure why I didn't think about that 😁 works, thank you. Still wondering why the other don't work though?

AlliAlosa
10 - Mercury
10 - Mercury

 

For rolling up text, I usually use something like

ARRAYJOIN(ARRAYCOMPACT(ARRAYUNIQUE(values)))

ARRAYCOMPACT() will get rid of any null values, and ARRAYJOIN() converts the whole thing into a string. Using only ARRAYUNIQUE() might make the field appear empty, but under the hood it’s actually an array of an empty value, which - confusingly enough - counts as a non-empty value in a rollup field’s result.

omg thank you @AlliAlosa - I was trying to distill the same thing without having had enough and it was all "sometimes empties aren't really empties because they're arrays of empties which rollups sees as fulls (maybe because the rollups haven't had enough coffee either)" and fortunately you posted before I clicked send on my barrel of word-nonsense. 😂😂

Ahh makes a lot of sense... Thank you for your explanation