Archive Data question - Subform

sondriven

Registered User.
Local time
Today, 06:55
Joined
Jun 13, 2002
Messages
158
Hello

I have an inventory program that has a form and a subform. In the main form, there is the basic information. Part Number, Description, ect. In the Subform, there is the information on what qty was taken out on what day it was taken out and vice versa for putting items in stock. So for each time something is added or taken out of stock a new line is put in. The number of records is getting quite large now and I was wondering if theres a way to archive this information? Say for every year, the information can be dumped into an archive file. Is this possible? If so, what do I have to do?

Thanks

john
 
Hi
You can have 2 methods to keep archive info:
1) keep achive in a table within your database or
2) in other database table linked to your database.

How:
1)Create query "ArchiveYear" which contain all fields for archivation(current year)
2) Create table "ArchiveAll" with all the same fields name.
3) Validate using VBA code that current time is end of december
4) If it is true then
a) run query "Insert into ArchiveAll Select * from ArchiveYear"
b) run query "Delete * from ArchiveYear", so you erase all current year subform info.
This will also work for linked table(2 method).
Best regards.
Igor.
 

Users who are viewing this thread

Back
Top Bottom