ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Excel query to access database (https://www.excelbanter.com/excel-discussion-misc-queries/261562-excel-query-access-database.html)

Piotr

Excel query to access database
 
Hi,

Could you help me to find solution for my problem please?

Im not very good in Excel and Access but have to create Excel spread sheet
which will take data from Access DB. I almost done it but have one problem
which not able to find solution.

When I create query in Excel using €śQuery Wizard€ť there is a step called
€śFilter Data€ť. I would like to use filter for the table like that: Company
Name €“ equals €“ Contoso. My problem is that instead using €śContoso€ť I would
like to take value from filed in Excel document (like $c$2).

Is it possible? How to do this?

Thank you and Kind Regards


Jarek Kujawa[_2_]

Excel query to access database
 
record a macro while creating the query
Tools-Macro-Macros and select your macro, press Edit
go to the SELECT clause and change your filtering condition
accordingly

from
"WHERE (Company Name='Contoso')")

to
"WHERE (Company Name=" & Range("F1").Value & ")")

then use the macro every time you need to generate new data

HIH
pls click YES if it was helpful


On 15 Kwi, 10:53, Piotr wrote:
Hi,

Could you help me to find solution for my problem please?

I’m not very good in Excel and Access but have to create Excel spread sheet
which will take data from Access DB. I almost done it but have one problem
which not able to find solution.

When I create query in Excel using “Query Wizard” there is a step called
“Filter Data”. I would like to use filter for the table like that: Company
Name – equals – Contoso. My problem is that instead using “Contoso” I would
like to take value from filed in Excel document (like $c$2).

Is it possible? How to do this?

Thank you and Kind Regards



Piotr

Excel query to access database
 
Dziekuje bardzo za pomoc i pozdrawiam.

"Jarek Kujawa" wrote:

record a macro while creating the query
Tools-Macro-Macros and select your macro, press Edit
go to the SELECT clause and change your filtering condition
accordingly

from
"WHERE (Company Name='Contoso')")

to
"WHERE (Company Name=" & Range("F1").Value & ")")

then use the macro every time you need to generate new data

HIH
pls click YES if it was helpful


On 15 Kwi, 10:53, Piotr wrote:
Hi,

Could you help me to find solution for my problem please?

Im not very good in Excel and Access but have to create Excel spread sheet
which will take data from Access DB. I almost done it but have one problem
which not able to find solution.

When I create query in Excel using €śQuery Wizard€ť there is a step called
€śFilter Data€ť. I would like to use filter for the table like that: Company
Name €“ equals €“ Contoso. My problem is that instead using €śContoso€ť I would
like to take value from filed in Excel document (like $c$2).

Is it possible? How to do this?

Thank you and Kind Regards


.


Jarek Kujawa[_2_]

Excel query to access database
 
proszÄ™ bardzo

postaw mi proszę ocenę (gwiazdki) jeśli Ci pomogłem

On 15 Kwi, 14:40, Piotr wrote:
Dziekuje bardzo za pomoc i pozdrawiam.



"Jarek Kujawa" wrote:
record a macro while creating the query
Tools-Macro-Macros and select your macro, press Edit
go to the SELECT clause and change your filtering condition
accordingly


from
"WHERE (Company Name='Contoso')")


to
"WHERE (Company Name=" & Range("F1").Value & ")")


then use the macro every time you need to generate new data


HIH
pls click YES if it was helpful


On 15 Kwi, 10:53, Piotr wrote:
Hi,


Could you help me to find solution for my problem please?


Im not very good in Excel and Access but have to create Excel spread sheet
which will take data from Access DB. I almost done it but have one problem
which not able to find solution.


When I create query in Excel using €śQuery Wizard€ť there is a step called
€śFilter Data€ť. I would like to use filter for the table like that: Company
Name €“ equals €“ Contoso. My problem is that instead using €śContoso€ť I would
like to take value from filed in Excel document (like $c$2).


Is it possible? How to do this?


Thank you and Kind Regards


.- Ukryj cytowany tekst -


- PokaĹĽ cytowany tekst -




All times are GMT +1. The time now is 01:41 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com