Unable to validate selector with string variable in it

I’m trying to use a string variable in my selector for the aaname field but it is saying it is unable to validate it

After you add variable, you cannot validate it, because validation doesnot able to recognize the variables, you can only validate with proper values.

so even though it is unable to validate it may still work?

Yes, it will work.

To check validation, put the value of variable manually and check, if it validates properly then your selector will also work with your variable.