By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
425,461 Members | 2,184 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 425,461 IT Pros & Developers. It's quick & easy.

Comparing data in two databases

P: 4
Hi

We had a recent migration to a new server early this week (Tuesday). My database (and all the other files on the old server) were copied onto the new server. The old server is still up and running and some people inadvertantly entered data in the database on the old server over the past few days. I need to find out what was eroneously added to the database on the "old" server so I know what data I need to update in the real database on the "new" server.

I have a backup copy that I made on the "new" server immediately after the migration occurred. So, I can use that as the baseline database.

I also have a copy of the database on the "old" server on the date it was discovered that data was eroneously entered on the "old" server's database (Thursday).

How do I compare these 2 databases (tables) to see what data had been eroneously added to the old copy of the database?

(I don't know how to do VBA).

Thanks very much!!!!
Giff
Jan 12 '08 #1
Share this Question
Share on Google+
1 Reply


P: 45
Hi

We had a recent migration to a new server early this week (Tuesday). My database (and all the other files on the old server) were copied onto the new server. The old server is still up and running and some people inadvertantly entered data in the database on the old server over the past few days. I need to find out what was eroneously added to the database on the "old" server so I know what data I need to update in the real database on the "new" server.

I have a backup copy that I made on the "new" server immediately after the migration occurred. So, I can use that as the baseline database.

I also have a copy of the database on the "old" server on the date it was discovered that data was eroneously entered on the "old" server's database (Thursday).

How do I compare these 2 databases (tables) to see what data had been eroneously added to the old copy of the database?

(I don't know how to do VBA).

Thanks very much!!!!
Giff
If this is a one time fix I would create a blank database. Link to the tables in the two different databases you want to compare. Create a select query that has both Old and New tables linked at the unique ID then right click the link line and choose to show all records in the Old table whether or not they exist in the New table. Then filter the New table ID field to "is Null". Now you should see all the records that exist in the Old table but not the New. At this point I would change the query from select to make table (called Missing) - just to review before appending the records. The query SQL should look somthing like this:

SELECT [Old Table].* INTO Missing
FROM [Old Table] LEFT JOIN [New Table] ON [Old Table].RecID = [New Table].RecID
WHERE ((([New Table].RecID) Is Null));

Once you are satisfied that the missing table is only missing records with no errors then create and run a simple Append query to the New table.
Jan 12 '08 #2

Post your reply

Sign in to post your reply or Sign up for a free account.