G
Guest
I need to add the ability to import a lot of data from another database.
I've created a form and allow the user to select the database to import from.
Now since the imported data is supposed to replace the existing data, I need
to remove all the existing data. That I can do, except for the fact that
there are 2 tables whose data should not be removed, but which have
relationships to the other data that will be removed. So I need to break
those relationships before removing the data, and then recreate them after
the data has been imported.
How can that be done in vba? I've been looking at ADO and ADOX objects and
methods, but haven't figured out exactly what needs to be done to remove and
then recreate a relationship. Can someone point me to a source that explains
how to do this? Thanks!
I've created a form and allow the user to select the database to import from.
Now since the imported data is supposed to replace the existing data, I need
to remove all the existing data. That I can do, except for the fact that
there are 2 tables whose data should not be removed, but which have
relationships to the other data that will be removed. So I need to break
those relationships before removing the data, and then recreate them after
the data has been imported.
How can that be done in vba? I've been looking at ADO and ADOX objects and
methods, but haven't figured out exactly what needs to be done to remove and
then recreate a relationship. Can someone point me to a source that explains
how to do this? Thanks!