On Fri, Mar 17, 2006 at 14:39:04 +0100, Stefan Meyer <[EMAIL PROTECTED]> wrote: > i have a beginner question and i have read the FAQs. > is there a faster ways than > > select count(*) from foo; > > to get the rowcount for the tables in my db ?
There are some ways to get approximate counts that won't require scanning the whole table. If you are going to be doing lots of these, you can use triggers to maintain a count. There is also a more complicated approach that can be used to reduce contention. You should be able to find more details in the archives. ---------------------------(end of broadcast)--------------------------- TIP 9: In versions below 8.0, the planner will ignore your desire to choose an index scan if your joining column's datatypes do not match