Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Pivot table - issue using query parameter?

Status
Not open for further replies.

Kobayashi

Technical User
Oct 11, 2001
69
0
0
US
Using Access 2000:

I have created a pivot table based on a pretty basic select query. However, I need to filter the query by certain dates. Now, if I hardcode the dates into the query, for example, 'Between 01/01/2004 and 01/01/2005' then the pivot will run fine. However, if, as I would like, I place a parameter in the query - 'Between [Enter beginning date] and [Enter end date] - then the pivot table will not open and cannot obtain the data?

Any ideas how to resolve this?

Help, as always, is much appreciated.

Thanks,

Adrian
 
You have to declare the parameters in BOTH queries:
PARAMETERS [Enter beginning date] DateTime, [Enter end date] DateTime;
TRANSFORM ...

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
PHV,

Many thanks but could you expand a little please? Both queries???

Thanks,

Adrian
 
Ph,

I have added the parameter to the SQL but I am still 'Unable to obtain data' when I edit the pivot table and try to refresh?

Any ideas?

Thanks,

Adrian
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top