I am checking to make sure that if person A identifies person B as his/her spouse, then person B also identifies person A as his/her spouse. I used the example in the Standard Survey Modules - Household Roster - spouse_pid_1, verification #3 as an example of the logic. The code I tried is given below. memfamily is the name of the roster; name_spouse is a single-select question linked to the roster with the names of the household members.
memfamily[self].name_spouse==@rowcode : true
When I test the code, and answer the questions for the first person in the roster, the condition “memfamily[self].IsAnswered(name_spouse)” is being evaluated as True even though I have not yet answered any question for any other household members, and the filter on the question excludes the current person’s name from being displayed. I even tried hard coding a specific row number “memfamily.IsAnswered(name_spouse)” (which should refer to the second person in the household) and it still evaluated as True even though questions for that person had not been answered. There is no problem using IsAnswered without referencing another row (i.e. I tried it just referring to a question for the current person and it evaluated correctly).