Deleting Records in a Database

U

Una

Hi all,

I've got a database that I would like to copy and give to a friend for her
business, however I don't want her to have copies of any of the records.

There are thousands of records and I could delete one by one but that's just
not worth it!

Is there a way to delete all records in all tables? I've gone into each
table and deleted all records at once, but then when I test the database I
get error messages, the debugging screen pops up, and it won't allow me to
enter any new records.

Any ideas?

Access is not my forte!

U :)
 
A

Arvin Meyer

Build a new empty database and import the tables from the old one. Before
you push the OK button, click on the Options button and choose "Definition
Only" and whatever other othions you'd like. Push the button and all the
tables will be imported likety-split!
--
Arvin Meyer, MCP, MVP
Microsoft Access
Free Access Downloads
http://www.datastrat.com
http://www.mvps.org/access
 
J

John Vinson

Is there a way to delete all records in all tables? I've gone into each
table and deleted all records at once, but then when I test the database I
get error messages, the debugging screen pops up, and it won't allow me to
enter any new records.

Any ideas?

You can use Delete queries - but you will probably need to do so in
the correct order. Access won't let you delete records from a "parent"
table if this would leave orphan records in a "child" table.

The solution is to start with the "many" side tables; create a new
Query based on each table. Select the * field and change the query to
a Delete query, and run it with the ! icon.

Some "lookup" tables should probably be spared, for example if you
have an address component you may have a table of States or
PostalCodes - that's not your proprietary data and will be useful to
your friend, so leave those tables unemptied.

John W. Vinson[MVP]
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top