Information générale
Catégorie:
Base de données, Tables, Vues, Index et syntaxe SQL
Titre:
Find duplicate ID by last 3 digits and address
Hi all,
I have a single table that I would like to find a single record for each same name, same first name, same birthday, different address that are created those persons ID:
For example :
mytable contains only an ID and city :
Name, First, Birthday, address = ID and city
Joe Doe 19601231 mycity = JDOE19601231001 mycity
Joe Doe 19601231 yourcity = JDOE19601231002 yourcity
Joe Doe 19601231 hiscity = JDOE19601231003 hiscity
Joe Doe 19651231 hercity = JDOE19651231002 hercity
Joe Doe 19651231 sexcity = JDOE19651231001 sexcity
Jay Doe 19601231 joecity = JDOE19601231001 joecity
Jay Doe 19601231 jaycity = JDOE19601231002 jaycity
Jay Doe 19601231 ourcity = JDOE19601231003 ourcity
Joe Doe 19651231 fullcity = JDOE19651231001 fullcity
Joe Doe 19651231 lastcity = JDOE19651231002 lastcity
Joe Doe 19651231 firstcity = JDOE19651231004 firstcity
I could have a hundred records to sort out by the last 3 digits of their id started from 001,002,003,004,005 .....100 and different addresses that separated each id.
I really appreciated that someone could help me with the SQL command to do this.
Thank in advance,
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement