Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

This article explains how to create a query that leverages variables. This allow to dynamically query the datasource and so reduce the time necessary to retrieve the results.

  • Select a SQL data source (date parameters can be applied also to other datasource but the procedure might slightly change)

Image Modified

  • Create the query you wish (without date parameters). You can use the drag & drop feature or write the query by your own.

Image Modified

  • Create two variables of type date to store the start and end date

Image Added

Image Added

  • Right click on the query you created and click on Properties than click on Edit in the Conditions section

Image Added

  • A window will appear allowing you to write your filter condition in some clicks. For filtering rows between the start and end date you could write some like that

Image Added

  1. Select the database column that you want to use in the comparison.
  2. Select the comparison method
  3. Choose the right variable

    In order to select the variables, click on the icon on the right and select the Variable option

    Image Added

Your table should now able to retrieve only the data of the data range you selected.