Adding of Data from Two Datasets

  • Last update:November 06, 2024
  • Overview

    Problem

    You can define multiple datasets in a report and extract the required data from each respectively. Therefore, the data displayed in a report can come from different tables or databases. How can you add data columns from different datasets?

    Solution

    1. You can add dataset data with SQL statements. Details are not elaborated in this document.

    2. You can drag each of the two data columns that come from different datasets into separate cells, and add the two cells with the SUM formula.

    3. You can directly add dataset data with the dataset formula.

    Example One: Adding Data with the SUM Formula

    Report Design

    1. Create two built-in datasets, as shown in the following figure.

      2024-11-06_11-46-43.png

    2. Drag the data columns into the corresponding cells, insert the formula SUM(B1, C1) into cell D1, and set Expansion Direction to No Expansion for D1, as shown in the following figure.

    2024-11-06_11-49-42.png

    3. Double-click C1 to set the filter condition: Product Equals to A1, as shown in the following figure.

    2024-11-06_11-38-04.png

    Effect Display

    Save the template and click Pagination Preview. The preview effect is shown in the following figure.

    2024-11-06_11-40-32.png

    Example Two: Adding Data with the Dataset Formula

    Report Design

    You can simply use the formula Embedded1.select(Sales Volume, Product = A1) + Embedded2.select(Sales Volume, Product = A1), as shown in the following figure. In the formula, Embedded1 and Embedded2 are dataset names.

    The formula obtains the values of Sales Volume through the extended Product values and adds the Sales Volume values to obtain the total of the two datasets.

    iconNote:
    Multiple conditions can be determined by adding AND or OR relationships in the formula. && represents the AND relationship, and || represents the OR relationship.

    2024-11-06_11-45-03.png

    Effect Display

    2024-11-06_11-45-43.png

    Attachment List


    Theme: Report Application
    • Helpful
    • Not helpful
    • Only read

    滑鼠選中內容,快速回饋問題

    滑鼠選中存在疑惑的內容,即可快速回饋問題,我們將會跟進處理。

    不再提示

    7s后關閉

    Get
    Help
    Online Support
    Professional technical support is provided to quickly help you solve problems.
    Online support is available from 9:00-12:00 and 13:30-17:30 on weekdays.
    Page Feedback
    You can provide suggestions and feedback for the current web page.
    Pre-Sales Consultation
    Business Consultation
    Business: international@fanruan.com
    Support: support@fanruan.com
    Page Feedback
    *Problem Type
    Cannot be empty
    Problem Description
    0/1000
    Cannot be empty

    Submitted successfully

    Network busy