From: PlarfySoober on 15 Apr 2010 15:43 I have created a query, all the fields from an existing table. One field has a date format. I want to select for records in which that field contains data. I tried >"01/01/2000", but no joy. Message was "Data type mismatch in query expression." This is the way to create this criteria, AFAICT in the Help file, where it shows > '01 Jan 1995' as the proper way to select for later dates than that one. But mine doesn't work. Thanks in advance. Don.
From: Douglas J. Steele on 15 Apr 2010 15:48 Dates need tobe delimited with #, not quotes. Try > #01/01/2000# or > #01 Jan 1995# -- Doug Steele, Microsoft Access MVP http://www.AccessMVP.com/DJSteele (no e-mails, please!) "PlarfySoober" <PlarfySoober(a)discussions.microsoft.com> wrote in message news:B5252B24-485E-4D1F-A84A-7D11F0CAB5F8(a)microsoft.com... >I have created a query, all the fields from an existing table. > > One field has a date format. I want to select for records in which that > field contains data. > > I tried >"01/01/2000", but no joy. Message was "Data type mismatch in > query > expression." This is the way to create this criteria, AFAICT in the Help > file, where it shows > '01 Jan 1995' as the proper way to select for later > dates than that one. But mine doesn't work. > > Thanks in advance. > > Don. >
From: PlarfySoober on 15 Apr 2010 18:36 Just as you said. And the Help file is wrong, because it makes no mention of using ## instead of '' or "". Thank you very much. "Douglas J. Steele" wrote: > Dates need tobe delimited with #, not quotes. > > Try > > > #01/01/2000# > > or > > > #01 Jan 1995# > > -- > Doug Steele, Microsoft Access MVP > http://www.AccessMVP.com/DJSteele > (no e-mails, please!) > > "PlarfySoober" <PlarfySoober(a)discussions.microsoft.com> wrote in message > news:B5252B24-485E-4D1F-A84A-7D11F0CAB5F8(a)microsoft.com... > >I have created a query, all the fields from an existing table. > > > > One field has a date format. I want to select for records in which that > > field contains data. > > > > I tried >"01/01/2000", but no joy. Message was "Data type mismatch in > > query > > expression." This is the way to create this criteria, AFAICT in the Help > > file, where it shows > '01 Jan 1995' as the proper way to select for later > > dates than that one. But mine doesn't work. > > > > Thanks in advance. > > > > Don. > > > > > . >
|
Pages: 1 Prev: Criteria Parameter in query for two fields: help Next: redo my design |