How would I perform a Where, in a SQL command, only if the item is not equal to "<All>"
Currently I have
WHERE Q4.AgentGroup= [Forms]![frmCDErrorReports]![Group]
But, the first item in the dropdown [group] is "<All>"
Is there a way to structure the Where so it doesn't limit anything if "<All>" is selected?
WHERE Q4.AgentGroup= iif([Forms]![frmCDErrorReports]![Group]='<All>','*',[Forms]![frmCDErrorReports]![Group])
hoping that the * would allow the where to grab everything, but its just comparing the two, and because no group is = * it isn't giving any results.
Just tried this also
Didn't work, always gets all the agent groups.Code:WHERE iif(Forms!frmCDErrorReports!Group='<All>','','Q4.AgentGroup=Forms!frmCDErrorReports!Group')