Special Variables (SQL)

 > Filters > Special Variables (SQL)

Special Variables are used in SQL mode to help you create dynamic Widgets that can change depending on the date and the current user logged in Viur.

  • {TODAY}: is replaced by the current date in UTC. Ex: '2017-11-17'
  • {VIUR_USER_EMAIL}: is replaced by the user e-mail logged in Viur. Ex: '[email protected]'
  • {VIUR_USER_FIRSTNAME}: is replaced by the user first name logged in Viur. Ex: 'Pedro'
  • {VIUR_USER_LASTNAME}: is replaced by the user last name logged in Viur. Ex: 'Almeida'
  • {VIUR_USER_ROLE}: is replaced by the user role logged in Viur. Ex: ('admin', 'analyst' or 'viewer').

special-variables;

Still need help? Get in touch!
Last updated on 16th Oct 2018