Parameter

Create dynamic notebooks and reports.

By using the Parameter defined in Notebooks, you can make Notebooks and Reports dynamic and interactive. This allows you to control embedded SQL through parameters without directly accessing SQL, and obtain tailored outputs as needed.

Key Features

  • Make Notebooks and Reports Dynamic:

    • Make Notebooks and Reports dynamic and interactive.

  • Various types of parameters:

    • Choose from various data types and associated input widgets.

  • Two types of scopes:

    • Choose parameters used across the entire Notebook or on a page-by-page basis.

  • Parameter overwrite:

    • Fine-grained control by overwriting parameters when chaining SQL.

Types of Parameters

  • Text input (STRING):

    • Simple string input field.

    • Expanded with quotes in SQL.

  • Text select (STRING):

    • Pass a fixed option list in CSV format or retrieve options from SQL results.

  • Number input (NUMBER):

    • Simple number input field. Can set min, max, and intervals.

    • Expanded without quotes in SQL.

  • Number select (NUMBER):

    • Pass a fixed option list in CSV format or retrieve options from SQL results.

  • Date input (DATE):

    • Simple date input field. Can select using an absolute expression from a calendar UI.

    • Can set min and max.

    • Expanded in ‘yyyy-MM-dd’ format in SQL.

  • Date range ([DATE, DATE]) :

    • Specify start and end pairs.

  • Checkbox (BOOLEAN):

    • Simple boolean checkbox.

    • Expanded as TRUE, FALSE in SQL.

Scopes of Parameters

Parameters can be created from two types of scopes:

  • Notebook common

    • Parameters shared across all pages in the notebook

    • Values are retained on each page

  • Page specific

    • Parameters specific to each page

Notebook common parameters can be used, for example, when you want to control components on a Grid Page, such as charts created from SQL on a Doc Page, with the same parameter.

Page specific parameters can be used, for example, when you do not want the parameter to affect anything outside of the specific page.

Parameter Overwrite

When chaining SQL, you may want to cut off the parameter dependencies. For example:

  • Setting unique parameters for each page when chaining SQL across pages.

  • Using different parameters for different SQLs derived from the same base SQL.

Parameters can be overwritten on a popup displayed by hovering over the referenced SQL in SQL Blocks.

Syncing Parameter Values and Execution Results Among Users

Parameter values and execution results in Notebooks are synchronized among users. However, using Notebook Version and Reports ensures that changes to parameter values and execution results are not synchronized between users, reflecting changes only to the user who change the values.

For more details, please refer to the Notebook Version.

Last updated