PostgreSQL increase group by over 30 million rows
up vote
0
down vote
favorite
Is there any way to increase speed of dynamic group by query ? I have a table with 30 million rows. create table if not exists tb ( id serial not null constraint tb_pkey primary key, week integer, month integer, year integer, starttime varchar(20), endtime varchar(20), brand smallint, category smallint, value real ); The query below takes 8.5 seconds. SELECT category from tb group by category Is there any way to increase the speed. I have tried with and without index.
postgresql performance rdbms database-performance
share | improve this question
asked Nov 10 at 19:06