Jump to content

avoiding importing duplicates?


GlennC
 Share

This topic is 6496 days old. Please don't post here. Open a new topic instead.

Recommended Posts

You might try importing to an intermediary database, relate it to your main database, and set up a calc field checkbox that is a "one" if it finds a matching record across the relationship, and "zero" if not.

Run a find on this checkbox for a "one" and omit. Your found set is all records not duplicated in the main db. Go to main db & import.

This entire process, starting from the .csv file, could be scripted to a single button to click.

Steve Brown

Link to comment
Share on other sites

Thanks spb. That works fine. I'm curious, how do you get all this to happen with a single click, when the script needs to access a different file?

Thanks Leb i Sol, all that is new to me and interesting - I'll do some learning.

Link to comment
Share on other sites

Set up a script in the intermediary database that will show all records, delete all records, then import the .csv. Include a Perform find script step on the checkbox as per discussion.

If set up correctly, this script ("ImportNew" will leave you with a found set in the intermediary that you want. Now set up a simple import script (one step) in your primary database that imports from the intermediary ("ImportIntermediary")

Now make a master script in the primary database that looks like:

Perform Script [sub-scripts, External: "Intermediary.fp5 (*)"]

Perform Script [sub-scripts, "ImportIntermediary"]

Add whatever bells & whistles you need, sorts, go to layout, etc. Attach this script to a button in your primary database, click it, and the effect will be that the primary is suddenly bigger by x number of new records. As long as your initial .csv file always has the same name and is always found in the same place, it should work painlessly.

Steve Brown

Link to comment
Share on other sites

This topic is 6496 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...

Important Information

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