All Products
Search
Document Center

Quick BI:Configure Query Control Cascade

Last Updated:Jan 20, 2025

To associate query controls, such as linking a region selection in Control A to a province list in Control B, you must configure their association. This topic introduces how to associate query controls by configuring conditional cascade.

Prerequisite

  • A dashboard has been created. For more information, see Create a Dashboard.

  • The dashboard has at least two text query controls or date query controls. For more information, see Text Query and Select Date.

Background information

Conditional cascade is a method to link one or more query controls, supporting queries from the same or different datasets.

  • For multiple query controls with at least one query condition's dataset differing from the others, select non-homologous configuration for conditional cascade.

  • If the option values in the query conditions of multiple query controls are from the same dataset, you may choose either homologous or non-homologous configuration for conditional cascade.

    Note

    Using the same data source, homologous configuration is simpler and achieves the same result as non-homologous configuration.

  • For cascading multiple date query controls, select date cascade configuration for conditional cascade.

Limits

  • Conditional cascade configuration supports both homologous and non-homologous configurations:

    Cascade configuration item

    Supported filter types

    Homologous cascade configuration

    Dropdown list and sourced from a single dataset

    Tree drop

    Date selection and sourced from dataset field

    Non-homologous cascade configuration

    Dropdown list and sourced from a single dataset

    Date selection and sourced from dataset field

    Date cascade configuration

    Date selection

  • A single cascade configuration item can include up to 5 cascade conditions. For more than 5 conditions, configure multiple cascades.

Notes

  • Upper-level relationships can cascade to lower levels. Conditions at the same level can establish cascades but cannot cascade in reverse.

    Note
    • Hierarchy: Global control > Tab query control > Chart query control. Global control can cascade to both Tab and Chart query controls. Tab query control can cascade to Chart query control but not to Global control in reverse. Chart query control can only cascade within its own level.

    • Reverse cascade is not permitted: If Control A includes fields for area and product type, and area is set to cascade product type, product type cannot cascade area in reverse.

  • Identical fields may exist under different controls. To differentiate them, select Show Title and edit the control name.

    image

  • Hiding query conditions in cascade configurations will clear the cascade, except when hiding the first level, which retains the configuration.

  • If you hide the first level in query conditions:

    • If the first level has a default value, it will take effect according to that value, and sub-level options will be sourced from the next level of the default value.

      For example, if the cascade condition is Area Province City District and the default value for Area is East China, then the options for City or District are sourced from the Province under East China.

    • If the first level does not have a default value and the options are sourced from the global parameter, it will take effect according to the global parameter value.

    • If the first level has no default value, no global parameter value is passed, and the first level value cannot be selected after hiding, it is equivalent to not setting this condition, and all values are in the sub-level.

      46.gif

    • If the first level has a default value and the dashboard is also configured with a global parameter, the global parameter value will overwrite the default value and take effect accordingly.

Associate query controls

  • When the query condition display type is Dropdown list and sourced from a single dataset, it supports both homologous cascade and non-homologous cascade.

    image

  • When the query condition display type is Select Date and the data is sourced from a dataset field, both same-source cascade and different-source cascade are supported.

    Note

    You can configure date conditions with other types (dropdown, tree drop) for homologous or non-homologous cascade.

    image

  • When the query condition display type is Tree Drop, it supports homologous cascade and can configure the cascade relationship with the same dataset as the tree drop.

    image

  • When the query condition display type is Date selection, it supports date cascade and configures the cascade relationship of date controls.

    Note

    If there are multiple date controls and the dataset for the date source is not selected, you can directly configure the cascade between these multiple date conditions, but it cannot cascade with dropdown lists or other text-type controls.

    image

Procedure

  1. On the dashboard editing page, follow the guide in the figure below to enter the conditional cascade page.

    image

    You can also click on conditional cascade configuration in the Query Condition Settings interface to enter the conditional cascade page.

    image

    Enter the Conditional Cascade Configuration page.

    image

  2. Configure conditional cascade.

    • When the option values in the query conditions of multiple query controls all come from the same dataset, it is recommended to choose homologous configuration for conditional cascade.

    • For multiple query controls with at least one query condition's dataset differing from the others, select non-homologous configuration for conditional cascade.

    • When the query condition display type is Date selection:

      • If there are multiple date controls and the dataset for the date source is not selected, you can directly configure the cascade between these date conditions. For more information, see the Date Cascade section in Date Query Control Cascade Configuration in this topic.

      • If it is a single date and dropdown list or other text-type control, it supports homologous or non-homologous cascade.

Configure conditional cascade relationship (homologous configuration)

Suppose in the dashboard, Query Control A contains fields for area and province, and Query Control B contains fields for city and product category. If Query Control A and B's data comes from the same dataset, you can link the area field in Control A with the city field in Control B. When an area is selected in Control A, only cities within that area will be displayed in Control B.

  1. On the Conditional Cascade Configuration page, click Add New Cascade Configuration -> Homologous Cascade or select Switch To Homologous Cascade.

    image

    • After selecting Add New Homologous Cascade Configuration, you can add a cascade relationship without changing the source cascade relationship.

    • After selecting Switch To Homologous Cascade, the original cascade relationship is changed, and the operation is irreversible.

  2. Select the targetfield Area in Query Control A and click the 添加 icon on the right.

    image

  3. Select the condition field City that needs to be cascaded with the target field.

    image

  4. Click Confirm.

    Now, when you select Area as Northwest in Query Control A, only cities within the Northwest area will be available in Query Control B's City field.

    Untitled.gif

Configure conditional cascade relationship (non-homologous configuration)

Consider a dashboard where Control A includes fields for region and product type, while Control B has fields for province and product subcategory. If the data for Control A and B comes from different datasets, linking the region field in Control A with the province field in Control B means that selecting a region in Control A will filter the provinces in Control B accordingly.

  1. On the Conditional Cascade Configuration page, in the Cascade Configuration Item area, select the target field Region and click the 添加 icon on the right.

    image

  2. In the configuration box corresponding to the added cascade configuration item, perform the following:

    1. Select the condition field Region that needs to be cascaded with the target field.

      When selecting the condition field, multiple Provinces may appear. Choose the condition field associated with the control.

      image

    2. Select the associate field.

      • The associate field must be in the dataset that receives the value from the upper-level condition for the province query condition source. For instance, if the upper level is region and the lower level is province, the area field selected should be the one receiving the value from Region.

        image

      • The associate field can be a Dimension, Expression Value Placeholder, or Value Placeholder. The logic for passing values through placeholders is as follows:

        Query control type

        Query method

        Value placeholder

        Expression placeholder

        Date filter

        Single time:

        e.g., 2024-05-28

        2024-05-28

        >=2024-05-28,<=2024-05-28

        Time interval:

        2024.05.28~2024.05.28

        2024-05-28

        >=2024-05-28,<=2024-05-28

        Time interval:

        2024.05.21~2024.05.28

        2024-05-21

        >=2024-05-21, <=2024-05-28

        Text filter

        Single selection: East China

        East China

        in East China

        Multiple selection: East China, South China, Northeast

        East China, South China, Northeast

        in East China, South China, Northeast

        Note

        During time interval filtering, if the start and end times in the filter box differ (e.g., 2024.05.28~2024.05.28), the Value Placeholder will default to the start time, such as 2024-05-21. Should you want to select the end time, 2024.05.28, you can do so within the dataset by specifying, for example: report_date < '$val{report_date_ph.get(1)}'.

        For detailed information on using placeholders, refer to the Placeholder documentation.

  3. (Optional)

    If multiple query conditions in Control A and B need association, click Add New Cascade Configuration and repeat the previous steps to complete the association.

    image

  4. After completing the configuration, click Confirm.

    Now, selecting Region as Northeast in Control A will display only the provinces in the Northeast area in Control B's Province field.

    image

Date query control cascade configuration

Date cascade

In a dashboard, Control-Date may include fields for quarter and month. Associating these two date fields enables a date cascade effect. For instance, selecting the first quarter of 2023 will limit the month date control to only January, February, and March.

  1. On the Conditional Cascade Configuration page, click Add New Cascade Configuration and select Date Cascade.

    image

    Note

    In date cascade configuration items, the condition range includes only date-type query controls. Supported time granularities are year, year-quarter, year-month, year-week, year-month-day, and year-month-day-hour-minute-second.

  2. Select the target field Quarter in Control-Date and click the 添加 icon on the right.

    image

  3. Select the condition field Month that needs to be cascaded with the target field.

    image

  4. Click Confirm.

    Selecting the first quarter of 2023 now limits the month filter to January through March 2023.

    image

Date control and other controls mutual cascade

Mutual cascade between date query controls and dropdown lists is supported only when the date query control's data source is a dataset field.

  • For instance, using a homologous configuration can enable date control to cascade and influence other controls.

    1. On the Conditional Cascade Configuration page, click Add New Cascade Configuration -> Homologous Cascade or select Switch To Homologous Cascade.

      image

      • Selecting Add New Homologous Cascade Configuration allows you to add a cascade relationship without altering the existing one.

      • Choosing Switch To Homologous Cascade changes the original cascade relationship irreversibly.

    2. Select the target field Transport Date in Control C and click the 添加 icon on the right.

      image

    3. Select the condition field Area that needs to be cascaded with the target field.

      image

    4. Click Confirm.

      Selecting Date as 2023-04-01 and then selecting Area will filter the area corresponding to April 1, 2023.

      image

  • For instance, using a non-homologous configuration can enable the cascading of date controls among other controls.

    1. On the Conditional Cascade Configuration page, click Add New Cascade Configuration -> Non-homologous Cascade.

      image

    2. In the Conditional Cascade Configuration page's Cascade Configuration Item area, select the target field Promotion Activity in Control D and click the 添加 icon on the right.

      image

    3. In the configuration box for the added cascade configuration item, proceed with the following:

      1. Select the condition field Date that will be cascaded with the target field.

        When selecting the condition field, multiple Dates may be displayed. Choose the condition field associated with the control.

        image

      2. Select the associate field.

        Note

        The associate field must be the one in the dataset that receives the value passed from the upper-level condition for the query condition source. For example, if the upper level is Promotion Activity and the lower level is Date, the selected Promotion Activity field is the one that receives the value passed from Promotion Activity.

        image

    4. Once the configuration is complete, click Confirm.

      Currently, when you choose Promotion Activity labeled as Spring Festival Activity, you can filter by the dates associated with the Spring Festival Activity.

      image

      Note

      When other controls cascade to a date control, the selectable date range within the date control encompasses all dates associated with the Spring Festival Activity value in the dataset.

      For instance, if the dataset includes three entries for the Spring Festival Activity on 2024-02-05, 2024-02-10, and 2024-02-17, the selectable date range will span from 2024-02-05 to 2024-02-17, covering the entire continuous period.

Modify conditional cascade configuration

You can modify an existing conditional cascade configuration with the following steps.

  • Rename a cascade configuration item.

    By default, a new cascade configuration is named Cascade Configuration Item. Click the title area to rename it.

    image

  • Delete a cascade configuration item.

    Click the Delete icon above the added condition to remove it. Alternatively, click the Delete icon next to the cascade configuration item to delete the entire item.

    image