Skip to main content.
home | support | download

Back to List Archive

Re: [swish-e] Grouping Search Results based on directory path

From: Peter Karman <peter(at)not-real.peknet.com>
Date: Mon Apr 27 2009 - 20:26:01 GMT
Chad Kellerman wrote on 04/27/2009 02:45 PM:
> Users -
>       I believe I have a simple problem, but I am having a difficult time
> finding a solution.  I've read through the documentation on the swish-e
> website and the man pages, and either I just read over what I was looking
> for, or it's not in there.
> 
>      Here is a brief description of what I would like to do:
> 
> I am indexing a /export/safe/QA file directory.  In the /export/safe/QA
> directory are about 300 other directories that contain project names.  I am
> using the cgi to do the display of the search.  Sometimes a search will have
> results located multiple times within a project directory as well as in
> multiple project directories.
> 
>    I am looking to sort the results of the search so that the display will
> be grouped by project name (I.E directory)
> 
> Here is my swish-e information:
> ./swish-e -V
> SWISH-E 2.4.6
> 
> my Conf file looks like:
> --------------------------------------<conf>----------------------------------------
> # Tell Swish-e what to index (same as -i switch above)
> IndexDir /export/safe/QA
> 
> NoContents .jar .ear .png .war .gif .tar .zip .dll
> 
> # Tell Swish-e that .txt files are to use the text parser.
> IndexContents TXT* .txt
> 
> # Otherwise, use the HTML parser
> #DefaultContents HTML*
> DefaultContents TXT*
> 
> # Ask libxml2 to report any parsing errors and warnings or
> # any UTF-8 to 8859-1 conversion errors
> ParserWarnLevel 9
> 
> # location of index file
> IndexFile /safe/data/qa.index
> 
> StoreDescription TXT* <body> 200000


sounds like you need ExtractPath and then sort on the path name. Check
the config docs for ExtractPath:

 http://swish-e.org/docs/swish-config.html#extractpath

-- 
Peter Karman  .  peter(at)not-real.peknet.com  .  http://peknet.com/

_______________________________________________
Users mailing list
Users@lists.swish-e.org
http://lists.swish-e.org/listinfo/users
Received on Mon Apr 27 16:26:00 2009