[Xapian-discuss] Searching for terms like C#?

Olly Betts olly at survex.com
Thu Apr 14 13:47:36 BST 2005


On Thu, Apr 14, 2005 at 02:28:14PM +0200, Arjen van der Meijden wrote:
> Didn't you change enough in the quartz backend to make it advisable to 
> rebuilt the databases anyway?

0.9.0 does a better job of filling blocks in "sequential mode" (which is
what you'll be in when adding lots of documents to a database).  But I'm
not sure that I'd go as far as advising a rebuild.  Running the database
through 'quartzcompact -n' will achieve roughly the same result, but be
a lot faster.

> Anyway, the change in case of C# vs C is indeed not that bad even if a 
> database is not regenerated.
> 
> Btw, don't forget J# as well ;) I can ask if other users of our forum 
> know of more similar terms if you like?

There's also at least "A#", which is Ada for .NET and "F#" which is
OCaml for .NET (I can't help wondering why "F" seemed the obvious
choice...)

But I'd probably just implement it as a # suffix on a term, since adding
"#" is an obvious way to name a port of something to .NET.  Musical
notes are another example: "D#"

Hmm, we could also check (if a database has been given) that the term
exists, and drop the # if not.  That's probably useful in general, but
also nicely gives us the current behaviour if "C#" hasn't been indexed
with the #.  This check would probably be a useful way to handle + and -
suffixes too...

Cheers,
    Olly



More information about the Xapian-discuss mailing list