Re: [ADMIN] A query with performance problems.
От
Stephan Szabo
Тема
Re: [ADMIN] A query with performance problems.
Дата
Msg-id
20030506073613.K7678-100000@megazone23.bigpanda.com
Ответ на
A query with performance problems. (Fabio C. Bon)
Список
[Moving to -performance since it's more ontopic there] On Tue, 6 May 2003, Fabio C. Bon wrote: > I have a database on PostgreSQL 7.2.1 and I have performance's problems with > some queries. > I'm debbuging the query below: > > Select count(*) from blcar > where manide = 3811 and blide = 58090 and bcalupcod = 'MVDUY' and bcalopcod > = 'LOCAL' and bcapag <> 'P'; What does the schema of the table look like? Is the SQL query in the file exactly the same text as the above? > Aggregate (cost=8277.10..8277.10 rows=1 width=0) (actual > time=1273.98..1273.98 rows=1 loops=1) > -> Seq Scan on blcar (cost=0.00..8277.09 rows=1 width=0) (actual > time=1273.96..1273.96 rows=0 loops=1) > Filter: (((manide)::numeric = 3811::numeric) AND ((blide)::numeric It seems to want to coerce manide and blide to a numeric here, which seems odd. > = 58090::numeric) AND (bcalupcod = 'MVDUY'::bpchar) AND (bcalopcod = > 'REPRE'::bpchar) AND (bcapag <> 'P'::bpchar)) > Total runtime: 1274.08 msec > (4 rows)
В списке pgsql-performance по дате отправления
От: Christopher Kings-Lynne
Дата: