ARS Quesry Based Distribution Group

Is it possible to create a query based distribution group where the LDAP query compares two attributes and adds a user to the group if they are not the same?

The two attributes that I want to compare are 'mail' and a virtual attribute 'edsvaFirstEmailAddress'.

If the two values are not the same then the user should be added to the group.

Is that possible?