Wie kann man Doubletten in den Adressen finden?

Mehr
6 Jahre 10 Monate her - 6 Jahre 10 Monate her #1143 von Anonymous
Wie kann man Doubletten in den Adressen finden?

Create View UserQueryAdressDoubletten AS select Adr1.KorrNr KorrNr_A, Adr1.Name1 Name1_A, Adr1.Strasse Strasse_A, Adr1.Ortsname Ort_A,
Adr2.KorrNr KorrNr_B, Adr2.Name1 Name1_B, Adr2.Strasse Strasse_B, Adr2.Ortsname Ort_B
from (select KorrNr, Suchname, Name1, Strasse, Ortsname,
Soundex(replace(Strasse,' ','')) as SoundexA1,
Soundex(replace(Name1,' ','')) as SoundexA2,
Soundex(replace(Ortsname,' ','')) as SoundexA3
from Adressen) Adr1
inner Join
(select KorrNr, Name1, Strasse, Ortsname,
Soundex(replace(Strasse,' ','')) as SoundexB1,
Soundex(replace(Name1,' ','')) as SoundexB2,
Soundex(replace(Ortsname,' ','')) as SoundexB3
from Adressen) Adr2
on Adr1.SoundexA1=Adr2.SoundexB1 and Adr1.SoundexA2=Adr2.SoundexB2 and Adr1.SoundexA3=Adr2.SoundexB3
where Adr1.KorrNr <> Adr2.KorrNr

Bitte Anmelden oder Registrieren um der Konversation beizutreten.