Get Free Trial

A measurement field with an initial value of null does not default to all aggregators

Alan asked on September 19, 2017

I think I have found an issue with null fields. I have a jsfiddle to help me explain
In this fiddle there are 2 records of data. The price in the first one is null and therefore the price column only allows Count even though the second price value is a number 23. If I change this around and make the first record price 23 and the second price value null . I get the correct aggregators sum, avg etc …
The question is is this a bug or how can I get it to ignore the fact that the first value is null.

2 answers

Tanya Gryshko Tanya Gryshko Flexmonster September 20, 2017

Hello, Alan,
Thank you for the interest on our component. The first value is usually used to determine the column type (i.e. string, numberdate, etc.).
So, if the first value is null it will be determined by default as string. Therefore, you should set column type explicitly.
Please refer to the updated sample demonstrating how to set the correct type for such case –
For more details please read our documentation about JSON data types.
Please let me know if everything works fine.

Alan September 20, 2017

Hi thanks for the quick response. That worked! thanks

Please login or Register to Submit Answer