Log in
::
Register
::
Not logged in
Home
Tags
Articles
Editorials
Stairways
Forums
Scripts
Videos
Blogs
QotD
Books
Ask SSC
SQL Jobs
Training
Authors
About us
Contact us
Newsletters
Write for us
Recent Posts
Recent Posts
Popular Topics
Popular Topics
Home
Search
Members
Calendar
Who's On
Home
»
SQL Server 7,2000
»
T-SQL
»
Match firstname lastname
11 posts, Page 1 of 2
1
2
»»
Match firstname lastname
Rate Topic
Display Mode
Topic Options
Author
Message
diesel
diesel
Posted Tuesday, July 22, 2003 5:51 AM
Grasshopper
Group: General Forum Members
Last Login: Friday, August 28, 2009 8:49 AM
Points: 13,
Visits: 4
Hi,
Could anyone help me with T-SQL to match names. I have to match names from one database to bank account details entered by clients in another. The problem is that clients enter full name, initials, fistname last and lastname first, spouses names etc. for account details. Huge dilemma!
Thanks in advance,
diesel
Post #14416
j.o.s.
j.o.s.
Posted Tuesday, July 22, 2003 10:40 AM
SSC-Enthusiastic
Group: General Forum Members
Last Login: Tuesday, July 06, 2004 3:29 AM
Points: 120,
Visits: 1
Instead of trying to compare single column values to multivalue columns, look at using the like operator to search through the multi-value columns looking for instances of the name you are searching. If you post your schema, we can show you the T-SQL.
Post #71569
rnelson_shs
rnelson_shs
Posted Tuesday, July 22, 2003 12:18 PM
SSC Rookie
Group: General Forum Members
Last Login: Thursday, July 31, 2003 12:00 AM
Points: 34,
Visits: 1
I agree that seeing the schema will up. The logic will might be a bit complex, may have to have more than 1 temp table, but again without the schema (from both databases), it's a hard call.
Post #71570
5409045121009-7368
5409045121009-7368
Posted Tuesday, July 22, 2003 3:14 PM
Say Hey Kid
Group: General Forum Members
Last Login: Wednesday, May 30, 2007 4:59 PM
Points: 672,
Visits: 1
Maybe more of the business rules aswell, how do you determine if Joe Doe is really Joe Doe in the other database, both maybe married to a Sue.
Post #71571
David.Poole
David.Poole
Posted Wednesday, July 23, 2003 2:16 AM
SSCrazy
Group: General Forum Members
Last Login: Thursday, May 16, 2013 3:16 PM
Points: 2,749,
Visits: 1,405
How are you going to cater for Rob, Bob, Robert, Robin, Bert. They could all be the same person or they could be all different.
Speaking as someone who has done more name and address matching than I've had hot dinners this is not something you should do on financially sensitive data such as bank accounts.
The best you could hope for would be and exact name and address match, but that is likely to be about 40% of cases if you are lucky.
LinkedIn Profile
Post #71572
diesel
diesel
Posted Wednesday, July 23, 2003 5:47 AM
Grasshopper
Group: General Forum Members
Last Login: Friday, August 28, 2009 8:49 AM
Points: 13,
Visits: 4
All valid points. I have done a link to the QAS package we use, (ACE in the USA) which narrows it down. I guess that considering it's not the brightest of requests I have had from Customer Services I will send the extract to them to wade through. Revenge is sweet.
Thanks for the help!
Post #71573
emoore 99634
emoore 99634
Posted Monday, September 24, 2012 7:13 AM
Forum Newbie
Group: General Forum Members
Last Login: Thursday, February 07, 2013 7:48 AM
Points: 3,
Visits: 53
I would use Fuzzy Matching in SSIS. Throw everything to temp table. Remove your direct matches and then fuzzy matching the rest. Sorry can't give more details, but I did this in a project once when we were trying to correlate various school lists across government agencies. A joy that was.
Post #1363471
laurie-789651
laurie-789651
Posted Monday, September 24, 2012 7:30 AM
SSC Veteran
Group: General Forum Members
Last Login: Friday, April 19, 2013 1:16 PM
Points: 272,
Visits: 781
I don't think the OP will notice because he hasn't logged in since 2009....
Post #1363479
emoore 99634
emoore 99634
Posted Monday, September 24, 2012 8:57 AM
Forum Newbie
Group: General Forum Members
Last Login: Thursday, February 07, 2013 7:48 AM
Points: 3,
Visits: 53
True, but others reading through a forum might be looking for ideas on how to tackle problems like this.
Post #1363553
Jeff Moden
Jeff Moden
Posted Monday, September 24, 2012 2:14 PM
SSC-Dedicated
Group: General Forum Members
Last Login: Today @ 8:41 AM
Points: 32,893,
Visits: 26,772
emoore 99634 (9/24/2012)
True, but others reading through a forum might be looking for ideas on how to tackle problems like this.
+1
--Jeff Moden
"
RBAR
is pronounced "ree-bar" and is a "Modenism" for "
R
ow-
B
y-
A
gonizing-
R
ow".
First step towards the paradigm shift of writing Set Based code:
Stop thinking about what you want to do to a row... think, instead, of what you want to do to a column."
For better, quicker answers on T-SQL questions, click on the following...
http://www.sqlservercentral.com/articles/Best+Practices/61537/
For better answers on performance questions, click on the following...
http://www.sqlservercentral.com/articles/SQLServerCentral/66909/
Post #1363717
« Prev Topic
|
Next Topic »
11 posts, Page 1 of 2
1
2
»»
Permissions
You
cannot
post new topics.
You
cannot
post topic replies.
You
cannot
post new polls.
You
cannot
post replies to polls.
You
cannot
edit your own topics.
You
cannot
delete your own topics.
You
cannot
edit other topics.
You
cannot
delete other topics.
You
cannot
edit your own posts.
You
cannot
edit other posts.
You
cannot
delete your own posts.
You
cannot
delete other posts.
You
cannot
post events.
You
cannot
edit your own events.
You
cannot
edit other events.
You
cannot
delete your own events.
You
cannot
delete other events.
You
cannot
send private messages.
You
cannot
send emails.
You
may
read topics.
You
cannot
rate topics.
You
cannot
vote within polls.
You
cannot
upload attachments.
You
may
download attachments.
You
cannot
post HTML code.
You
cannot
edit HTML code.
You
cannot
post IFCode.
You
cannot
post JavaScript.
You
cannot
post EmotIcons.
You
cannot
post or upload images.
Copyright © 2002-2013 Simple Talk Publishing. All Rights Reserved.
Privacy Policy.
Terms of Use.
Report Abuse.