CREATE A TABLE FROM A UNION QUERY

S

Samora

Hello everyone

I have a query named QryExport that makes a UNION from 3
tables

My goal is to append the result of this query to a new table.

The table to receive the data is named TExport

The query i have to make the UNION is called Exportar

Although this query works great and gives me the result
that i am expecting , i want that this result could be
placed in that table (TExport) with one single field (125
characters ) in order i can export the result as a Text
file to be send by e-mail.

I am trying to make the SQl code , but it doesn't work and
there are sintaxe errors that i can't fix.

If someone can helps me , i would appreciate very much

Thanks in advance
 
G

gls858

Samora said:
Hello everyone

I have a query named QryExport that makes a UNION from 3
tables

My goal is to append the result of this query to a new table.

The table to receive the data is named TExport

The query i have to make the UNION is called Exportar

Although this query works great and gives me the result
that i am expecting , i want that this result could be
placed in that table (TExport) with one single field (125
characters ) in order i can export the result as a Text
file to be send by e-mail.

I am trying to make the SQl code , but it doesn't work and
there are sintaxe errors that i can't fix.

If someone can helps me , i would appreciate very much

Thanks in advance
Have you tried making your union query a make table query?
Open the query in design view right click the the upper portion
of the query, select query type > make table > give the table a name.

gls858
 
M

MacDermott

Hello, Samora!

When I need to create a new table from a union query, I use a second query
based on the first:
SELECT QryExport.* INTO TExport FROM QryExport

However, there's really no need to create a new table for exporting;
you can export directly from QryExport.

HTH
- Turtle
 

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

Similar Threads

UNION QUERY 1
SUM in a UNION query 2
Duplicates in union query 3
UNION QUERY.. 3
Code for union query 1
Run Make Table Query on Union Query 2
append with union query? 6
UNION ALL 25

Top