Copying one table to another, at same time as appending

D4WNO

Board Regular
Joined
Mar 6, 2012
Messages
67
Hi everyone,

I can't edit the title now, it's supposed to say "copying one TABLE to another", oops [note: title changed now - moderator]
I'll try to explain what I'm looking for as best I can but do please ask questions if I've done a terrible job of it.

To give some background, I run a daily download of fault tickets and I have the below tables set up

Old data
Current data
New data

I'd like to do the below in this order

1) Copy "Current data" to "Old data" (so Old is like an archive).
2) Append "New Data" to "Current Data" AND hopefully at same time, update other entries in "Current Data if they've been updated) - There is a field named "Last Updated" so it'll add anything brand new since the newest one, and then also update any tickets already in there with the updated information.

Is this at all possibl or will I need to do this as entirely seperate options?

Thanks in advance for your help, I really appreciate you taking the time to read this.
 
Last edited by a moderator:

Excel Facts

Excel Joke
Why can't spreadsheets drive cars? They crash too often!
During the daily download, how many tables are received?

If there is just a single download, does it include just 'current' tickets? Or something else?

Is there a unique index, like a Ticket number so that duplicates are not introduces in the current table?
 
Upvote 0
Hi there,

It's just a single table that we download from another system (Remedy), then upload into Access. Yes, it uses "Ticket ID" as the unique ID
 
Upvote 0
What will be in the new table?

Will it have tickets that are in the current table and new tickets which aren't in the current table?

Could it also be missing 'old' tickets?

Have you considered this?

1 Append all data from current table to old table.

2 Delete all records from current table.

3 Append all records from new table to current table.

Would that work?
 
Upvote 0
Stages 2 and 3 won't work - I need to keep what is already in "Current", then add anything brand new from "New" and also update anything in "New" with a last updated date of a date that I select.
 
Upvote 0
Thought that might be the case.

What do you mean by update exactly?

Would you add a timestamp to both new and updated records?
 
Upvote 0
I basically have a list of tickets, all with different statuses and open/closed throughout the day.

I will be updating the "Current" list with anything brand new and also updating anything that has changed since it was last run (this will be signified by the "last updated" field" within the data
 
Upvote 0
You could do this with 2 queries.

The first would be an append query and the second an update query.
 
Upvote 0
Oops, actually 3 queries, another to add the current data to the old table.
 
Upvote 0

Forum statistics

Threads
1,214,805
Messages
6,121,656
Members
449,045
Latest member
Marcus05

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top