Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default VBA - query an Access table - results in Excel

Using VBA, I want to query an Access database table which has 240,000
records. The data I am quering for is from a worksheet (sheet1) and I would
like the results stored in an Excel worksheet (sheet2). The results from the
query will be only a few thousand records, never greater than 10,000. The
Access db and Excel sheet are on the same PC. Eventually I will need to query
the Access DB from a different PC across a network.
What is the best way to do this?

Thanks,

rirus
  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 249
Default VBA - query an Access table - results in Excel

I'd use ADO This article may help.

http://support.microsoft.com/kb/257819/

--

Regards,

Dave Patrick ....Please no email replies - reply in newsgroup.
Microsoft Certified Professional
Microsoft MVP [Windows]
http://www.microsoft.com/protect

"rirus" wrote:
| Using VBA, I want to query an Access database table which has 240,000
| records. The data I am quering for is from a worksheet (sheet1) and I
would
| like the results stored in an Excel worksheet (sheet2). The results from
the
| query will be only a few thousand records, never greater than 10,000. The
| Access db and Excel sheet are on the same PC. Eventually I will need to
query
| the Access DB from a different PC across a network.
| What is the best way to do this?
|
| Thanks,
|
| rirus


  #3   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 11,123
Default VBA - query an Access table - results in Excel

Maybe you can use this
http://www.rondebruin.nl/accessexcel.htm

--
Regards Ron de Bruin
http://www.rondebruin.nl



"rirus" wrote in message ...
Using VBA, I want to query an Access database table which has 240,000
records. The data I am quering for is from a worksheet (sheet1) and I would
like the results stored in an Excel worksheet (sheet2). The results from the
query will be only a few thousand records, never greater than 10,000. The
Access db and Excel sheet are on the same PC. Eventually I will need to query
the Access DB from a different PC across a network.
What is the best way to do this?

Thanks,

rirus



  #4   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 2
Default VBA - query an Access table - results in Excel

I set up an ODBC for the Access database and then added a tablequery in the
Excel worksheet. So far that is working great and is getting what I need.
Surprisingly, the query takes seconds to run which is faster than what I
expected. I am not sure though how it will work across a network. Hopefully
the retrieval rate will not change too much.

Thanks for your inputs. They have been helpful.

rirus


"Ron de Bruin" wrote:

Maybe you can use this
http://www.rondebruin.nl/accessexcel.htm

--
Regards Ron de Bruin
http://www.rondebruin.nl



"rirus" wrote in message ...
Using VBA, I want to query an Access database table which has 240,000
records. The data I am quering for is from a worksheet (sheet1) and I would
like the results stored in an Excel worksheet (sheet2). The results from the
query will be only a few thousand records, never greater than 10,000. The
Access db and Excel sheet are on the same PC. Eventually I will need to query
the Access DB from a different PC across a network.
What is the best way to do this?

Thanks,

rirus




Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
No Results returned from Access query Chuck W[_2_] Excel Discussion (Misc queries) 3 September 23rd 09 03:37 PM
Why are access query results different in Excel DannyD Excel Discussion (Misc queries) 0 July 29th 07 04:54 AM
Access query results to Excel piano banger Excel Discussion (Misc queries) 4 December 8th 06 09:32 AM
Copy the results of an Access query into an Excel spreadsheet lylo Excel Programming 3 July 27th 04 12:46 PM
Linking a table in Access to a table in Excel using MS Query Diana[_5_] Excel Programming 1 January 16th 04 09:43 PM


All times are GMT +1. The time now is 01:00 PM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"