The other day I had to try and work out how to filter files within a windows server 2008 explorer window. I knew 2008 had some good search features but had never got into using the search other than just typing in filenames or extensions with wildcards
i.e.
- filename.*
- *.jpg
So I started looking into AQS. There are a number of properties you can choose but I need to filter by extension and to not list folders or images. Below is the query I construction
ext: NOT (.rtf OR .doc OR .docx OR .txt OR.xls OR.msg OR .pdf OR.wps OR .xps OR .pub OR .ppt OR.odt) AND type: NOT image AND kind: NOT folders
So
ext: NOT (.rtf OR .doc OR .docx OR .txt OR.xls OR.msg OR .pdf OR.wps OR .xps OR .pub OR .ppt OR.odt)
This part will list all files with extentions
ext:
except with .rtf,.doc ,.docx,.txt,.xls,.msg,.pdf,.wpf,.xps,.pub,.ppt,.odt
NOT (.rtf OR .doc OR .docx OR .txt OR.xls OR.msg OR .pdf OR.wps OR .xps OR .pub OR .ppt OR.odt)
except files of type image.
AND type: NOT image
except folders
AND kind: NOT folders
You can view other available properties here
http://www.microsoft.com/windows/products/winfamily/desktopsearch/technicalresources/advquery.mspx
No comments:
Post a Comment