phrase searching with SearchKit
phrase searching with SearchKit
- Subject: phrase searching with SearchKit
- From: Michael Thon <email@hidden>
- Date: Fri, 2 Jul 2010 11:09:46 +0200
I'm trying to set up an index with SearchKit and search it with quoted phrases. It is my understanding that I need to enable proximity indexing to get phrase searches to work. If I don't enable proximity indexing, then it seems like my quoted string is treated as separate search terms. However, when I enable proximity indexing, my quoted string doesn't return any hits from the index. The string I'm searching is from a document I know has been indexed. When I try the quoted string with Spotlight, I can find the document. Here is the code I'm using to create the database:
CFMutableDictionaryRef props = CFDictionaryCreateMutable(NULL, 0,
&kCFTypeDictionaryKeyCallBacks, &kCFTypeDictionaryValueCallBacks);
CFDictionaryAddValue(props, kSKProximityIndexing, kCFBooleanTrue);
theIndex = SKIndexCreateWithURL((CFURLRef) url,
(CFStringRef) dbName,
kSKIndexInverted,
props);
Anyone know what I'm doing wrong?
Mike
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden