473,385 Members | 1,707 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

A2K - how to copy a database structure with relationships?

I'm experiencing bloat problems when I restore my backup files.
Users can take a look at the reports of any previous backup without having
to ensure they have a backup of their current data - this means I have to do
a silent backup of the existing database, restore the selected mdb, then
restore the silent backup when they are finished viewing the restored data.
To the user it appears that they are are just able to see reports relating
to any backup file they select

It all works lovely but after an evening of testing this the mdb had bloated
to over 250mb!

Sooooo, I really need a more grown up solution.

One way is to refer to the data directly i.e linking of which I don't have
much experience. However the real problem is this;

I want to copy the backup file (it's password protected) to a temp mdb and
create the relationships between the tables as they exist in the main
database.

Then I can link to this file and amend my code so that the reports run using
this data. Various queries get executed so I need the relationships in
place. I would then delete the temp mdb.

Googling for this hasn't been productive. TransferDatabase only copies one
object at a time (I suppose I could do a loop) so is there a better way of
copying all the tables to a new temp mdb?

And then creating the relationships - I know what these should be so it is
feasible to establish these using some DAO? I have about 98 tables to deal
with.

The database is still single-user and unsplit at this time.
Thanks
Martin
Nov 13 '05 #1
5 2367
Ah and one more thing, how would I get my queries to use tables in another
mdb as opposed to the local mdb tables that they currently reference? Would
I have to have separate queries or something?
Nov 13 '05 #2
I mess about with a club membership database. Currently I am involved with
4, no 5 different clubs. I gave a form wich on pressing a button with the
appropriate club name detaches most of the tables on the club that I no
longer want, and links the tables from the other club.

Looks similar, but there is a lot of code and tables and forms. Might be
able to cabbage something together if you are desparate

Phil

"Deano" <ma**********@gmail.com> wrote in message
news:41***********************@ptn-nntp-reader04.plus.net...
I'm experiencing bloat problems when I restore my backup files.
Users can take a look at the reports of any previous backup without having
to ensure they have a backup of their current data - this means I have to
do
a silent backup of the existing database, restore the selected mdb, then
restore the silent backup when they are finished viewing the restored
data.
To the user it appears that they are are just able to see reports relating
to any backup file they select

It all works lovely but after an evening of testing this the mdb had
bloated
to over 250mb!

Sooooo, I really need a more grown up solution.

One way is to refer to the data directly i.e linking of which I don't have
much experience. However the real problem is this;

I want to copy the backup file (it's password protected) to a temp mdb and
create the relationships between the tables as they exist in the main
database.

Then I can link to this file and amend my code so that the reports run
using
this data. Various queries get executed so I need the relationships in
place. I would then delete the temp mdb.

Googling for this hasn't been productive. TransferDatabase only copies
one
object at a time (I suppose I could do a loop) so is there a better way of
copying all the tables to a new temp mdb?

And then creating the relationships - I know what these should be so it is
feasible to establish these using some DAO? I have about 98 tables to
deal
with.

The database is still single-user and unsplit at this time.
Thanks
Martin

Nov 13 '05 #3
Phil Stanton wrote:
I mess about with a club membership database. Currently I am involved
with 4, no 5 different clubs. I gave a form wich on pressing a button
with the appropriate club name detaches most of the tables on the
club that I no longer want, and links the tables from the other club.

Looks similar, but there is a lot of code and tables and forms. Might
be able to cabbage something together if you are desparate

Phil


Cheers, if you're able to simplify something and post the code relating to
that aspect I would be grateful.
Nov 13 '05 #4
Sorry. Need to send a complete Db

Let me have your email address

Phil
"Deano" <ma**********@gmail.com> wrote in message
news:41***********************@ptn-nntp-reader04.plus.net...
Phil Stanton wrote:
I mess about with a club membership database. Currently I am involved
with 4, no 5 different clubs. I gave a form wich on pressing a button
with the appropriate club name detaches most of the tables on the
club that I no longer want, and links the tables from the other club.

Looks similar, but there is a lot of code and tables and forms. Might
be able to cabbage something together if you are desparate

Phil


Cheers, if you're able to simplify something and post the code relating to
that aspect I would be grateful.

Nov 13 '05 #5
Phil Stanton wrote:
Sorry. Need to send a complete Db

Let me have your email address
OK, mail me at martin dot dean at gmail dot com

thanks

Phil
"Deano" <ma**********@gmail.com> wrote in message
news:41***********************@ptn-nntp-reader04.plus.net...
Phil Stanton wrote:
I mess about with a club membership database. Currently I am
involved with 4, no 5 different clubs. I gave a form wich on
pressing a button with the appropriate club name detaches most of
the tables on the club that I no longer want, and links the tables
from the other club.

Looks similar, but there is a lot of code and tables and forms.
Might be able to cabbage something together if you are desparate

Phil


Cheers, if you're able to simplify something and post the code
relating to that aspect I would be grateful.


Nov 13 '05 #6

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
by: Marc R. Bertrand | last post by:
Hello, Do some of you know some pretty good books or web tutorials on building databases, if any? By that I mean, when looking at a business, the sound way of choosing the proper fields and the...
7
by: Andante.in.Blue | last post by:
Hello everyone! I've been working with a problematic legacy database for a while. While I am still fairly new to Access, the more I work with the database, the more problems I've uncovered. ...
11
by: dixie | last post by:
If I wanted to be able to copy all of the tables in an existing database called Original.mde to another database called New.mde from a button click event in Original.mde, is there an easy way of...
6
by: Noozer | last post by:
I'm developing a database using MS Access and have come across a problem. The majority of my database is pretty straightforward "many to one" relationships. I have one relationship that is...
3
by: solar | last post by:
n my work i often do copy all the objects of the database to a new database.Can i also copy the relationships instead of creating them anew? Is there a command in Access to copy all the...
4
by: Stephan Tobies | last post by:
Hi everyone, I am looking for a good data structure that could be used to represent families of trees with shared sub-trees and copy-on-write semantics. On a very abstract level, I would like...
29
by: MP | last post by:
Greets, context: vb6/ado/.mdb/jet 4.0 (no access)/sql beginning learner, first database, planning stages (I think the underlying question here is whether to normalize or not to normalize this...
1
by: Eric Sadoyama | last post by:
I have a database documentation question, but I am not even sure how to phrase it properly so I don't know where to start looking for answers. We are developing a database that is based on...
1
by: Froefel | last post by:
I'm starting research on how I could best approach feeding XML files to a relational database. Here's the scenario: - we receive several hundred XML files per week, all of which adhere to the...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.