Unix Technical Forum

Words suggest or spellcheck in MS SQL 2005 Express

This is a discussion on Words suggest or spellcheck in MS SQL 2005 Express within the SQL Server forums, part of the Microsoft SQL Server category; --> I am trying to recreate the same functionality Google has in regards to suggesting words (not names), when you ...


Go Back   Unix Technical Forum > Database Server Software > Microsoft SQL Server > SQL Server

FAQ Members List Calendar Search Today's Posts Mark Forums Read
  #1 (permalink)  
Old 03-01-2008, 12:09 PM
Pacific Fox
 
Posts: n/a
Default Words suggest or spellcheck in MS SQL 2005 Express

I am trying to recreate the same functionality Google has in regards to
suggesting words (not names), when you misspell something it comes up
with suggestions.

We have a list of words in the database to match against.

I've looked at SOUNDEX but it is not close enough, DIFFERENCE is even
worse.
The only way I can get SOUNDEX to be more accurate is with
SELECT [word]
FROM [tbl_word]
WHERE ( SOUNDEX( word ) = SOUNDEX( 'test' ) AND LEN( word) = LEN(
'test' ) )

I've been looking at Regular Expression matching which I reckon would
provide more accurate matches. Not sure how that will affect
performance, as we could be talking about 20,000 records.

Or also been looking at the Double Metaphone algorithm.

Is there something else that I am missing, anyone know what to use in a
situation like this?

Thanks in advance.

Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
  #2 (permalink)  
Old 03-01-2008, 12:09 PM
Dam
 
Posts: n/a
Default Re: Words suggest or spellcheck in MS SQL 2005 Express

Hi,

You can try Edit Distance or Levenshtein distance, which are more
advanced similarity algorithms

http://www.google.com.ar/search?hl=e...sque da&meta=
http://en.wikipedia.org/wiki/Levenshtein_distance

I believe there are some T-SQL implementations to these methods.

However I guess Google must do more than look for most similar words to
your keywords. Maybe you could find most similar and used words to try
to detect what user is most probably going to look for.

Hope that helps,
Damian

On 25 ene, 20:38, "Pacific Fox" <tacofl...@gmail.com> wrote:
> I am trying to recreate the same functionality Google has in regards to
> suggesting words (not names), when you misspell something it comes up
> with suggestions.
>
> We have a list of words in the database to match against.
>
> I've looked at SOUNDEX but it is not close enough, DIFFERENCE is even
> worse.
> The only way I can get SOUNDEX to be more accurate is with
> SELECT [word]
> FROM [tbl_word]
> WHERE ( SOUNDEX( word ) = SOUNDEX( 'test' ) AND LEN( word) = LEN(
> 'test' ) )
>
> I've been looking at Regular Expression matching which I reckon would
> provide more accurate matches. Not sure how that will affect
> performance, as we could be talking about 20,000 records.
>
> Or also been looking at the Double Metaphone algorithm.
>
> Is there something else that I am missing, anyone know what to use in a
> situation like this?
>
> Thanks in advance.


Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!
Reply With Quote
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT. The time now is 09:49 PM.


Powered by vBulletin® Version 3.6.5
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0
www.UnixAdminTalk.com