Wijmo OLAP: Don't have SUM function field settings

Posted by: subakaranmca on 20 November 2018, 10:47 pm EST

    • Post Options:
    • Link

    Posted 20 November 2018, 10:47 pm EST - Updated 3 October 2022, 8:17 pm EST

    Hi, I used latest Wijmo version for angular 2. When I test OLAP functionalities, I don’t have SUM function on the field settings. ( Pls refer screenshot)

    But WIJMO sample intro webpage shows more function on the field settings dropdown ( see second screen is attached here) .

    Did I miss anything? please advise me.

  • Posted 20 November 2018, 11:48 pm EST

    Hi, subakaranmca,

    This is because of the data type of the field. The Downloads field is a numeric data type hence it shows the more function. If you try with another field except for Sales and Downloads for Wijmo OLAP demo, you will get the same result.

    Please check the data type for your field.

    ~Manish

  • Posted 21 November 2018, 2:26 am EST

    ‘Sum’ option is shown for number dataType. If your field is number type and it is not automatically detected then you may set dataType property of PivotField to ‘wijmo.DataType.Number’ and then field setting will show ‘Sum’ as a summary option.

    Please refer to the following code snippet:

    let myField = myPivotEngineInstance.fields.getField('myFieldName');
    myField.dataType = wijmo.DataType.Number;
    

    You may also refer to the following sample:

    https://stackblitz.com/edit/angular-ddjynb?file=app%2Fapp.component.ts

    ~Sharad

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels