DawMatt 1 Posted January 27, 2015 Posted January 27, 2015 Hi All, I've run into an issue where an advanced search works perfectly on Mac and Android, and adequately on iOS but fails on Windows. I was hoping for some advice on how to resolve or work around this issue. Issue:I have a notebook for my todo items and active projects I'm completing. Active projects have a Project Definition whose subject is prefixed with "PD". Todo items that are to be done later have their "Updated"" date set to the day they become relevant. I keep a shortcut to a saved search that shows only the current todo items (not the PDs or future tasks) This saved search only works on some platforms. Steps:1) Create a notebook called _Actions.2) In the _Actions notebook create three notes. First called "PD: Test", second called "Current Task Test", third called "Future Task Test" and set its updated date/time to two or more days into the future.3) Create a saved search with the following criteria:notebook:"_Actions" -intitle:PD -updated:day+14) Add the saved search to your Shortcuts5) Open the shortcut to the search Expected Results:On all platforms, the shortcut should execute a search that returns only the note "Current Task Test". Actual Results:On Mac, the shortcut returns only the note "Current Task Test".On Android, the shortcut returns only the note "Current Task Test".On iOS 8, the shortcut returns only the note "Current Task Test". Please note If I exclude the "-updated:day+1" it still returns only this one note, when it should actually return both test tasks, so it isn't working 100% as expected.On Windows, the shortcut returns nothing. During experimentation I found that it would return any of my current todo items that contained the digit "1" in its bodyUPDATED 27/1/2015:On Evernote Web, .the shortcut returns either a "Communication Error" dialog or does nothing. Other search shortcuts work fine and other saved searches work fine, but this saved search and saved search shortcut fails. Any suggestions on how to resolve this issue, or at least to work around it? I know it sounds odd to be working across 4 platforms but I do actually use Evernote on all of these every day and this issue is impacting my workflow. Particularly at work (the Windows system). Thanks,Matt
Level 5* jefito 5,598 Posted January 27, 2015 Level 5* Posted January 27, 2015 The "day+1" bit on date terms doesn't work in the Windows client; that's been long established. The formal search grammar (see https://dev.evernote.com/doc/articles/search_grammar.php#Date_Time_Arguments) doesn't appear to support the '+' operator in relative dates, so that may be a reflection of the "correct" behavior, but I don't know that for sure, or when the Windows client goes to the API for search results (maybe never, and all operations are performed locally). Never tried to dig that deep to find out. Tip: on WIndows, use the Search Explanation to see what the WIndows client thinks its filter actually is (View / Show Search Explanation). Anyways, I've long thought that '+' makes a lot of sense since in practice, Evernote users were hijacking the created date to implement 'to-do' functionality, but since reminders came into being, it seems as though '+' should be a necessity. Edit: Note that the Search Grammar page does mention use of '+' with respect to Reminder dates, so it's inconsistent with the formal search grammar presented below, unfortunately.
DawMatt 1 Posted January 27, 2015 Author Posted January 27, 2015 The formal search grammar (see https://dev.evernote.com/doc/articles/search_grammar.php#Date_Time_Arguments) doesn't appear to support the '+' operator in relative dates, so that may be a reflection of the "correct" behavior, ...Edit: Note that the Search Grammar page does mention use of '+' with respect to Reminder dates, so it's inconsistent with the formal search grammar presented below, unfortunately.Thanks for responding. The grammar does seem to indicate positive dates are unsupported, but the examples on the same page do create uncertainty. As you've noted the addition of reminders makes this a much more pressing problem. It seems like replacing the:| relative , "-" , { digit }line with:| relative , "-" , { digit }| relative , "+" , { digit }would resolve the grammar issue though the code would still need to be updated to support the change. Some of the platforms already support - not sure what is necessary to help Windows and the web client to support it as well. Another option would be if they created some specific representations for common relative dates. e.g. yesterday, tomorrow, lastweek, nextweek. This would satisfy the more common use cases but it would seem like supporting the "+" operator would be more flexible and simpler from a coding and documentation stand point. Especially since many of the platforms already support the operator. Thanks, Matt
Level 5* jefito 5,598 Posted January 27, 2015 Level 5* Posted January 27, 2015 Here's my guess at what's happening: * The search grammar as documented is incorrect; '+' actually is supported in the Evernote API (e.g. on the servers). They should fix the documentation, as the remindertime portion plus the empirical evidence of other clients clearly imply that it's valid (not to mention the commonsense notion that searching for reminders in the future would be a good thing ) * The search string parsing is not properly implemented on the Windows client; note how the Search Explanation shows a misinterpretation of search, using the '1' as a text term (consistent with your results). They should fix that.
DawMatt 1 Posted January 28, 2015 Author Posted January 28, 2015 I like your thinking, Jeff! After posting this thread I discovered how to log a bug report. I've done that as well (linking to this forum thread) so I hope they will look into this. Matt
Recommended Posts
Archived
This topic is now archived and is closed to further replies.