Search And Compare Text

  • Thread starter Thread starter Mike B
  • Start date Start date
M

Mike B

Hello all, I am not sure if this is the correct group to post this but I
figured I would start here. My question is, what is the best way to search
and compare 2 strings.

Say I have this string which would be the main string to start with:

John Doe #45 Jumped Over a Creek

I then have these strings in a database (MSSQL 2005):

John Doe Jumped Over a Creek
John Doe #45
John Doe #99
John Doe Ran Into a Creek
John Doe Jumped into A Pond

What is the best way to search and compare to get the closed match?


TIA
Mike
 
Mike B expressed precisely :
Hello all, I am not sure if this is the correct group to post this but I
figured I would start here. My question is, what is the best way to search
and compare 2 strings.

Say I have this string which would be the main string to start with:

John Doe #45 Jumped Over a Creek

I then have these strings in a database (MSSQL 2005):

John Doe Jumped Over a Creek
John Doe #45
John Doe #99
John Doe Ran Into a Creek
John Doe Jumped into A Pond

What is the best way to search and compare to get the closed match?


TIA
Mike

I think the best way would be to use a "full text search" option in
sqlserver. Search for the keywords CONTAINS/CONTAINSTABLE and
FREETEXT/FREETEXTTABLE.

http://msdn.microsoft.com/en-us/library/ms142497.aspx

Hans Kesting
 
It looks to me that I need to use a Full Text Search that also uses the edit
distance. Does anyone have any examples on how they implemented this?
 
Back
Top