#1   Report Post  
scos00
 
Posts: n/a
Default MS Query Date Format


I am having a problem passing a date parameter to MS Query.
Ultimately I want the parameter to be picked up from the Excel
spreadsheet but for the moment I can't even get it working in MS
Query.

In MS Query I create a new criteria with a value of [startdate] so that
when I execute it prompt me for the date. When I enter the date it
refuses to accept it, regardless of format. The error message depends
on the format I use. Since it is an Oracle database I get one of the
following:

- ORA-01843 Not a valid month
- ORA-01858 a non numeric character was found where a numeric was
expected
- ORA-01861 lieral does not match format string

If I enter a date directly in the criteria value field it works fine,
e.g. #10/10/2005#.
I have tried with and without the # in the prompt, plus I have tried
every conceivable date format and it won't accept it.
Of course it must be something to do with the fact that the underlying
database is Oracle but I just don't know how I can get round it. (I
tried DD-MON-RR, of course, which is the Oracle date format).

Any ideas??

Thanks.


--
scos00
------------------------------------------------------------------------
scos00's Profile: http://www.excelforum.com/member.php...o&userid=28264
View this thread: http://www.excelforum.com/showthread...hreadid=478261

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
Customized Date Format Frustrated Excel Worksheet Functions 5 October 7th 05 11:30 PM
format date in excel Nigel Excel Discussion (Misc queries) 2 September 15th 05 09:52 PM
Compare dates (one cell not in date format) craigcsb Excel Discussion (Misc queries) 5 June 28th 05 05:07 PM
How do I keep the date from changing format in a mail merge? Brynn Wilson Excel Discussion (Misc queries) 1 June 9th 05 06:44 PM
Excel enters date as a text format Kane Excel Discussion (Misc queries) 3 March 22nd 05 09:20 PM


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