Show no rows UNLESS it matches the search

One of my docs is specifically set up to keep track of my collections in Morrowind, with the biggest table being books/notes/etc. I have the filter set up to show rows that match my search query, but if the search field is blank, it shows all 585 rows. Very frustrating. For now I’m dealing with it by leaving an asterisk in the search field to filter out all rows, but I’d like the filter to automatically do that. I’ve tried a few different formulas but none seem to behave right.

The library as I would like it to behave by default. Note the asterisk I’ve typed to accomplish this. I don’t want to have to do this.

The library as it behaves with a blank search bar. Note the incredibly long scrollbar on the side.

Hi Sierra,

Welcome to Coda! Great to see Coda being applied to the important things in life… :wink:

Would it be possible for you to change the Title column from a text column to a select (or lookup) column?

That should help you overcome the problem.

Regards
Rambling Pete

Hi Pete! You should see the other personal projects I track as well! :laughing:

Hmm, I’m not entirely sure it’s working. I tried both options and neither seem to show up differently. Perhaps sharing the doc would work better for you (or anyone else) to see how my data is structured. What’s the easiest way to do that without borking up my setup?

Hi again @Piet_Strydom,

I managed to finagle the formula without changing the column type! Here’s what I came up with:

If([Search Library Title],thisRow.Title.Matches([Search Library Title]),thisRow.Title.IsBlank())

Works like a charm! Shows nothing if the search field is blank, shows matches if typed in.

Now I can play the game, haha. :stuck_out_tongue:

1 Like

I’ve bookmarked this trick and try it out.

Have you ever played Factorio?

It’s been my game of choice for several years now.

P

1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.