gnumed-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Gnumed-devel] branching a test branch


From: Karsten Hilbert
Subject: Re: [Gnumed-devel] branching a test branch
Date: Mon, 11 Dec 2006 16:15:50 +0100
User-agent: Mutt/1.5.13 (2006-08-11)

On Mon, Dec 11, 2006 at 08:40:32AM +1100, syan tan wrote:

> now that 8.2 works with child tables (after vacuum analyse , i think ),
:-)

> the performance bug with clin.v_pat_narrative was traced to 
> dem.v_staff; actually, there isn't a need to use dem.v_staff in
> the query; use dem.staff instead,
Done.

> and the performance is less
> than a second (vs 10 minutes).
Here is another tidbit which might decrease performance:

gnumed_v3=> explain SELECT * from clin.clin_narrative where modified_by = 
'gm-dbo';
                           QUERY PLAN
-----------------------------------------------------------------
 Seq Scan on clin_narrative  (cost=0.00..22.50 rows=6 width=168)
   Filter: (modified_by = 'gm-dbo'::name)

IOW, clin.v_pat_narrative does

        where clin.clin_narrative.modified_by = dem.staff.db_user

which lacks an index. I'll add one...

Karsten
-- 
GPG key ID E4071346 @ wwwkeys.pgp.net
E167 67FD A291 2BEA 73BD  4537 78B9 A9F9 E407 1346




reply via email to

[Prev in Thread] Current Thread [Next in Thread]