ASP/SQL searching on several directories at once

Results 1 to 2 of 2

Thread: ASP/SQL searching on several directories at once

  1. #1
    Join Date
    Dec 1969

    Default ASP/SQL searching on several directories at once

    I am trying to do an advanced search that will allow the user to select which directories to search but ticking certain checkboxes. The values are then captured using:<BR>request.form("value")<BR><BR>After this, the query us run, and this is where the problem lies. It only one box is selected it searches and returns results. However, I cannot get it to search too directories at once.<BR><BR>The code that I am presently using is:<BR><BR>SQL = SQL & "SCOPE(&#039DEEP TRAVERSAL OF " & QUOT & strScope1 & QUOT & "&#039)" <BR><BR>How would I add the second strScope2 etc to this, so that it will search the second directory.

  2. #2
    Scott S Guest

    Default RE: ASP/SQL searching on several directories at on

    Well, I&#039m not familiar with the syntax that you listed but heres how I would do it. I would write a script that used the File System Object to index all of the pages in the web, have it start in the beginning & then recursively run through all of the directories. For each file that it found it would write that file&#039s location & some information bout it (perhaps the Meta Tags, perhaps the file&#039s content that parts irrelavent) Also for each file entry into our database i would write the directory name, that way when i searched i could very easily specifiy which directories to search ex:<BR><BR>SELECT URL FROM SEARCHDB WHERE CONTENT LIKE &#039%SOMESEARCHTERM%&#039 AND DIRECTORY IN (&#039DIRECTORYONE&#039,&#039DIRECTORYTWO&#039,&#0 39DIRECTORYTHREE&#039)<BR><BR>You could even go as far to allow boolean searching, you&#039d have to parse the Search string & build the query but thats not so hard. (i have some basic examples if you want some)<BR>Hope that helps, <BR><BR>Scott S<BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts