Skip 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.

Delete Duplicates on Import

Featured Replies

Can somone help me with a script that will delete duplicate records as they are imported into a database?

I have a DataSource with more than 4 million records with many of the Order Numbers Being duplicate. I would like to filter out all but the first occurence of these Order numbers as the data is being imported.

Is this possible?

Thanks,

Steve

Take a good look at the import dialog box. One of the options avialable is to Update existing records, and to add new records.

Lee

  • Author

Hi Lee,

Thanks for the quick response but I don;t see anything in the import dialog that would allow me to filter out duplicate records as they are coming in.

I'm not sure if I stated my question correctly originally...

I have a data source (ODBC) with over 4 million records. Many of these individual records share a matching "order Number" I would like to import only the first occurence of the Order Number.

Or I would like to Import all of the records and then run a sub script that deletes all of the duplicates after import, basically accomplishing the same thing if the original question is not doable.

thanks,

Steve

- Set your OrderNumber field to be unique and always validate.

- When you define your import select

--- "Update Matching Records in found set" radio button

--- "Add remaining data as new records" check box

--- change the field mapping for your ordernum fields to an equal sign.

Files attached for your reference, not sure if it will save the import info.

MyOrderNum.zip

  • 10 months later...

When you select your ODBC data source and click continue, it will open a SQL Query Builder window.

Your SQL Query should look similar to this:

Select Distinct TableName.OrderID

From TableName

By adding the word "Distinct", you will only import the first occurence of each OrderID.

Create an account or sign in to comment

Important Information

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

Account

Navigation

Search

Search

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.