Difficulty level: Easy
What does the functionality do?
The following types of variables are found in Survalyzer:
- Question variables
- Member variables
- Url variables
- Custom variables
The different type of variables have different constraints. For example, member variables are columns of a table in the database. These table names, for example, don’t support the following characters:
%^&(){} ][”’
Another example is member variables which in placeholders which are used in the scope of HTML text. If a member variable is named “Büchername”, the related placeholder would be {member.Büchername} but since it is used in HTML, the special characters are escaped. In fact, the placeholder would look like “{member.Büchername} which is not resolvable any longer.
Finally, variables could be used in the scope of calculations. In this scope the following symbols are invalid:
+-*/
These are arithmetic operators which would give the formula a different meaning. For example, with “Buecher-Name” an attempt is made to find the variable Buecher and to subtract the variable Name from it. This could lead to invalid filter conditions.
Therefore, Survalyzer defined the valid set of characters for all variables to seek consistency and provide guidance to customers. The valid chars are:
a-z, A-Z, 0-9, _
This means that uppercase and lowercase Latin letters as well as numbers could be used. The underscore is supposed to be used as a separation character. To stick to the previous example, this would result in {member.buecher_name} being a fully valid name in all scopes.