I asked this in Queries before, but I think my problem is of a different nature now.
My database is meant for faculty members at my university to scout out potential research partners with similar interests.
I have a table with faculty members' names, and then a list of about 54 keywords which might be applicable to that faculty member's research. Each keyword is its own field, and all of the keywords are Yes/No values.
An example [for arguments sake, using dummy keywords] runs like this, with the field names first:
Last: Miller
First: Larry
Blue: Yes
Red:
Green: Yes
Yellow:
Then the next entry, using those same fields, would be:
Last: Muldrich
First: Maria
Blue:
Red: Yes
Green: Yes
Yellow: Yes
My form has a list of all 54 keywords.
Suppose a faculty member wants the research interests "Blue" and "Red."
With the code I have now, neither Larry Miller nor Maria Muldrich would turn out, because neither one has BOTH Blue AND Red.
Instead, when a faculty member checks both "Blue" and "Red" on the form, I would like the query to return both Larry AND Maria, because they fit the criteria of having EITHER "Blue" OR "Red."
This is easy enough to do with just a query, put "True" in all the Or spots in the query.
Attaching this to the form is where I'm stuck. :banghead:
This was my original code:
(((IIf([forms]![Form1]![Check0],[Blue]=True,True))=True)) AND etc.
I tried changing the AND to OR in all of the lines. The query does not run at all and instead gives me my entire table.
My database is meant for faculty members at my university to scout out potential research partners with similar interests.
I have a table with faculty members' names, and then a list of about 54 keywords which might be applicable to that faculty member's research. Each keyword is its own field, and all of the keywords are Yes/No values.
An example [for arguments sake, using dummy keywords] runs like this, with the field names first:
Last: Miller
First: Larry
Blue: Yes
Red:
Green: Yes
Yellow:
Then the next entry, using those same fields, would be:
Last: Muldrich
First: Maria
Blue:
Red: Yes
Green: Yes
Yellow: Yes
My form has a list of all 54 keywords.
Suppose a faculty member wants the research interests "Blue" and "Red."
With the code I have now, neither Larry Miller nor Maria Muldrich would turn out, because neither one has BOTH Blue AND Red.
Instead, when a faculty member checks both "Blue" and "Red" on the form, I would like the query to return both Larry AND Maria, because they fit the criteria of having EITHER "Blue" OR "Red."
This is easy enough to do with just a query, put "True" in all the Or spots in the query.
Attaching this to the form is where I'm stuck. :banghead:
This was my original code:
(((IIf([forms]![Form1]![Check0],[Blue]=True,True))=True)) AND etc.
I tried changing the AND to OR in all of the lines. The query does not run at all and instead gives me my entire table.