Rachel has attended:
Access Introduction course
Access Intermediate course
Access Advanced course
Make table queries
If I made a make table query and a form to run that query, and I wanted to run that query several times a year but I didnt want to re-write existing tables, how would I do that?
RE: Make table queries
Thank you for your question
After some consideration it seems the only way to do this would be to write some VBA code that would prompt the user to enter a table name and would then insert that name into the queries SQL and then run the query.
An example of the code required is as follows
Sub MakeTable()
Dim strTable As String
Dim strSQL As String
strTable = InputBox("Enter table name")
strSQL = "SELECT Employees.Company, Employees.[Last Name], Employees.[First Name] INTO" & """strtable""" & "FROM Employees;"
DoCmd.Run strSQL
End Sub
However I suggest that you might find things easier if you use an append query to send all the data to the same table. You can then run searches on that table using date ranges
Regards
Stephen