Re: Select count(*) on a 2B Rows Tables Takes ~20 Hours

2018-09-17 Thread Laurenz Albe
Fred Habash wrote: > If I'm reading this correctly, it took 57M ms out of an elapsed time of 61M > ms to read 45M pages from the filesystem? > If the average service time per sarr is < 5 ms, Is this a case of bloated > index where re-indexing is warranted? > > explain (analyze,buffers,timing,ve

Re: Select count(*) on a 2B Rows Tables Takes ~20 Hours

2018-09-17 Thread Fred Habash
Buffers: shared hit=72620045 read=45,297,330 I/O Timings: read=57,489,958.088 Execution time: 61,141,110.516 ms If I'm reading this correctly, it took 57M ms out of an elapsed time of 61M ms to read 45M pages from the filesystem? If the average service time per sarr is < 5 ms, Is this a case of bl

Big image tables maintenance

2018-09-17 Thread still Learner
Hi , I have a 10 TB size table with multiple bytea columns (image & doc)and makes 20TB of DB size. I have a couple of issues to maintain the DB. 1. I Would like to separate the image column from the 10TB size table, place it in a separate schema. The change should not result in any query change i