| From: | Richard Huxton <dev(at)archonet(dot)com> |
|---|---|
| To: | Christian Rengstl <Christian(dot)Rengstl(at)klinik(dot)uni-regensburg(dot)de> |
| Cc: | andreas(dot)kretschmer(at)schollglas(dot)com, pgsql-general(at)postgresql(dot)org |
| Subject: | Re: Antw: Re: Query questions |
| Date: | 2006-07-31 14:55:39 |
| Message-ID: | 44CE19EB.3010303@archonet.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-general |
Christian Rengstl wrote:
> My version is 8.1.4. Here is the plan for the query, it's performed on a
> smaller table, though because i can't access the biggest table at the
> moment:
> QUERY PLAN
>
> -----------------------------------------------------------------------------------------------------------------------------
>
> Bitmap Heap Scan on mytable (cost=67.48..16738.24 rows=6519 width=10)
> (actual time=34.033..1903.106 rows=1 loops=1)
> Recheck Cond: ((pid)::text = 'ZZZ000110011'::text)
>
> Filter: ((crit)::text = '915677'::text)
>
> -> Bitmap Index Scan on idx_pid_22 (cost=0.00..67.48 rows=8996
> width=0) (actual time=12.998..12.998 rows=6207 loops=1)
> Index Cond: ((pid)::text = 'ZZZ000110011'::text)
>
> Total runtime: 1903.894 ms
>
> And yes i have indexes on both pid (varchar(15)) and crit(varchar(13)).
That's not quite what Andreas asked. Do you have an index on (pid, crit)?
--
Richard Huxton
Archonet Ltd
| From | Date | Subject | |
|---|---|---|---|
| Next Message | DANTE Alexandra | 2006-07-31 15:00:55 | Re: Questions about update, delete, ctid... |
| Previous Message | Ron Johnson | 2006-07-31 14:53:42 | Re: Practical maximums (was Re: PostgreSQL theoretical |