473,327 Members | 1,919 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,327 software developers and data experts.

Put 3 tables with same fields into one

hi,

i have three tables all with same fields i.e an id and a count.

table1 + table2 + table3 = #temp

thanks
Feb 15 '07 #1
3 1254
almaz
168 Expert 100+
Expand|Select|Wrap|Line Numbers
  1. insert #temp
  2. select * from table1
  3. union all
  4. select * from table2
  5. union all
  6. select * from table3
Feb 15 '07 #2
thanks man, i had just found out about the union thing

but was not workin as left out some records

then i saw your 'all' thing and that works.

whats the difference?

thanks again tho!
Feb 15 '07 #3
almaz
168 Expert 100+
The difference is that "union" without "all" filters duplicate records. It is much more expensive (in terms of CPU cost) comparing to "union all".
Feb 15 '07 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: Marco Simone | last post by:
Hi, I have 4 tables, tblCompany, tblA, tblB and tblC. tblA, tblB and tblC contain same type of data, they should be in one table, but since there are many fields, I split it into 3 tables. Each...
5
by: Lumpierbritches | last post by:
Thank you in advance. I have a database that I've written in Access 97 and have some clients using the program. My question is, when I update tables, so they don't loose their data, is there a way...
5
by: Megan | last post by:
Hi everybody- I'm helping a friend with a music database. She has an old one and is creating a new one. She wants to compare records and fields in the old database with records and fields in the...
7
by: Joe | last post by:
I am using Access 2003 and are linking to an Oracle 9i ODBC datasource (using Oracle ODBC drivers). After linking the tables in Access, I inspect the data contained in the linked tables. For...
11
by: dskillingstad | last post by:
I've been struggling with this problem for some time and have tried multiple solutions with no luck. Let me start with, I'm a novice at Access and I'm not looking for someones help to design my...
3
by: Reader | last post by:
Hello all, I am joining two tables in a query and the output should be all those records where two fields in table1 match two corresponding fields in table2. I joined the tables using both...
1
by: Monkey Boy | last post by:
I've used Access pretty basically for the last couple of years, and I'm slowly trying to get a bit more advanced. I'm attempting to consolidate multiple tables with similar information. Some...
4
by: is49460 | last post by:
Any help would be very appreciated!!! I have two tables: Main Data and Archived Data. Each table has the same fields (about 50 or so fields). Main data contains records that are updated every...
12
by: nyathancha | last post by:
Hi, I have a question regarding best practices in database design. In a relational database, is it wise/necessary to sometimes create tables that are not related to other tables through a...
4
by: gillianbrooks91 | last post by:
Forgive me for asking this question, I've trawled through nearly every available post on this subject that I can find for a few weeks now but nothing quite points me in the right direction. I'm...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
1
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
1
by: Defcon1945 | last post by:
I'm trying to learn Python using Pycharm but import shutil doesn't work
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...

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.