Action - Show if band name appears under affiliations in another table

I have a table of Bands. I also have a table of “Connections”, which basically is a table of associated contacts for specific bands. The connection references the band name.

I am making an action under the Bands to add a ‘Connection’. I would like this action to ONLY appear on Bands where the Band name appears under the “Affiliation” column in the 'Connections table.

Currently I have
IN(Bands[Band Name],Connections[Affiliation]) But for some reason the expression is valid… seems to make sense… doesn’t do what I want it to… Just shows nothing.

I’ve tried Bands[Band Name]=ANY(Connections[Affiliation]) But I get cannot compare list with name (because Affiliation is a reference to Band Name and as such is a list)

What am I missing here? How can I solve this issue with my logic lol

Thanks everyone for your time!

I am surprised that the IN() statement shows as valid, the first argument should be a single value to be matched. Bands[Band Name] should return a LIST of Band Names making the statement invalid - well now that I think about it, maybe you can check for a list within a list??

Anyway, If you are in an Action for the Bands table you only need [Band Name] so the IN() statement should be like this

IN([Band Name], Connections[Affiliation])

Why? Because the Action is already being processed on a single Bands row. The Action knows from context that you want [Band Name] for the current row you are operating on.


Ah, yes! I did try this. The issue there is that, while it works… It is only working for one record for some reason. I have no idea why… but it only works on that one band… the rest of the records show nothing.

At first I thought it was the first record in the actual table/ spread sheet… But it’s not. It’s like… the 11th record…

Wait somehow it had gotten changed and saved wrong. I just fixed it. your expression works. holy cow. thanks so much!

1 Like

Happy to help!

I suspect the first argument to IN() is converted automatically to a single Text value. For instance, LIST("A", "B", "C") becomes "A , B , C".