Re: stats on cursor and query execution troubleshooting - Mailing list pgsql-performance

From Tom Lane
Subject Re: stats on cursor and query execution troubleshooting
Date
Msg-id 25576.1097072199@sss.pgh.pa.us
Whole thread Raw
In response to stats on cursor and query execution troubleshooting  ("Alban Médici (NetCentrex)"<amedici@fr.netcentrex.net>)
Responses Re: stats on cursor and query execution troubleshooting  ("Alban Médici (NetCentrex)"<amedici@fr.netcentrex.net>)
List pgsql-performance
=?ISO-8859-1?Q?=22Alban_M=E9dici_=28NetCentrex=29=22?= <amedici@fr.netcentrex.net> writes:
> I'm looking for the statistic of memory,  CPU,  filesystem access while=20
> executing some regular SQL query,  and I want to compare them to
> same kind of results while executing a cursor function.

I think your second query is finding all the disk pages it needs in
kernel disk cache, because they were all read in by the first query.
This has little to do with cursor versus non cursor, and everything
to do with hitting recently-read data again.

            regards, tom lane

pgsql-performance by date:

Previous
From: Alan Stange
Date:
Subject: Re: Excessive context switching on SMP Xeons
Next
From: Bill Montgomery
Date:
Subject: Re: Excessive context switching on SMP Xeons