Optimize query flags

Plug-in and third party software discussion.
jams
Posts: 11
Joined: Thu Mar 27, 2014 8:36 am

Optimize query flags

Postby jams » Thu Oct 12, 2017 9:22 pm

I the C# wrapper library I'm building I used to set the query flags with almost all options on:

Code: Select all

EVERYTHING_REQUEST_SIZE
| EVERYTHING_REQUEST_FILE_NAME
| EVERYTHING_REQUEST_EXTENSION
| EVERYTHING_REQUEST_ATTRIBUTES
| EVERYTHING_REQUEST_PATH
| EVERYTHING_REQUEST_FULL_PATH_AND_FILE_NAME
| EVERYTHING_REQUEST_DATE_CREATED
| EVERYTHING_REQUEST_DATE_MODIFIED
| EVERYTHING_REQUEST_DATE_ACCESSED
| EVERYTHING_REQUEST_DATE_RUN

I figured out that it was drastically slowing down queries, so I now pick only flags relevant to the query.
But if for example I don't pick EVERYTHING_REQUEST_DATE_MODIFIED then I can't retrieve the modification date through the results.
Do you have any clue on how to optimize the selection of flags for a query and still offer enough information in the results?

And by the way is there any reason why searching for creation date is so slow compared with other date queries?

Thanks,
Julien.

therube
Posts: 1740
Joined: Thu Sep 03, 2009 6:48 pm

Re: Optimize query flags

Postby therube » Thu Oct 12, 2017 11:43 pm

why searching for creation date is so slow compared with other date queries

I could be totally off, but could it be because date created is not indexed where modified / accessed are?
Everything | Options | Indexes -> Index date...

void
Site Admin
Posts: 3606
Joined: Fri Oct 16, 2009 11:31 pm

Re: Optimize query flags

Postby void » Fri Oct 13, 2017 12:32 am

If the requested information is indexed it will be returned instantly.
If the requested information is not indexed it will be gathered before returning (this could take several minutes).

Please check the Everything_IsFileInfoIndexed call (currently undocumented)
Pass the EVERYTHING_IPC_FILE_INFO_* to check if the information is indexed.

Please check the Everything_IsFastSort SDK call (currently undocumented)
Pass the sort type to check if the information is indexed and has fast sort enabled.

void
Site Admin
Posts: 3606
Joined: Fri Oct 16, 2009 11:31 pm

Re: Optimize query flags

Postby void » Fri Oct 13, 2017 1:16 am


jams
Posts: 11
Joined: Thu Mar 27, 2014 8:36 am

Re: Optimize query flags

Postby jams » Sun Oct 15, 2017 8:59 am

Thanks for the addition it will be useful.

About the scenario when the information is not indexed, is the time spent to gather data done on every such query?
And still about index information, in the added methods to your SDK I didn't see anything about ID3 tags and image data (width, height, bpp).

void
Site Admin
Posts: 3606
Joined: Fri Oct 16, 2009 11:31 pm

Re: Optimize query flags

Postby void » Sun Oct 15, 2017 10:16 am

is the time spent to gather data done on every such query?


Yes. I've made a note to keep the SDK reply hwnd open for the next Everything release, this would keep the file information cached between queries.

And still about index information, in the added methods to your SDK I didn't see anything about ID3 tags and image data (width, height, bpp).


This information is not available to the SDK, yet. It will most likely be supported in Everything 1.5.
Currently you can only search for this information.


Return to “Development, plugins and third party software”