Forum OpenACS Q&A: Response to connect by patch?

Collapse
Posted by Dan Wickstrom on
If you want to get relative performance results, use explain from psql.

psql>explain select * from some_table where some_attribute = 'some_value';

Will give you a cost estimate for the query.  I've also seen references on the pg hackers list about turning on extended logging whereby you can obtain more detailed information about each query such as the number of physical reads from the disk and the time in msecs for executing the query.  Unfortunately, I can't recall how this is done.