Query (Parameter Update Method)

 

Choose this Update Method if you want to feed the parameter with the result of a query. Using this method enables you to feed a parameter with a dynamic value. This value will be the result of the first column of the first record returned by the specified query.

 

Examples: a parameter can return the most recent date, a product code corresponding to the most sold product, the number of records in a table or the number of distinct values for a specified column. The last two examples enable you to avoid printing a report in a report book if there are no data for this report (See also Run Condition in a report)

 

Example with a parameter retrieving the last date used in a table and another parameter that will use this value for the criteria on the date field:

 

 

image\parameterquery1.gif

image\parameterquery2.gif

 

The criteria on the date field will be as follows:

 

image\parameterquery3.gif