Re: [PERFORM] CPU usage goes to 100%, query seems to ran forever

2006-04-28 Thread Andrus
> Something seems to have truncated your EXPLAIN output, but anyway we > can see where the problem is: I copied it from pgAdmin in 640x480 screen resolution in XP Maybe pgAdmin bug ? > The planner is expecting to get one row from "dok" passing the filter > condition, and hence chooses a plan tha

Re: [PERFORM] CPU usage goes to 100%, query seems to ran forever

2006-04-28 Thread Tom Lane
"Andrus" <[EMAIL PROTECTED]> writes: > Here it is running in my local computer. I'm expecting run time no more 1 > second Something seems to have truncated your EXPLAIN output, but anyway we can see where the problem is: > " -> Seq Scan on dok (cost=0.00..787.80 rows=1 width=39) >

Re: [PERFORM] CPU usage goes to 100%, query seems to ran forever

2006-04-28 Thread Andrus
> You have ANALYZEd all these tables recently, I hope? The planner > certainly doesn't think this query will take very long. I have autovacuum running so I expect it takes care of ANALYZE, isn't it ? I ran also analyze command before running explain analyze. > To find out what's wrong, you're g

Re: [PERFORM] CPU usage goes to 100%, query seems to ran forever

2006-04-27 Thread Tom Lane
"Andrus" <[EMAIL PROTECTED]> writes: > I have small database running in 8.1.3 in W2K server. > The following query causes Postgres process to use 100% CPU and seems to run > forever. > If I change '1EEKPANT' to less frequently used item code, it runs fast. You have ANALYZEd all these tables rece

[PERFORM] CPU usage goes to 100%, query seems to ran forever

2006-04-27 Thread Andrus
I have small database running in 8.1.3 in W2K server. The following query causes Postgres process to use 100% CPU and seems to run forever. If I change '1EEKPANT' to less frequently used item code, it runs fast. How to speed it up ? set search_path to public,firma2; select rid.toode FR