Conditional Formatting on a second column with hidden columns

Hi there, I am quite new to your product, so I beg your pardon if I am mistaken about what is currently possible.

  1. I believe that conditional formatting requires a constant, rather than e.g. a comparison to another column.

  2. I also believe that it is not possible to hide columns.
    Given this is correct (?) if it was possible to change these I think it would allow considerably greater expression.

For instance, assuming I have a column with rates which have row-specific thresholds (in a separate column), where I want to highlight where a threshold has been reached, I could:
a) Create a column with the diff of the rate and the threshold
b) Hide that column
c) Highlight the rate column conditional on the diff column.

My hunch is that this might be easier to produce than dynamic relations between columns for conditional formatting.

Is it possible that this could be available in the medium term?

Alternatively, if a similar solution already exists, and I’ve missed it, it would be very kind of you to forgive my ignorance and let me know.

Finally, thank you for the great product and project, it greatly simplifies my working life! :slight_smile:

Hi @Simon1
That’s currently not possible. There are some hacky workarounds :slight_smile:

  1. Create a “Custom column” (previous called Custom Field), where you have done the calculation, so that’s the only column you’ll be checking in Conditional Formatting.
  2. I think having the option to also hide a column, besides removing it (as currently possible), would likely just end up in confusion and making it difficult to figure out what’s going on.
    Workaround, add the column to the end of the table and resize the column to almost 0 (still shows like 20px width) and add a prefix of ... to the columns formatting.

If you think it’s too hacky and want it more streamlined, then open a feature request - please create a separate issue for each request, it makes it easier to overview:
https://github.com/metabase/metabase/issues/new/choose

1 Like

Thanks flamber, I’ll give this a shot first! :slight_smile: