Thank you for the information. Schema of table is: ID bigint company_name text data_set text time timestamp Date date Length of company_name is not known so it is of datatype text. I need to build the index on company_name and ID. And then insert the records. I can not create the index after insertion because user can search the data as well while insertion. Machine is of 8 core, os centos6 and 8 GB of RAM. Here is my configuration: max_connections = 100 shared_buffers = 32MB wal_buffers = 1024KB checkpoint_segments = 3 -- Sent via pgsql-performance mailing list (pgsql-performance@xxxxxxxxxxxxxx) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-performance