Hi Guys,
I'm wondering if you could help me.
I have a nested IF AND formula which I can't get quite right - I must have been over it a million times.
Essentially what I'm trying to do is work out the status of an individual based on a date range.
The formula is:
=IF(ISERROR(IF(AND(C3>=Headcount!$D$13,AC3<=Headcount!$D$14),"Hired and Terminated in Period",IF(AND(C3>=Headcount!$D$13,C3<=Headcount!$D$14),"Hired in Period",IF(AND(AC3>=Headcount!$D$13,AC3<=Headcount!$D$14),"Terminated in Period",IF(AC3<Headcount!$D$13,"Terminated in Prior Period",IF(C3>=Headcount!$D$14,"Future Period Hire","Active in Period")))))),"",IF(AND(C3>=Headcount!$D$13,AC3<=Headcount!$D$14),"Hired and Terminated in Period",IF(AND(C3>=Headcount!$D$13,C3<=Headcount!$D$14),"Hired in Period",IF(AND(AC3>=Headcount!$D$13,AC3<=Headcount!$D$14),"Terminated in Period",IF(AC3<Headcount!$D$13,"Terminated in Prior Period",IF(C3>=Headcount!$D$14,"Future Period Hire","Active in Period"))))))
C3 = Hire Date
AC3 = Termination Date
$D$13 = Period Start Date
$D$14 = Period End Date
For the majority of people it seems to work fine.
I've got one record for instance for Joe Bloggs, whose:
Hire date is 03/08/2020
Termination date is 06/04/2020
The end result for Joe should be Active in Period, whereas it currently states Terminated in Prior Period.
Any help would be much appreciated.
Thanks,
Sam
I'm wondering if you could help me.
I have a nested IF AND formula which I can't get quite right - I must have been over it a million times.
Essentially what I'm trying to do is work out the status of an individual based on a date range.
The formula is:
=IF(ISERROR(IF(AND(C3>=Headcount!$D$13,AC3<=Headcount!$D$14),"Hired and Terminated in Period",IF(AND(C3>=Headcount!$D$13,C3<=Headcount!$D$14),"Hired in Period",IF(AND(AC3>=Headcount!$D$13,AC3<=Headcount!$D$14),"Terminated in Period",IF(AC3<Headcount!$D$13,"Terminated in Prior Period",IF(C3>=Headcount!$D$14,"Future Period Hire","Active in Period")))))),"",IF(AND(C3>=Headcount!$D$13,AC3<=Headcount!$D$14),"Hired and Terminated in Period",IF(AND(C3>=Headcount!$D$13,C3<=Headcount!$D$14),"Hired in Period",IF(AND(AC3>=Headcount!$D$13,AC3<=Headcount!$D$14),"Terminated in Period",IF(AC3<Headcount!$D$13,"Terminated in Prior Period",IF(C3>=Headcount!$D$14,"Future Period Hire","Active in Period"))))))
C3 = Hire Date
AC3 = Termination Date
$D$13 = Period Start Date
$D$14 = Period End Date
For the majority of people it seems to work fine.
I've got one record for instance for Joe Bloggs, whose:
Hire date is 03/08/2020
Termination date is 06/04/2020
The end result for Joe should be Active in Period, whereas it currently states Terminated in Prior Period.
Any help would be much appreciated.
Thanks,
Sam