Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Accessing catalogs in ASP pages

0 views
Skip to first unread message

David Samson

unread,
Nov 26, 2001, 3:59:41 PM11/26/01
to
Hi there,

First of all, here's the context: Win 2000 platform, IIS
5.0, ASP files using Visual Interdev and whichever version
of index server that comes with Win 2000.

I created catalog named "Intranet" in Index Server,
pointing to an existing local directory, to which I added
a new directory called "man_sous_auto" pointing
explicitely to a subdirectory of the "intranet" catalog.

I would like to access this catalog from within my ASP
files. Since this is all new to me, I based myself on ISS
5.0 sample code (the famous query.asp page!) and tried to
make it work, without success as of now, with
my "intranet" catalog.

Here's the code i'm working on:

set Q = Server.CreateObject("ixsso.Query")
set util = Server.CreateObject("ixsso.Util")
Q.Query = CompSearch
Q.SortBy = "rank[d]"
Q.Columns = "DocTitle, vpath, filename, size, write,
characterization, rank, path"
Q.MaxRecords = 300

util.AddScopeToQuery Q, "/Intranet/man_sous_auto/", "deep"

Q.LocaleID = util.ISOToLocaleID("EN-US")

set RS = Q.CreateRecordSet("nonsequential")

When this piece of code is executed, just after the set RS
= Q.CreateRecordSet("nonsequential") instruction, both
RS.BOF and RS.EOF are true; meaning no results were found.

What exactly am I doing wrong? I'm pretty sure that my
catalog is correctly set up in Index Server since if I
interrogate it from within Index Server itself, I do get
valid results.

Help!!! :o)

David Samson

scott

unread,
Nov 27, 2001, 5:39:44 AM11/27/01
to
Can't seem to see it in your code, but did you declare your catalogue?

Q.Catalog = "<catalogue name>"

Then make sure it is running in the Index Server MMC and pointing to
the correct website.


Scott.

"David Samson" <david....@ssqgenerale.com> wrote in message news:<003101c176bd$44750220$37ef2ecf@TKMSFTNGXA13>...

David Samson

unread,
Nov 27, 2001, 10:20:52 AM11/27/01
to
Thanks for the Q.Catalog hint Scott as it now partially
works.

I say partially since I do not seem to be able to access
any sub-index of my catalog if I may say. That is, I
created a catalog named "Intranet" which points at the
root directory of my web site. I then created what they
call a directory under the Intranet catalog,
call "man_sous_auto", which points to a folder within my
web site.

Now, I would like to use that sub-directory of my catalog
instead of using the entire web site index. I saw on some
code samples that the use of the function

util.AddScopeToQuery Q, "/Intranet/man_sous_auto", "deep"

should "solve" this sort of dilema; unfortunately it does
not seem to work.

Anyone has a hint as to what I might be doing wrong?

Thanx,

David

>.
>

Randy

unread,
Nov 28, 2001, 12:05:40 AM11/28/01
to
Not sure if I follow what you're doing , but I'll take a stab. First you
state that you've created a catalog called intranet that is built on the
root directory of your web site. Then you have a folder within? that web
called man_sous_auto? If that folder is within the web site (and the web
site in general is indexed) and the folder is indexed (property sheet for
the folder within the MMC) you should be able to get results by specifying
your directory like this:

util.AddScopeToQuery Q, "/man_sous_auto", "deep"

you shouldn't have to create any additional catalogs that I am aware of. the
line above assumes the folder within the web site is named "man_sous_auto".
if it is something else change the line accordingly

HTH

Randy

"David Samson" <david....@ssqgenerale.com> wrote in message

news:182f01c17757$19d62810$b1e62ecf@tkmsftngxa04...

scott

unread,
Nov 28, 2001, 5:17:04 AM11/28/01
to
As you might have already found out, getting Index Server to work as
you want is *very* fiddly and you have to tweak it here and there.

In the .asp code I used a FormScope variable

FormScope = "/"

Which is the same as your line:


util.AddScopeToQuery Q, "/Intranet/man_sous_auto", "deep"

except my code would be
util.AddScopeToQuery Q, FormScope, "deep"

have you tried using "shallow" rather than "deep" (I would try using
just the root "/", then "/Intranet/" and see what results you get from
that.)

also you can exclude/include directories in the Index Server MMC

hope that helps

Scott


"David Samson" <david....@ssqgenerale.com> wrote in message news:<182f01c17757$19d62810$b1e62ecf@tkmsftngxa04>...

David Samson

unread,
Nov 28, 2001, 2:10:10 PM11/28/01
to
Thank you both.
Everything now works like a charm!

See ya!

>.
>

0 new messages