Access 2007 Filter a Calculated IF Statement Field -


i have query has calculated field:

montheligible: iif([5yranniv]>=dateserial(year(date()),month(date())+1,1),[5yranniv],iif([5yranniv]<=dateserial(year(date()),month(date())+1,1),dateserial(year(date()),month(date())+1,1),"")) 

and have field that's calculate based on this:

eligible?: iif(datepart("m",[montheligible])=(datepart("m",date())+1),"yes","no") 

basically, first 1 calculates month in eligible, , second 1 says "yes" if month next month, or "no" if isn't.

from there, want filter second field show yes records. when put "yes" in criteria , click view, access prompts me put in value [montheligible]. how not this? want use existing [montheligible] field works when there's no criteria.

you logic makes little sense. after, this:

montheligible: iif([5yranniv]>dateserial(year(date()),month(date())+1,1),[5yranniv],dateserial(year(date()),month(date())+1,1))  eligible: iif(datediff("m",date(),[5yranniv])>1,"yes","no") 

Comments

Popular posts from this blog

node.js - Mongoose: Cast to ObjectId failed for value on newly created object after setting the value -

gradle error "Cannot convert the provided notation to a File or URI" -

python - NameError: name 'subprocess' is not defined -