Converting Query Result into an Input Table

C

carl

I have a large query result (approximately 4 million records). I need to
convert it into a data table inorder to use the Pivot Table Function (Pivot
Table Funtion does not work on the query result).

Can someone walk me through how I can convert the query result into a data
table ?

Thank you in advance.
 
O

Ofer

If you dont want to change the existing query, create a new query that
includes all the fields from the existing query, and change it to a create
new table query

You can use this SQL, just change the name of the table and query to suit
your needs

SELECT QueryName.* INTO TableName
FROM QueryName
 
C

carl

Thank you Ofer. This may be the perfect solution.

I am not familiar with setting up an SQL for Access.

Can you provide some basic starting points ?

Thank you again.
 
D

DLG

You can use a Make Table Query to do this once and then in the future use an
append query. Here are the steps:
1. Open your existing query in Design view, select Query, Make Table, fill
in the blank with new table name, save query with new name, run query to
create and fill table.
2. create new Delete query to empty the table you just made
3. Open the Make Table query you just created, change it to an append query
that will fill the table, save it with a new name.

Now you can run the delete query followed by the append query to get current
data before the pivot table gets filled.
 
O

Ofer

Open a new query, change the view of the query to SQL.

Paste this SQL I provided you with into it

SELECT QueryName.* INTO TableName
FROM QueryName

Change the Name of the query to your QueryName, and give the TableName a
name for a new table
 
C

carl

Thank for trying to help. I am new to Access.

I have tried what you have suggested but am getting an error message
"Invalid Argument".

Any thoughts ?
 
C

carl

Thanks again. Here's what I tried:

SELECT FilterNCSCode.* INTO Table1
FROM FilterNCSCode;

The original query is named FilterNCSCode.
 
O

Ofer

Its look fine,
If you ran the query,FilterNCSCode, by itself, do you get any errors?
Can you post the sql of the query - FilterNCSCode
 
C

carl

Thanks Again for helping. Here is the "SQL" of the query. I set the query up
using the design view (if that makes a difference).

SELECT sept27.*
FROM sept27
WHERE (((sept27.NSC_Code) Between [Start] And [End]));
 
Top