Need help inserting table

haveli1

New member
Local time
Today, 12:23
Joined
Jul 24, 2006
Messages
9
I have a database that contains a few tables and queries etc. I made a copy of this database so that I could change some of the VB code with out affecting the database information. I have completed all the code and now I want to input those old tables into my finished verion. I am not sure how to do this. Any ideas on how I could do this would greatly be appreciated. Thanks.
 
Open the new db and then File>Get External Data>Import...
 
The only problem with this is that some of my tables have extra columns. I have the correct tables on my changed Database, but I added 50 records when I was testing the Database. Is there a way I can delete these 50 records, while also starting the autonumber back at where I left off.

The correct ID number is 900 (Autonumber)
I added ID until 950, but thse extra records are just tests.
I want to delete thse 50 records and start back again at 900 with my new and inproved database. Is this possible?
 
So you would like to delete all of the records in the new mdb and then append the tables from the old mdb, correct? This is a one time operation so go ahead and import the tables and the do the record manipulations. Delete * from TableName will delete all of the records. By the way, since you seem to be concerned about the value of your AutoNumber field, I'll bet you are not using it correctly. It should *never* be seen by the user and you should not be concerned about the value.
 
Sorry, I am somewhat new at this. I am not quite sure what you are telling me to do. I dont want to delete all the records, but I would like to delete the last 50 records, if that is possible. My ID number is the autonumber. It is to keep track of the forms. If you could explain what I should do in a little more detail, it would be appreciated. Thanks for your help so far.
 
How many tables had their structure changed? You can delete 50 records by hand in just a few minutes. If you deleted *all* of the records in the new mdb and then appended all of the records from the old db, would that give you what you want? If you delete all of the records in a table and then compact and repair, the AutoNumber starts over.
 
Two tables had their structure changed. And on the forms I added a few more text boxes. I deleted the 50 records, however when I add a new record the ID began at 950. Is there a way to make the ID go back to 900.

So in my changed database the ID goes to 950 with 50 testing records.
In the old datbase there are 900 records. What would you suggest the easiest way to get the 900 records keeping in mind that I have changed alot of the tables.
 
If you've still got a copy of the original database you could try splitting the databases into back ends (containing the information) and front ends (containing the code) then linking the new front end to the old back end. There are tool for this in the AddIns if you have them installed and they work really well.
If you did this with a database called fred.mdb you would end up with 2 files called fred.mdb and fred_be.mbe where fred_be.mdb is the back end or data file and fred.mdb would be linked to the tables in fred_be.mdb.
The advantage of this is that you can work on a test copy called fredtest.mdb, say, linked to fredtest_be.mdb, say, and not affect your live data. When you've got fredtest.mdb doing what you want you then link it to fred_be.mdb using the Linked Table Manager in the addins, rename or delete fred.mdb and rename fredtest.mdb to fred.mdb.
The disadvantages are 1) you have to install and get the hang of the linked table manager and database splitter and 2) you have to keep track of which copy of the database is which.
If you want to try this approach I suggest that you create a simple trial database to experiment on before you try it on your important stuff, but that's good advice generally!
Best of luck!!
 

Users who are viewing this thread

Back
Top Bottom