Requirement: We have to capture the data for a day in particular time intervals(time interval is constant for a set of data). The time interval can range from 5 minutes to 2 hours . So the number of data points for a day can vary from 12 to 288. How should we design our table to accommodate this variation.
Can we go up with adding 288 columns in the table ? If the time interval is 5 minutes then all 288 columns will be occupied. If its 2 hours than only the 1st 12 columns will be occupied. and so on.
hstore
datatype to overcome the limitations of the EAV pattern.