I just wanted to find out if indexes affect the storage space of the data ?
I’ve got about 124 double precision fields, that I’ve left as default ( they have an index ) but seeing as I do not need to specifically query those fields ( no join or where clause usage ) could I leave out the index and save any storage space for the table ?
Also If any of the fields are used in window or aggregation functions, would they need an index ?
Hi David, indexes take up space, yes.
They can be disabled for specific columns by passing INDEX OFF next to the data type for the relevant columns in the table definition.
While you will not be able to reference these columns in the WHERE clause, most aggregations and even JOINs will still work as CrateDB can leverage the column store for that.
There is no generic guideline on this as compression is involved, but for what is worth, on a totally unscientific test I just did with 1 million random bigint numbers, disabling indexing saved me 8.6 MB