473,507 Members | 2,368 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Appending Tables:

I have an Access DB that contains 5 tables for the last 5 years. All 5
tables have the same structure. I wanted to keep each year separate
for organizational purposes.

But, I want to query all 5 tables with one query for an application.

What would an query look like that uses all 5 tables as a source ?

Should I create a view that inserts all 5 tables into a recordset ?
(Wouldn't this be resource heavy ?)

Thanks

Sid.
Nov 13 '05 #1
1 1788
"Eli Sidwell" <si******@alexian.net> wrote in message
news:ef**************************@posting.google.c om...
I have an Access DB that contains 5 tables for the last 5 years. All 5
tables have the same structure. I wanted to keep each year separate
for organizational purposes.

But, I want to query all 5 tables with one query for an application.

What would an query look like that uses all 5 tables as a source ?

Should I create a view that inserts all 5 tables into a recordset ?
(Wouldn't this be resource heavy ?)


What you're looking for is called a Union query (check help file). It basically
combines tables vertically rather than the more typical horizontal. This type
of query cannot be built in the query design grid, but rather has to built in
SQL view.

You would be better served long term to combine all the tables into one and add
a field to identify the year. It is MUCH easier to pull one desired year out of
a table with multiple year's data using a query than it is to combine multiple
tables with a Union. Plus a Union is automatically read only. Not a problem
for reporting, but you might want to do some editing across years at some point.
--
I don't check the Email account attached
to this message. Send instead to...
RBrandt at Hunter dot com
Nov 13 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
11190
by: freeagent | last post by:
Help!! I am a complete Access newbie and I have to concatenate about 30 tables into one large table. All these tables have the same column headings as each other. For example, I have TABLE...
2
2075
by: dixie | last post by:
If I have two compatible tables, but in two separate databases, can I append the records in one table onto the records in the other by code in either a module or a form. If the two databases were...
7
2404
by: PC Datasheet | last post by:
Looking for suggestions ---- A database was designed for a national automobile inspection program. In it's simplest form, the database has two tables: TblOwner OwnerID <Year/Make/Model owned...
2
2225
by: tony.collings | last post by:
I started a thread here : http://groups.google.co.uk/group/microsoft.public.cmserver.general/browse_thread/thread/29d63077144004a9/c3888efdcb7338f6?hl=en#c3888efdcb7338f6 About creating an Email...
13
2368
by: Shwetabh | last post by:
Hi, I wanted to know if it is possible to do to append two tables into a third table. For example, consider these two tables Table 1...
2
1382
by: sjlung | last post by:
I have set up queries in access that make tables and then append them to each other. Unfortunately the resulting table after three seperate tables are appended does not comprise of all the entries...
7
9465
by: Daz | last post by:
Hi everyone! Is it possible to take a line of text like so: <tr><td>title1</td><td>title2</td><td>title3</td><td>title4</td></tr> And append it to a DOM node such as this: var...
3
1665
by: HSXWillH | last post by:
I've looked through the site and not found what I'm looking for here. I am not code-versed or anything like that so my skills are rudimentary at best. I'm using Access 03 on a Windows Vista...
3
4442
by: manojspromantr | last post by:
I'm trying to append some data from one table to another table both the table structure are same. I have an attachments field in both tables but it seems that i cannot append the attachments from one...
0
7111
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
1
7031
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7485
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
1
5042
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
4702
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3179
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1542
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
760
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
412
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.