Jump to content

I thought I understood search syntax...


Go to solution Solved by John in Michigan USA,

Recommended Posts

...but now I find that tag:".Trigger*" -notebook:"Completed/Done" returns no hits. Expected to see all my notes tagged ".Trigger" except for the ones in the Completed/Done notebook. There are 28 notes that should have matched this search string, and 6 that would be excluded.

Since -tag:"<tag>" works as expected, I guess someone ran out of coffee and never implemented -notebook:"<notebook>"

Tried work-arounds using AND, NOT, OR and () but no joy. I assume I need to upgrade EN, which in turn requires upgrading my Win 7...well that's in the pipeline but for now, if anyone knows of a work-around that works on EN <= 6.25.1 it would be a great help!

Link to comment
  • Level 5*

I'm pretty sure if not certain that -Notebook searches never worked in pre V10 EN.  If they appeared to work for you in the past it may have been because there were no notes with the tag trigger in that notebook at the time.  Fix to this in the past was to have the Complete/Done notebook not be in a stack with the active notebooks containing trigger tags.

  • Like 1
Link to comment
10 hours ago, John in Michigan USA said:

...but now I find that tag:".Trigger*" -notebook:"Completed/Done" returns no hits.

I think the problem is the quotation marks around the tag name. It may be looking for a literal *. You only normally need quotation marks if there is a space in your tag or notebook name. When I tried it (admittedly on V10) I got no hits when I incliuded quotation marks and the expected hits when I didn't.

Link to comment
  • Level 5

I second the idea the problem is in the tag string.

Just tried with "ticket" as search string, followed by -notebook:"@ 📥 Inbox". I have to put the quotation marks, because I have decorated my notebooks with these icons. It finds nearly 300 notes when I only search for the "ticket", and less than 200 when I add the "-notebook" term. Once the -notebook is added all the notes that are still in my inbox won't show in the search any more. If I try and take the "-" away, it finds only notes in the inbox with the "ticket" term.

The notes count of the 3 searches add up exactly: -notebook + notebook = total notes

The implementation looks sound to me, and is working in v10.38 Mac direct download.

Link to comment

For me on V10 Windows desktop

tag:+* -notebook:AllMyNotes

Gives me the correct results. ie those notes with tags starting with + and not in the AllMyNotes notebook. But

tag:"+*" -notebook:AllMyNotes

gives no results as I don't have any tags literally tagged "+*"

Reading the original post again I am not clear why the OP even included a * in the search string if all he wants is notes tagged with .Trigger.

I also am not sure that the -notebook: syntax worked pre V10.

Link to comment
  • Level 5*
15 hours ago, PinkElephant said:

No idea for Windows legacy. In Mac legacy, it does NOT work. Adding -notebook:mynotebook does not result in zero, but it results in a way too small number of hits.

But it does work in EN v10.

- notebook is new to V10, never did work in pre V10 Windows.

  • Like 1
Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...