Received: from localhost (pluto.hub.org [200.46.204.4]) by postgresql.org (Postfix) with ESMTP id 965409FB2A6 for ; Fri, 3 Nov 2006 08:06:33 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.4]) (amavisd-new, port 10024) with ESMTP id 33390-09 for ; Fri, 3 Nov 2006 08:06:24 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey- Received: from mail.metronet.co.uk (mail.metronet.co.uk [213.162.97.75]) by postgresql.org (Postfix) with ESMTP id 61DED9F9F7D for ; Fri, 3 Nov 2006 08:06:28 -0400 (AST) Received: from mainbox.archonet.com (84-51-143-99.archon037.adsl.metronet.co.uk [84.51.143.99]) by smtp.metronet.co.uk (MetroNet Mail) with ESMTP id 869647378B; Fri, 3 Nov 2006 12:06:22 +0000 (GMT) Received: from [192.168.1.17] (client17.office.archonet.com [192.168.1.17]) by mainbox.archonet.com (Postfix) with ESMTP id 2224615EAB; Fri, 3 Nov 2006 12:06:22 +0000 (GMT) Message-ID: <454B311E.9010001@archonet.com> Date: Fri, 03 Nov 2006 12:07:58 +0000 From: Richard Huxton User-Agent: Thunderbird 1.5.0.7 (X11/20060918) MIME-Version: 1.0 To: "A. Kretschmer" Cc: pgsql-performance@postgresql.org Subject: Re: profiling PL/pgSQL? References: <20061103112137.GD15480@a-kretschmer.de> In-Reply-To: <20061103112137.GD15480@a-kretschmer.de> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200611/37 X-Sequence-Number: 21807 A. Kretschmer wrote: > am Fri, dem 03.11.2006, um 3:12:14 -0800 mailte Drew Wilson folgendes: >> I have 700 lines of non-performant pgSQL code that I'd like to >> profile to see what's going on. >> >> What's the best way to profile stored procedures? > > RAISE NOTICE, you can raise the aktual time within a transaction with > timeofday() Of course you only have very small values of "best" available with plpgsql debugging. There's a GUI debugger from EnterpriseDB I believe, but I've no idea how good it is. Any users/company bods care to let us know? -- Richard Huxton Archonet Ltd