I have a query which retrieves 5 fields called attendance
each field may or may not have a name in it
I need to calculate total attendance, up to 5 people obviously!
if there is a null entry the query returns a zero if there is an entry the field displays a 1.
example of function below (this bit works ok)
Att1: IIf(IsNull([Attendance1]),"0","1")
Att2: IIf(IsNull([Attendance2]),"0","1") etc.
I calculate total attendance with the following but it is not working.
NumAttendance: [Att1]+[Att2]+[Att3]+[Att4]+[Att5]
if all entries are null then i get 00000
if 1 3 and 5 are null i get 01010 instead of 2
TIA
It's gotta be so simple!!!
each field may or may not have a name in it
I need to calculate total attendance, up to 5 people obviously!
if there is a null entry the query returns a zero if there is an entry the field displays a 1.
example of function below (this bit works ok)
Att1: IIf(IsNull([Attendance1]),"0","1")
Att2: IIf(IsNull([Attendance2]),"0","1") etc.
I calculate total attendance with the following but it is not working.
NumAttendance: [Att1]+[Att2]+[Att3]+[Att4]+[Att5]
if all entries are null then i get 00000
if 1 3 and 5 are null i get 01010 instead of 2
TIA
It's gotta be so simple!!!