[AccessD] Date Comparison Problem

Stuart McLachlan stuart at lexacorp.com.pg
Thu Mar 30 15:56:33 CST 2006


On 30 Mar 2006 at 9:03, Rocky Smolin - Beach Access S wrote:

> Well I spoke (or wrote) a little too soon.  There's another statement,
> preceding the others which works right in US date format but not in UK
> format.  The statement reads:
> 
>     rstManpower.FindFirst "fldManpowerDate = #" & datCurrentDate & "# 
> AND " _

Access SQL likes it's dates in US format.

To get around the problem where the PC can have any regional setting, I 
always use:
...fldManpowerDate = Datevalue('" & datCurrentDate & "').....
when building these sorts of strings.


-- 
Stuart





More information about the AccessD mailing list