By default, the
/table endpoint returns a "dense cube". That means that it returns every value, even if the value is null or 0.
If you are generating large table queries that are likely to contain lots of null or 0 values, you can instead access the
/table/sparse endpoint. This returns only non zero and non null values. Each returned value has an index associated with it, which you can use to identify where it belongs in the table.
The only difference between the two endpoints is the contents of the
cubes section in the response. They both accept identical input and return otherwise identical responses.
Consider the following table, showing Gender by Marital Status:
As you can see, it contains a number of cells with 0 values.
To query the Open Data API for these values, you would use a request similar to the following:
Below are the examples of the
cubes section in the responses from the two endpoints: