Forum Discussion
IF FUNCTION AND ROUNDUP
- May 08, 2017
When it's something like this
=WEEKNUM(IF(ISBLANK(<hired off date>),TODAY(), <hired off date>)) - WEEKNUM(<hired on date>)
Perhaps plus 1 depends on how do you calculte not full week, as zero or as 1.
Ok so I have to know how many weeks have passed.
One column is called 'HIRED ON DATE' the other column is called 'HIRED OFF DATE'. I then need a column that says 'WEEKS HIRED TO DATE'. It needs to calculate the amount of weeks from HIRED ON DATE until HIRED OFF DATE or if no date is entered into HIRED OFF then it needs to use TODAYS date.
Thanks in advance x
- SergeiBaklanMay 08, 2017Diamond Contributor
When it's something like this
=WEEKNUM(IF(ISBLANK(<hired off date>),TODAY(), <hired off date>)) - WEEKNUM(<hired on date>)
Perhaps plus 1 depends on how do you calculte not full week, as zero or as 1.
- Zoe JefferyMay 08, 2017Copper ContributorI still need help!
- SergeiBaklanMay 08, 2017Diamond Contributor
Hi Zoe,
Let split on two parts. First one returns fired day or today if fired day is empty, assuming you have them in column B
=IF(ISBLANK(B2),TODAY(),B2)
If hiring days in column A when number of weeks between these two days will be
=ROUNDUP((IF(ISBLANK(B2),TODAY(),B2)-A2)/7,0)
I'm sorry for previous formula, weeknum returns the week number within the year, it'l be simply to use your ROUNDUP
- Zoe JefferyMay 08, 2017Copper Contributor
Sergi I couldnt get that to work. What is the - you have in the formula before the second WEEKNUM?
=WEEKNUM(IF(ISBLANK(<hired off date>),TODAY(), <hired off date>)) -
WEEKNUM(<hired on date>)