Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.programming
dan dan is offline
external usenet poster
 
Posts: 866
Default Using values in Excel as parameters in Microsoft Query connection

I currently have an Excel sheet containing data, and I'd like to create a SQL
query where parameters in my query are fields in my Excel sheet. I know how
to create a SQL query or other data connection, but I don't know how to
include my Excel data as a datasource in the query. Is this possible, and, if
so, how would I do it?


Thanks in advance,
Dan

  #2   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 43
Default Using values in Excel as parameters in Microsoft Query connection

Dan,

You can do this by using the importing external data query:

1) Go to data, import external data, new database query
2) Select or browse to the database you wish to connect to
3) Click cancel in the next screen and Click yes to open the macro Query
editor
4) Create your query and add filters to it
5) In the filter list enter "[Your description]"
6) Return the data to excel
7) Click on the Parameter button and select the cell where your criteria
houses.

Regards,

Brotha lee


"Dan" wrote:

I currently have an Excel sheet containing data, and I'd like to create a SQL
query where parameters in my query are fields in my Excel sheet. I know how
to create a SQL query or other data connection, but I don't know how to
include my Excel data as a datasource in the query. Is this possible, and, if
so, how would I do it?


Thanks in advance,
Dan

  #3   Report Post  
Posted to microsoft.public.excel.programming
dan dan is offline
external usenet poster
 
Posts: 866
Default Using values in Excel as parameters in Microsoft Query connect

Sorry; I should have mentioned that I'm using Excel 2007. I know that you can
filter your results in 2007, as you mention below, but don't remember how &
have had no luck using Excel Help.





"Brotha Lee" wrote:

Dan,

You can do this by using the importing external data query:

1) Go to data, import external data, new database query
2) Select or browse to the database you wish to connect to
3) Click cancel in the next screen and Click yes to open the macro Query
editor
4) Create your query and add filters to it
5) In the filter list enter "[Your description]"
6) Return the data to excel
7) Click on the Parameter button and select the cell where your criteria
houses.

Regards,

Brotha lee


"Dan" wrote:

I currently have an Excel sheet containing data, and I'd like to create a SQL
query where parameters in my query are fields in my Excel sheet. I know how
to create a SQL query or other data connection, but I don't know how to
include my Excel data as a datasource in the query. Is this possible, and, if
so, how would I do it?


Thanks in advance,
Dan

  #4   Report Post  
Posted to microsoft.public.excel.programming
dan dan is offline
external usenet poster
 
Posts: 866
Default Using values in Excel as parameters in Microsoft Query connect

Never mind...just figured it out. Thanks for the help.


"Dan" wrote:

Sorry; I should have mentioned that I'm using Excel 2007. I know that you can
filter your results in 2007, as you mention below, but don't remember how &
have had no luck using Excel Help.





"Brotha Lee" wrote:

Dan,

You can do this by using the importing external data query:

1) Go to data, import external data, new database query
2) Select or browse to the database you wish to connect to
3) Click cancel in the next screen and Click yes to open the macro Query
editor
4) Create your query and add filters to it
5) In the filter list enter "[Your description]"
6) Return the data to excel
7) Click on the Parameter button and select the cell where your criteria
houses.

Regards,

Brotha lee


"Dan" wrote:

I currently have an Excel sheet containing data, and I'd like to create a SQL
query where parameters in my query are fields in my Excel sheet. I know how
to create a SQL query or other data connection, but I don't know how to
include my Excel data as a datasource in the query. Is this possible, and, if
so, how would I do it?


Thanks in advance,
Dan

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
How to store a connection with parameters into a workbook Tom Edelbrok Excel Discussion (Misc queries) 0 November 9th 09 07:16 PM
Excel Query Parameters jason Excel Discussion (Misc queries) 1 February 8th 09 10:02 PM
Microsoft Query - pull data from Access "Too many parameters" Donica Excel Programming 0 April 11th 07 05:18 PM
Run an Access Query from Excel VBA with Parameters SupperDuck Excel Programming 1 March 2nd 07 03:39 PM
Microsoft query won't allow parameters kmoyer Excel Programming 3 March 31st 06 07:08 AM


All times are GMT +1. The time now is 07:20 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"