David,
> table_name #Rows
> cust 1000
> order 5000
> order_detail 9500
If you're willing to live with some inaccuracy, do:
SELECT relname, reltuples FROM pg_class
WHERE relkind='r';
This count gets updated when you do a VACUUM, and is seldom 100% accurate;
however, if you VACUUM regularly it will be within 5-10%.
--
-Josh BerkusAglio Database SolutionsSan Francisco