A Microsoft Office (Excel, Word) forum. OfficeFrustration

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » OfficeFrustration forum » Microsoft Access » Setting Up & Running Reports
Site Map Home Register Authors List Search Today's Posts Mark Forums Read  

datediff



 
 
Thread Tools Display Modes
  #1  
Old July 11th, 2007, 09:45 PM posted to microsoft.public.access.reports
greenbg via AccessMonster.com
external usenet poster
 
Posts: 14
Default datediff

hi
I am trying to get a list of name who's birthday is 35 of days away. I have
build a query with all of the information the I need. Under the field birth I
enter the following criteria:
IIf(DateDiff("d",[birth],Date())=35,[TITLE]+" "+[LNAME]," ")

I get an error 3464 (Data Type Mismatch in criteria expression)

In my table Birth is setup the following way:
Date/Time
Medium Date

--
Message posted via AccessMonster.com
http://www.accessmonster.com/Uwe/For...ports/200707/1

  #2  
Old July 14th, 2007, 03:06 AM posted to microsoft.public.access.reports
Duane Hookom
external usenet poster
 
Posts: 7,177
Default datediff

You have entered this expression where? Are you wishing to filter your
records to only babies that are less than 36 days old? If so, create a new
column in your query with an expression like:
DaysOld: DateDiff("d",[birth],Date())
and set the criteria to
=35
--
Duane Hookom
Microsoft Access MVP


"greenbg via AccessMonster.com" wrote:

hi
I am trying to get a list of name who's birthday is 35 of days away. I have
build a query with all of the information the I need. Under the field birth I
enter the following criteria:
IIf(DateDiff("d",[birth],Date())=35,[TITLE]+" "+[LNAME]," ")

I get an error 3464 (Data Type Mismatch in criteria expression)

In my table Birth is setup the following way:
Date/Time
Medium Date

--
Message posted via AccessMonster.com
http://www.accessmonster.com/Uwe/For...ports/200707/1


 




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Forum Jump


All times are GMT +1. The time now is 09:11 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 OfficeFrustration.
The comments are property of their posters.