Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 How to join data on similar string patterns

Author  Topic 

rasta
Starting Member

23 Posts

Posted - 2012-11-06 : 11:27:59
I m trying to join data based on similar strings such as the following:

SELECT p1.*,p2.*
FROM TAB1 p1
FULL OUTER JOIN TAB2 p2
ON p1.name = p2.name

However, data join only in the case the strings are exactly the same, but will not join if differs, e.g. in the following.
p1.name = 'OLOM production'
p2.name = 'com-OLOM s'

Is it possible to match such cases where only part of the strings match?

Thanks.

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2012-11-06 : 12:05:46
you need to use some kind of fuzzy matching algorithm for that and also dofew trials before you understand quality of data you're interested in

see

https://sites.google.com/site/sqlblindman/fuzzysearchalgorithm

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/

Go to Top of Page
   

- Advertisement -