Search returns incorrect results

What I did:
Search for notes with the text “Test” in the project “TEST”.
Syntax in the search field:
Test AND \project(TEST)

What happened:
Search also finds 2 notes that do not contain the text “Test”.

What I expected:
The search only finds notes in this project that contain the text “Test”.

Things that might be helpful to know (Agenda version, OS and model, etc):
iOS+iPadOS

So the extra notes you see are from the correct project, but do not have the text “test” in them?

Did those notes have the word “test” in the past?

Does it change anything if you make a small edit to those notes, and wait a minute, then search?

Yes exactly

Did those notes have the word “test” in the past?

I suspect that too. But i don’t remember exactly.
If this is the cause, then it should stop as soon as possible. I created this topic because I keep seeing search results that are not clean. But then it is very difficult to understand the problem.

Does it change anything if you make a small edit to those notes, and wait a minute, then search?

Nothing changes. Not even after 5 minutes.

If you search for the word Test without any qualification (i.e. “all”) in also includes all notes that have a project with the title “test”, which is why those notes show up.

1 Like

If I use the literal matches () or “” in the search, then the result should be identical, right?

Yes, the solution would be to introduce something like:

\note-text(Test) AND \project(TEST)

because right now

Test AND \project(TEST)

translates to:

\all(Test) AND \project(TEST)

and since all includes all searchable properties of a note, including its project title, it will match any note that is in the project TEST.

Ok, thanks for the clarification.

I’m still not quite sure why I get different results when using the literal matches () or “”.
I don’t expect any differences. Look here:

I search for:
(Test) AND \project(Projekt)

and is found:

then I search for:
„Test“ AND \project(Projekt)

and is found:

I am confused by the different results.
I expected that if I specifically search for the word “Text” only, then I would only see notes with the word “Text” highlighted.
Is my logic wrong?

Once again, you assume notes with the word “Text”, this is incorrect, the quotes don’t refer to notes with the word, it refers to the exact search term in the fields being searched. There is currently no qualifier that limits the search specifically to the text of the note, ignoring title, project title etc. So if you type “Test” it currently searches the exact term in all indexed fields which includes the project title.

btw do I correctly assume you are using version 19.0 not the 19.1 beta?

I have the version 19.0

1 Like