Pergunta

How to use OR in IIF statement in SSRS

=IIF((Fields!txtCurrentSubjectReportName.Value="",
      Fields!txtSubjectArchivedName.Value,
      Fields!txtCurrentSubjectReportName.Value) = "School Life" 
      OR 
      "My goal for this term..." 
      OR 
      "Student Reflective Comment", True, False)

Its throwing error

Foi útil?

Solução

=IIF(Fields!txtCurrentSubjectReportName.Value="",
     Fields!txtSubjectArchivedName.Value,
     Fields!txtCurrentSubjectReportName.Value) = "School Life" 
 OR 
 IIF(Fields!txtCurrentSubjectReportName.Value="",
     Fields!txtSubjectArchivedName.Value,
     Fields!txtCurrentSubjectReportName.Value) = "My goal for this term..." 
 OR 
 IIF(Fields!txtCurrentSubjectReportName.Value="",
     Fields!txtSubjectArchivedName.Value,
     Fields!txtCurrentSubjectReportName.Value) = "Student Reflective Comment"

The result is boolean itself and does not need in additional IIF().

Licenciado em: CC-BY-SA com atribuição
Não afiliado a dba.stackexchange
scroll top