How to import/export datas by writing query??

  • Thread starter Thread starter Guest
  • Start date Start date
Um, can you be a bit more specific in your question? You can certainly write a query and then export the data that the query returns, and you can write a query based on another query and export the data from it; importing is a different process and always related to tables and not to queries at all...
 
thanx for the attention,
actually i have one excel file which i want to import
through a query & after some calculation parts(which will
be done by database),it will store the value in database
and the result need to be exported in an excel file too.
i know macros could solve this problem but i want to
write queries 1 for import & another for export. i think
i have described what i want to do. plzz reply.

-----Original Message-----
Um, can you be a bit more specific in your question? You
can certainly write a query and then export the data that
the query returns, and you can write a query based on
another query and export the data from it; importing is a
different process and always related to tables and not to
queries at all...
 
You can use syntax like this to work with data in Excel sheets:

SELECT *
FROM
[Excel 8.0;HDR=Yes;database=C:\File.xls;].[Sheet1$A10:E20]
;

Make-table (export):
SELECT ID, FirstName, LastName
INTO [Excel 8.0;HDR=Yes;Database=C:\File.xls;].[Sheet]
FROM MyTable
;

If you go to http://groups.google.com and search this group for posts by
Jamie Collins, you'll find more examples.
 
Back
Top