Universal Search Operators

There might already be a topic on this—sorry if so!

Universal search is awesome, but I sometimes find it’s a bit too broad. For example, in multiselect mode, I sometimes just want to add a common parent to a slew of cards I recently created. It would be great to have lexical operators for narrowing the search like card:foo, icon:bar, action:baz to restrict results to those relevant to the particular thing I’m looking for. I don’t care too much about the operator syntax, but having something like this would be great!

As always, fantastic work on Supernotes overall! It’s one of the best applications I’ve used in years. Thanks!

3 Likes

So the type of narrowing you’re looking for doesn’t exist, but in case you haven’t seen it there is actually a way to slightly narrow the main search by clicking the icon on the left of the search bar. This toggles between searching cards by everything, title, content, or tags (but actions/commands will always be searched regardless). You can also toggle by pressing the tab button.

Text-based operators are always a bit hard in a search like this one because there is the potential that users want to actually search for whatever operator literal you decide to use (e.g. colons).

1 Like

I actually wasn’t aware of that feature, that helps, thanks @connor!

re: matching on textual operators—yeah I figured as much. It would certainly require escaping support for cases in which a card title etc. used some delimiter, which could get a bit unwieldy.

Giving this another bump as it’d be useful to be able to at least restrict a search to a particular parent, or by creating a collection. I realize this is effectively the same as simply opening the parent and browsing/setting up filters, but I often find myself wanting to jump to a particular card quickly in the global search, just to reference it or see if I’ve created it, without having to switch over to the proper parent and scroll around.

You might want to have a look at the search in view feature.

1 Like

I often find myself wanting to perform a more complex filter/search operation without necessarily creating or saving a custom collection for the search. For example, it’d be great to be able to filter for cards with no parents or cards with a specific parent using collections style JSON syntax as an operator mini language. This would enable you to effectively perform a temporary search/filter with equivalent power. For example, it’d be great to be able to write “parent_count:0” directly in the filter/search input.

(I vaguely recall possibly positing a topic like this before but I didn’t find it with a quick search so my apologies if this ends up being a double post).

I do realize these might have to be a little more restricted than the full collections filtering functionality, but I think even a limited version in which each filter type is limited to a single operation would still be useful. (For example, parent_count might always use equals, or you could use an operator syntax like parent_count=, parent_count<, parent_count~ (this last being for containment))

Hi @solsen,

I think I found your original post and have combined them all together so everything is in one place. We currently rely on a fuzzy search system or as Connor mentioned above you can narrow by clicking the icon in the Universal Search.

The idea of having simple operators has come up a few times over the years, and previously our stance was that fuzzy search generally works really well – if not just use the filters and filter the home. However, we have been experimenting with a more powerful Universal Search with live previews and this would also perhaps be a good time to add simple operators which would switch the search from fuzzy to filtered. So if you used name:idea parent_count:0 this would be an example of a filtered search. You could then also convert this to a filtered Noteboard with these filters. This is still very early days, but we will see what we can do. If anyone else would like this please like @solsen’s original post above.

3 Likes