Got a question about technology? Ask it here. Discussion of hardware, software, TiVos, multi-region DVDs, Windows, Macs, LINUX, hand-helds, iPods, anything tech related. Better than any helpdesk!
Hi--
Here am I with my daily Access question:
Is it possible to create an empty duplicate of a database. Currently, every class has a database, and, while I'd like to eventually make one registration database, right now I would like to not seem like I am changing everything.
In Filemaker, I could save a "clone, no records" copy of the database. It appears there is no good way to do this in Access. I would prefer not to build 35 identical databases.
Create a new database. Import all the tables from the existing database, but tell Access to import the table design only. (Also, import any queries, reports, forms, etc.)
If there aren't that many tables/records, you could also make a copy of the mdb file in explorer, then open the database, open each table, and delete all the records in each table.
Or you could enter and run the following function
Function cleartables()
Dim tdf As TableDef
DoCmd.SetWarnings False
For Each tdf In CurrentDb().TableDefs
if left(tdf.name,4) <> "msys" then
DoCmd.RunSQL "DELETE FROM " & tdf.name
end if
Next
DoCmd.SetWarnings True
End Function
I forgot how to quote while preserving formatting, which is why nothing in the above is indented....
eta: wait, don't do that, as it deletes system tables too.
eta2: There. All better.
Thanks tommy and DX. I'm going to get the hang of this soon, I hope!
TiVo reports first profit.
Well, breakeven actually. But still! Good News!
Go TiVo!
t clings to her TiVo