J
Jacqueline
In my Access 2000 mdb I am trying to create a report that
must choose the correct mailing address to send the
letter to...
The database holds 3 sets of mailing address for the
medical school applicants...Present...Permanent and Other
My problem is this...on that form there is also a
question which asks:
To which address do you want the final results sent:
Present...Permanent...Other (these are 3
checkboxes....table values 0 and -1)
My ? is: if a student checks off they want their final
results sent to...say their Present address...how do I
display the correct address in the query that runs the
report?
I know it must be some kind of IIF statement that would
need to check which of the 3 boxes are checked...but I
started with this field and am getting an error:
Circular reference caused by Alias Address1 in query
definition's Select List.
Address1: IIf([Send_Results_Pres]= -1,[Address1], IIf
([Send_Results_Perm]= -1,[Perm_Address1],
[Other_Address1]))
The sql view....
SELECT dbo_Users.User_Firstname, dbo_Users.User_Lastname,
IIf([Send_Results_Pres]=-1,[Address1],IIf
([Send_Results_Perm]=-1,[Perm_Address1],
[Other_Address1])) AS Address1
FROM dbo_Users INNER JOIN dbo_Personal ON
dbo_Users.User_ID = dbo_Personal.PersonalID;
must choose the correct mailing address to send the
letter to...
The database holds 3 sets of mailing address for the
medical school applicants...Present...Permanent and Other
My problem is this...on that form there is also a
question which asks:
To which address do you want the final results sent:
Present...Permanent...Other (these are 3
checkboxes....table values 0 and -1)
My ? is: if a student checks off they want their final
results sent to...say their Present address...how do I
display the correct address in the query that runs the
report?
I know it must be some kind of IIF statement that would
need to check which of the 3 boxes are checked...but I
started with this field and am getting an error:
Circular reference caused by Alias Address1 in query
definition's Select List.
Address1: IIf([Send_Results_Pres]= -1,[Address1], IIf
([Send_Results_Perm]= -1,[Perm_Address1],
[Other_Address1]))
The sql view....
SELECT dbo_Users.User_Firstname, dbo_Users.User_Lastname,
IIf([Send_Results_Pres]=-1,[Address1],IIf
([Send_Results_Perm]=-1,[Perm_Address1],
[Other_Address1])) AS Address1
FROM dbo_Users INNER JOIN dbo_Personal ON
dbo_Users.User_ID = dbo_Personal.PersonalID;