Re: [WebDNA] Finding duplicate email addresses
This WebDNA talk-list message is from 2008
It keeps the original formatting.
numero = 100916
interpreted = N
texte = ------=_Part_20387_7878879.1222156217131Content-Type: text/plain; charset=UTF-8Content-Transfer-Encoding: 7bitContent-Disposition: inlineThanks guys,I ended up using a mixture of all the ideas, I wanted to show all recordswith duplicate email addresses so the user can then decide which one todelete. The code I'm using is not pretty but it works - I'll try to refineit.The first search sets up a table with the email duplicates - but thisdoesn't include the initial email that the comparison is based on. Thesecond search goes through this table and summarises the email field - thefinal search searches the original database to ensure that all records withduplicate emails are shown.Its taking a couple of seconds to go through a list of about 9000 records.- Tom[search db=some.db&neRIDdatarq=find_all&asEMAILsort=1][text]prevRecord=NADA[/text][table name=duplist&fields=RID,DUPEMAIL][founditems][showif [url][prevRecord][/url]=[url][EMAIL]][RID] [EMAIL][/showif][text]prevRecord=[EMAIL][/text][/founditems][/table][/search][searchtable=duplist&neRIDdatarq=find_all&asEMAILsort=1&EMAILsumm=T][founditems][search db=somedb.db&eqEMAILdatarq=[DUPEMAIL][showif[url][DUPEMAIL][/url]=][blank][/showif]][founditems][RID] [EMAIL][/founditems][/search][/founditems][/search]------=_Part_20387_7878879.1222156217131Content-Type: text/html; charset=UTF-8Content-Transfer-Encoding: 7bitContent-Disposition: inline
Thanks guys,
I ended up using a mixture of all the ideas, I wanted to show all records with duplicate email addresses so the user can then decide which one to delete. The code I'm using is not pretty but it works - I'll try to refine it.
The first search sets up a table with the email duplicates - but this doesn't include the initial email that the comparison is based on. The second search goes through this table and summarises the email field - the final search searches the original database to ensure that all records with duplicate emails are shown.
Its taking a couple of seconds to go through a list of about 9000 records.
- Tom
[search db=some.db&neRIDdatarq=find_all&asEMAILsort=1]
[text]prevRecord=NADA[/text]
[table name=duplist&fields=RID,DUPEMAIL]
[founditems][showif [url][prevRecord][/url]=[url][EMAIL]][RID][EMAIL]
[/showif][text]prevRecord=[EMAIL][/text][/founditems][/table]
[/search]
[search table=duplist&neRIDdatarq=find_all&asEMAILsort=1&EMAILsumm=T][founditems]
[search db=somedb.db&eqEMAILdatarq=[DUPEMAIL][showif [url][DUPEMAIL][/url]=][blank][/showif]][founditems]
[RID] [EMAIL]
[/founditems][/search]
[/founditems][/search]
------=_Part_20387_7878879.1222156217131--
Associated Messages, from the most recent to the oldest:
------=_Part_20387_7878879.1222156217131Content-Type: text/plain; charset=UTF-8Content-Transfer-Encoding: 7bitContent-Disposition: inlineThanks guys,I ended up using a mixture of all the ideas, I wanted to show all recordswith duplicate email addresses so the user can then decide which one todelete. The code I'm using is not pretty but it works - I'll try to refineit.The first search sets up a table with the email duplicates - but thisdoesn't include the initial email that the comparison is based on. Thesecond search goes through this table and summarises the email field - thefinal search searches the original database to ensure that all records withduplicate emails are shown.Its taking a couple of seconds to go through a list of about 9000 records.- Tom[search db=some.db&neRIDdatarq=find_all&asEMAILsort=1]
[text]prevRecord=NADA[/text][table name=duplist&fields=RID,DUPEMAIL]
[founditems][showif
[url][prevRecord][/url]=
[url][EMAIL]][RID] [EMAIL][/showif]
[text]prevRecord=[EMAIL][/text][/founditems][/table][/search][searchtable=duplist&neRIDdatarq=find_all&asEMAILsort=1&EMAILsumm=T]
[founditems][search db=somedb.db&eqEMAILdatarq=[DUPEMAIL][showif
[url][DUPEMAIL][/url]=][blank][/showif]]
[founditems][RID] [EMAIL][/founditems][/search][/founditems][/search]------=_Part_20387_7878879.1222156217131Content-Type: text/html; charset=UTF-8Content-Transfer-Encoding: 7bitContent-Disposition: inline
Thanks guys,
I ended up using a mixture of all the ideas, I wanted to show all records with duplicate email addresses so the user can then decide which one to delete. The code I'm using is not pretty but it works - I'll try to refine it.
The first search sets up a table with the email duplicates - but this doesn't include the initial email that the comparison is based on. The second search goes through this table and summarises the email field - the final search searches the original database to ensure that all records with duplicate emails are shown.
Its taking a couple of seconds to go through a list of about 9000 records.
- Tom
[search db=some.db&neRIDdatarq=find_all&asEMAILsort=1]
[table name=duplist&fields=RID,DUPEMAIL]
[/showif][text]prevRecord=[EMAIL][/text][/founditems][/table]
[/search]
[search table=duplist&neRIDdatarq=find_all&asEMAILsort=1&EMAILsumm=T][founditems] [search db=somedb.db&eqEMAILdatarq=[DUPEMAIL][showif [url][DUPEMAIL][/url]=][blank][/showif]][founditems]
[RID] [EMAIL]
[/founditems][/search]
[/founditems][/search]
------=_Part_20387_7878879.1222156217131--
"Tom Duke"
DOWNLOAD WEBDNA NOW!
Top Articles:
Talk List
The WebDNA community talk-list is the best place to get some help: several hundred extremely proficient programmers with an excellent knowledge of WebDNA and an excellent spirit will deliver all the tips and tricks you can imagine...
Related Readings:
Commitdatabase tag (1998)
Beta version-Mac? (was Emailer update for Mac?) (1998)
Snake Bites (1997)
WebCat2 Append problem (B14Macacgi) (1997)
Problem with version 4 browsers (1998)
Logical and or in [hideif] (1997)
WebCat2b13 Mac plugin - [sendmail] and checkboxes (1997)
Part Html part WebDNA (1997)
Searching multiple Databases (1997)
Searching Multiple DBs (1997)
RE: [WebDNA] XML Help (2009)
Webcatalog, Webstar and Crasharama (1999)
Support ?? (1997)
CMS (2003)
service stop and restart (1997)
WebCat2b14MacPlugIn - [include] doesn't hide the search string (1997)
Dates (1996)
Add to Cart & List of Products (1997)
WebCatalog2 Feature Feedback (1996)
MyVitrualMerchant (2007)