Page 1 of 1

[Search] Prevent search from starting as soon as one character is typed

Posted: Sat Jul 07, 2018 3:38 pm
by Clairvaux
If I understand correctly, search begins as soon as one types a single character in the search field. This has the advantage of speeding up search, up to a point : since it starts before one finishes typing, the final result is displayed sooner.

Unless, that is, a certain threshold of database size has been reached, at which point search gets slower. I have now 6 800 notes in a single database, and search is painfully slow and clumsy, because in many cases, there is a very perceptible delay between typing one character, and seeing it displayed in the search field. It goes thus :

Type character 1 of your search string, wait, see it appear on the screen. Type character 2, wait, see it appear on the screen.

If you speed-type 2 or 3 keywords one after the other, as is customary, you'll be typing most of your characters blindly, probably getting some of them mistyped in the process, and having to begin all over again. You'll also need to wait again while deleting, and so on.

Since a successful search usually takes a few different attempts, with different keyword combinations, this is a major pain.

Ideally, of course, there should be a way for the software to switch automatically between non-delayed search when the database is small, and delayed search when it has grown too big.

But being able to prevent the search from starting before the whole search string has been typed, and visually checked, is a necessity, in my opinion.

I can envision different ways this could be achieved :

  1. Search does not start before you hit an OK button.
  2. Ditto, but you can switch between immediate search start and OK'd search in Preferences.
  3. The search field is buffered, and search starts after x millisecs of non-typing. Possibly adjustable.
  4. The program detects by itself when the database grows too big, and automatically switches between immediate search start and OK'd search.

I suppose n°2 would be best and simpler, since the user would have to change his setting once per database, after reaching the critical size.

(My system : AMD Athlon II X4 640, 4-core, 3 GHz processor, 4 GB RAM.)

Re: [Search] Prevent search from starting as soon as one character is typed

Posted: Mon Jul 09, 2018 11:15 am
by CintaNotes Developer
Hi and thanks for raising an important question.

In plans for version 4, we already have improvement in this area - namely your No. 3. Search will start only after some msecs of non-typing.
Also we have plans to make search non-blocking (the UI won't freeze).
Hopefully this solution will fit the bill for you!

Also, here are some tips to make search faster:
1) Make sure "search inside words" is OFF. When this option is on, full text index can't be used.
2) Consider splitting your 6000+ notes into several sections.
3) Move CN database to an SSD drive if possible and not already there.

Re: [Search] Prevent search from starting as soon as one character is typed

Posted: Mon Jul 09, 2018 1:30 pm
by Clairvaux
Thank you. I suppose non-blocking search means it will be going on in the background, while added search characters will display instantly ? That would offer the biggest advantage compared to the present situation, I think.

Of course, the best remedy would be for search to be as fast as in the mysteriously fast Everything, which can retrieve anything on a Windows system instantly (provided the keywords are in the file name). But I suppose this is an exception.

Some added info on my setup :

  • Search inside words and across files boundaries is not activated.
  • No SSD here for the moment, unfortunately.
  • I have several databases and several tabs, but the 6800 notes figure actually pertains to the main tab of my main database only. I add to this figure daily, and the whole point of the way I use CN is to be able to search within this blob of 6800 + notes. Other tabs and databases (which are much smaller), I can search separately by virtue of the way they are classified.
  • My main database, the one which has the main tab with 6800 notes, is only 100 MB large -- I believe this is small, as far as databases go.

Re: [Search] Prevent search from starting as soon as one character is typed

Posted: Mon Jul 16, 2018 2:59 pm
by CintaNotes Developer
Thanks for the extra info.
I think that when we add a delay and make search non-blocking, the problem should be solved 100%.