The following variables are available to use URL parameters in a default where clause:
- httpGet[‘param_name’]: Returns the value of parameter param_name for an HTTP GET request
- httpPost[‘param_name’]: Returns the value of parameter param_name for an HTTP POST request
- httpRequest[‘param_name’]: Returns the value of parameter param_name for an HTTP GET and POST requests
Examples #
Show only rows for a specific student.
student_id = httpPost['student_id'] and httpPost['student_id'] is not null
Use httpGet if directly querying a parameter from a URL. For example: YOURDOMAIN.com/?student_id=1
student_id = httpGet['student_id'] and httpGet['student_id'] is not null
Add a like condition using if.
first_name like if( httpGet['student_firstname'] is null, first_name, concat( '%', httpGet['student_firstname'], '%' ) )
Show only rows for a specific student when parameter student_id is present or all rows if parameter student_id is not present.
student_id = ifnull( httpPost['student_id'], student_id )
Notes #
- Null is returned when no argument with the given name is found
- Values are sanitized and prepared automatically
- This feature is available to all users in the App Builder and no longer requires a premium license