Full Version: Pull values from tables and store them in temp tables
UtterAccess Forums > Microsoft® Access > Access Queries
Greetings. The title doesn't give the full info - here's the rest. The db I created for my Boss gives her the option to create what basically equates to a back-up of a table. I'm currently giving this backup table the name "tblPrior_ yyyymmdd" with yyyymmdd equaling Format(Date, "yyyymmdd"). I have several of these tables which have different run dates inside the table (fieldname is Prun_Dte).
o what I'd like to do is to pull the Prun_Dte value and put it in a temp table (permanent table?) and then run a query against those values that will populate a combobox that will allow my Boss to select which table she would like to restore.
Odon't mind changing the way I'm currently naming "tblPrior_yyyymmdd" if doing so makes it easier to accomplish what I'm after.
I hope I've made this clear (and I'm sure I'll be notified if I haven't sad.gif ).
Having several tables with all of the same structure seems inefficient to me. The only time I would consider moving data to an identically structured table is if I was archiving data, and the table would be put into a separate database altogether.
You can accomplish the same thing with 1 table and a series of queries that pull the info the user wants. You can put the query names (with the format you describe) in a table so that you can populate the combo box you mention.
This is a "lo-fi" version of UA. To view the full version with more information, formatting and images, please click here.