[Download] | [Documentation Home] | [Release Note]
When defining a data service, a user may have an requirement, that even if a user has not entered a specific parameter value in a request, a default value should be automatically added to the query. This can be done in WSO2 Data Services Server using the default values feature that is found when defining a query.
Figure 1: Setting a default value to a field.
WSO2 Data Services Server defines special system variables, that can be used as a default value. At the moment, it only provides a variable for retreiving the username of the current user who is authenticated in a secured data service. This variable can be accessed by using the following syntax.