Result
The Vizzly Dashboard expects results to be returned in a certain structure, so that the data can be plotted on the components placed on the dashboard.
Format
type RowOfValues = Array<string | number | Date | null>;
export type Result = Array<RowOfValues>;
Example result
This is an example result. It has two fields, and 3 rows of values. This result shows the highest score for a computer game, grouped by player name.
[
["James", 932324],
["Chris", 194],
["Matt", 234]
]
Order of values
A Vizzly query defines a list of measures. The index of each measure should correspond to its value. This is how the Vizzly dashboard then reads the results.
Error handling
Currently, errors are handled by simply returning null
instead of the array of results.
Validation
The Vizzly frontend runs some basic validations on the results generated based on the query that we sent. If things aren't working as expected, it is always worth checking the console output in the browser to see if there's a friendly validation error message waiting for you. If not, please get in-touch with our support team and we can work with you on debugging it.