469,306 Members | 1,850 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,306 developers. It's quick & easy.

MOD Function in MS ACCESS

Hi. I'm a newbie regarding the use of MS Access and i have some problem that i would like to ask for a help or an answer..

i use this EXCEL formula
Expand|Select|Wrap|Line Numbers
  1. =IF(ISBLANK(I5),"",(NETWORKDAYS(F5,I5,HolidayList)-1)*(DayEnd-DayStart)+IF(NETWORKDAYS(I5,I5,HolidayList),MEDIAN(MOD(I5,1),DayEnd,DayStart),DayEnd)-MEDIAN(NETWORKDAYS(F5,F5,HolidayList)*MOD(F5,1),DayEnd,DayStart))
then i create the same system on MS Access. I created a query so that this function on MS Excel will also calculate/work on my MS Access Database. and i use this code.

Expand|Select|Wrap|Line Numbers
  1. IIf(ISBLANK([Date Forwarded to IRM]),"",(Workdays([Date Received by APA],[Date Forwarded to IRM])-1)*EndDate-StartDate)+IIF(Workdays([Date Forwarded to IRM],[Date Forwarded to IRM]), MEDIAN(MOD([Date Forwarded to IRM],1),EndDate,StartDate),EndDate)-MEDIAN(Workdays([Date Received by APA],[Date Received by APA])*MOD([Date Received by APA],1),EndDate,StartDate))
and theres an error appearing on my screen saying The expression you entered contains invalid intax. You may have entered a comma without a preceding value or identifier.

Then when i click Okay. the word "MOD" is highlighted.

may anyone please help me on my problem? I'll appreciate every reply and suggestion. Thank you in advanced :)
Mar 7 '12 #1

✓ answered by Rabbit

The same way you would add two numbers. + is an operator, - is an operator, mod is an operator.

6 8659
12,516 Expert Mod 8TB
In Access, it's an operator and not a function.
Mar 7 '12 #2
but am i able to use that operator on that kind of computation?
Mar 8 '12 #3
12,516 Expert Mod 8TB
You can use it, you just have to use it like an operator, not a function.
Mar 8 '12 #4
Thanks Rabbit but im a little bit confuse on how can i use it as an operator?
Mar 8 '12 #5
12,516 Expert Mod 8TB
The same way you would add two numbers. + is an operator, - is an operator, mod is an operator.
Mar 8 '12 #6
32,173 Expert Mod 16PB
Expand|Select|Wrap|Line Numbers
  1. X = Y Mod Z
This sets X to the remainder value when Y is divided by Z. If you need more explanation then the Help system will give you more than any person could require. See Context-Sensitive Help for how to find anything you need.
Mar 8 '12 #7

Post your reply

Sign in to post your reply or Sign up for a free account.

Similar topics

reply views Thread by chip0312 | last post: by
16 posts views Thread by bobueland | last post: by
8 posts views Thread by Sullivan WxPyQtKinter | last post: by
1 post views Thread by CARIGAR | last post: by
reply views Thread by suresh191 | last post: by
reply views Thread by harlem98 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.