We have updated WebDataRocks EULA, effective as of April 18, 2024. Learn more about what's changed.

How to customize 'Classical form' not to have values like sum of name_of_variable in columns


I’ve just discovered WebDataRocks and I find it very easy to implement but I would like to customize different report loaded when opening the page, and particularly ‘Classical form’.
I have set flat report as default form to have all data presented.
When I choose ‘Classical form’, I have already selected ‘Sum of var1’, ‘Sum of var2’ in the Values set part and theses values are added in Columns by default. Theses sum have no sens because nature of var1 and var2.
I would like either set my own Values or leave Values blank.
I do not found the answer in the documentation.
I can I do that?
Where can I find more detail documentation?
Thanks for replying,

1 answer

WebDataRocks Team WebDataRocks January 16, 2020

Thank you for reaching out to us.
We would like to explain the logic of placing fields in rows and columns in case the slice object is not specified:

  • In case the flat view is used by default, all fields from the data set will be chosen for the current report.
  • If the classic or compact view is used, the first field from the data set will go to the rows when the first measure to the columns.

In order to avoid such a behavior, the following approaches can be used:

  • Set the property showDefaultSlice of the options object to true. That allows to leave the slice empty and gives a possibility to choose fields to display right after the component is loaded. More information about the options object and its properties can be found following the link: Options Object.
  • In case specific fields have to be chosen by default, the slice object has to be specified. Being the property of the report object, slice has the following structure:
    slice: {
    columns: [
    { uniqueName: "Field_A" },
    { uniqueName: "Field_B" },
    rows: [
    { uniqueName: "Field_C" },
          { uniqueName: "Measures" }, //That object allows to choose where measures are going to be placed (columns or rows).
    measures: [
          { uniqueName: "Measure_A" },
    { uniqueName: "Measure_B" },

More information about the slice object and its properties by the link: Slice Object.
We hope it works for you.
Best regards,
WebDataRocks Team