Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Featured Replies

  • Newbies

How do you purge duplicate values with a field? For example: We are holding a tradeshow in Los Angeles next month and there are duplicate registrations, email addresses, etc.

First, in the short run, I need to send out a thank you letter with some of the last minute show add-ons, etc., and I don't want to send out more than one to the attendees. So a simple purge duplicates on the email field would be appreciated. Know of one??? confused.gif

Secondly, the MySQL database that the guy set up for us allows duplicate records and so I'd really like to purge duplicate records without having to manually go through them all one by one by hand, there will be 3,000 or more good ones by show time, February 18-20.

Any ideas???

Your help would be appreciated.

Ron Lindeboom

creativecow.net

If you put an exclaimation mark in a field in find mode, it finds all records in which that field is not unique.

So you could do something like this:

LOOP

Enter find mode

Set field, email, "!"

Perform find

#this will produce a big long list

set field, globalTemporaryEmail, email

#this remembers the first email address

enter find mode

set field, email, globalTemporaryEmail

perform find

#now you see all the records with that same email address

delete record (or maybe you just want to clear the field)

#this deletes the first one (there may still be duplicates of that address, but you'll catch that later.

END LOOP

Hi,

Create a relationship from eMail Address to eMail Address fields ( making a self relationship, lets call this SelfJoin)

Create a field RecordID (or use an existing serial number field)

Then, create a calculated field (lets call it cPrimaryRecord, result of a number)

Case(RecordID = SelfJoin::RecordID, 1,0)

This will tag the first record with a 1, then you can search for the 0's and delete, or just search for the 1's and then send out your email.

A lot easier than scripting, and quicker too.

This will tag the first record with a 1

What stops it from tagging both duplicates?

Did you try it?

You can also do If(Min(SelfJoin::RecordID) = RecordID,1,0)

However, this one does not tag a record with anything if it does not have duplicates, if it does, it tags the first record with a 1 and the remainder with a 0.

Did you try it?

no, I just don't understand how it works.

It seems to me that both of the duplicates would have a valid self relationship to eachother, so wouldn't they both get tagged?

  • Author
  • Newbies

Very cool technique. Worked like a charm. Took me a few minutes to gain the simplicity of mind to grasp it, but once I did -- flawless.

Very, very cool little trick, Andy -- you earn Boomie's eternal gratitude and a free pass to our media professionals conference and expo if you want one. (We have a killer Final Cut Pro track if you use it at all.)

The best always,

Ron Lindeboom

creativecow.net

no, I just don't understand how it works.

The reason is that in case of one to many relationship (and self join could be of that type), when refering to some related field you are ponting to the field of first related record.

dj

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.