Only sum the first occurrence of the value

  • Last update:  2021-05-14
  • I. Overview

    1. Problem description

    For the recurring indicators in the template, sometimes we only want to sum the first occurrence of the value. As in the example below, Apple appears twice, and only the first time is summed.

    1.png 


    2. Realization idea

    Use the seq() formula to calculate the number of occurrences of the specified object, and sum the number of occurrences equal to 1.

    II. Steps

    1. Design report

    1) Create a new built-in dataset Embedded1, as shown in the figure below:

    2.png

    2) Design the report as shown in the figure below, and set the A2 cell data as a list.

    3.png

    3) Fill in cell B3 with the formula: SUM(B2[!0]{SEQ(A2)=1})

    4.png


    2. Effect preview

    Save the template, click Pagination Preview, the effect is as shown in I.1.

    Note: Mobile terminal is supported.

    III. Download template

    Refer to the completed template: %FR_HOME%\webapps\webroot\WEB-INF\reportlets\doc-EN\ReportApplication\BasicApplication\Sum_first_occurrence.cpt

    Click to download: 

    Sum_first_occurrence.cpt


    Attachment List


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

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

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

    不再提示

    10s後關閉

    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