group multiple query in one query

G

Guest

hi everyone...
I've been looking in the posts for what i need but i didn't find it....

i have multiple query's with the same field names

query 1:
fields | value
field 1 : A
field 2 : 123
field 3 : abc
query 2:
field 1 : B
field 2 : 456
field 3 : def

what i want is a query with the result of query 1 and 2

A 123 abc
B 456 def

can anyone help me, please????
--
Thanks,

Sorry if my english isn''t correct, but I''m from Potugal ;)

Emanuel Violante Galeano
 
G

Guest

What you want is a UNION query. You can only build it in SQL View. After
you have the first table elements in the query change to the SQL View to see
something like this ---
SELECT Field1, Field2, Field3
FROM Table1;
Copy, paste and edit to look like this --
SELECT Field1, Field2, Field3
FROM Table1
UNION ALL SELECT Field1, Field2, Field3
FROM Table1
UNION ALL SELECT Field1, Field2, Field3
FROM Table1;
The edits removes all but the last semicolon. Insert UNION ALL before all
but the first SELECT.
You will not be able to view the query in design view.
Omit the ALL to omit duplicates records.
 
G

Guest

Thank you verry much Karl, that'sexactly what I needed

=D

--
Thanks,

Sorry if my english isn''t correct, but I''m from Potugal ;)

Emanuel Violante Galeano
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top