Need Help with MS Query and EXCEL

rgildoss

New Member
Joined
Oct 13, 2002
Messages
9
Ok , this may sound weird but here goes.

I’m doing a Database query ( in EXCEL through MS Query ), the query requires dates such as,

Created Date: >=#8/1/2002 12:00:01 AM# And <=#8/31/2002 11:59:59 PM#

The above string gives me everything recorded ( in the database ) between the dates 8/1/02 and 8/31/02

My question:

Is there away to created a field in the Excel spreadsheet that I can input the date I want to search without going into the MS Query and changing the date?

This is really bugging me. Every time I run the query I have to go in and change the dates, it would be nice if I could just input the date into a box or a field and have the ms query do search on that date.


PLEASE HELP!!!!
 

Excel Facts

Excel Joke
Why can't spreadsheets drive cars? They crash too often!

dk

MrExcel MVP
Joined
Feb 15, 2002
Messages
2,942
Hi,

This thread may be of some use. If not, post the SQL of your query. The jist of it is, you can use cell references if you use VBA, or you can have an inputbox displayed which can ask you for the dates you want.



_________________<font face="Impact">Hope this helps,
Dan</font>
This message was edited by dk on 2002-10-14 13:05
 

rgildoss

New Member
Joined
Oct 13, 2002
Messages
9
Ok , i did try some of the sug that people made on the other thread, however i still get a error when i try to send data back to the excel sheet, i get a pop up with
"Parameter Missing"

Im also using office XP
( not sure if that does anything )

Below is the past of SQL:

SELECT "RPMS Problem Report"."Customer Name", "RPMS Problem Report"."1_Entry-Id", "RPMS Problem Report"."3_Create-date", "RPMS Problem Report"."8_Short-Description", "RPMS Problem Report"."7_Status", "RPMS Problem Report".Severity
FROM "RPMS Problem Report" "RPMS Problem Report"
WHERE ("RPMS Problem Report"."3_Create-date">={ts '2002-03-10 00:00:01.000'} And "RPMS Problem Report"."3_Create-date"<={ts '2002-03-16 23:59:59.000'}) AND ("RPMS Problem Report"."CBG LOB"='Staff Legal')
 

Mark W.

MrExcel MVP
Joined
Feb 10, 2002
Messages
11,654
See the Excel Help topic for "Create a query that prompts for criteria".
 

Forum statistics

Threads
1,144,510
Messages
5,724,777
Members
422,576
Latest member
kayth891

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top