Обсуждение: Debug plpgSQL stored procedures

Поиск
Список
Период
Сортировка

Debug plpgSQL stored procedures

От
Daniel Morgan
Дата:
Does PostgreSQL provide a way to step-debug into plpgSQL stored procedures?

If yes, how do you do debug the stored procedures? Can it be done via
any interface: jdbc, odbc, .net, etc.?

If no, is there any plans to provide debugging support of plpgSQL stored
procedures?

I do request, if you there is plans to add debugging support, make it
easy enough for various interfaces to use it: jdbc, odbc, .net, etc...



Re: Debug plpgSQL stored procedures

От
Richard Huxton
Дата:
Daniel Morgan wrote:
> Does PostgreSQL provide a way to step-debug into plpgSQL stored procedures?

Afraid not. One of the commercial versions of PG offered it as a feature
IIRC, but I could be wrong, and if so it was some time ago.

> If yes, how do you do debug the stored procedures? Can it be done via
> any interface: jdbc, odbc, .net, etc.?
>
> If no, is there any plans to provide debugging support of plpgSQL stored
> procedures?

Not afaik - there's plenty of interest, but no-one with enough time and
knowledge I think.

> I do request, if you there is plans to add debugging support, make it
> easy enough for various interfaces to use it: jdbc, odbc, .net, etc...

That might be tricky as a general case, since I'm not sure all of them
offer a suitable out-of-band channel that could be used to send the
relevant control/debug data. You could always make it part of the SQL
interface, I suppose that would automatically give you cross-client support.

--
   Richard Huxton
   Archonet Ltd

Re: Debug plpgSQL stored procedures

От
Daniel Morgan
Дата:
Richard Huxton wrote:

> Daniel Morgan wrote:
>
>> Does PostgreSQL provide a way to step-debug into plpgSQL stored
>> procedures?
>
It is a shame.  PostgreSQL is really rocking these days.  Especially
with 8.0 on Windows.  I was really impressed how far it has come since
the 6.x days running on Cygwin.

> Afraid not. One of the commercial versions of PG offered it as a
> feature IIRC, but I could be wrong, and if so it was some time ago.

Can you remember the name of this company?

>> If yes, how do you do debug the stored procedures? Can it be done via
>> any interface: jdbc, odbc, .net, etc.?
>>
>> If no, is there any plans to provide debugging support of plpgSQL
>> stored procedures?
>
>
> Not afaik - there's plenty of interest, but no-one with enough time
> and knowledge I think.
>
>> I do request, if you there is plans to add debugging support, make it
>> easy enough for various interfaces to use it: jdbc, odbc, .net, etc...
>
>
> That might be tricky as a general case, since I'm not sure all of them
> offer a suitable out-of-band channel that could be used to send the
> relevant control/debug data. You could always make it part of the SQL
> interface, I suppose that would automatically give you cross-client
> support.
>

Could the out-of-bound channel be solved by requiring at least more than
one connection to the database?  One connection that acts like a
controller that executes debug commands and can respond to the results
while a second connection would be the connection that actually steps
through the plpgSQL code?  Special SQL commands may need to be created,
such as, hook this connection to another connection.

What do you think?



Re: Debug plpgSQL stored procedures

От
Klint Gore
Дата:
On Mon, 05 Sep 2005 21:59:33 +0100, Richard Huxton <dev@archonet.com> wrote:
> Daniel Morgan wrote:
> > Does PostgreSQL provide a way to step-debug into plpgSQL stored procedures?
>
> Afraid not. One of the commercial versions of PG offered it as a feature
> IIRC, but I could be wrong, and if so it was some time ago.

The EMS manager can apparently do it.
http://www.sqlmanager.net/en/

klint.

+---------------------------------------+-----------------+
: Klint Gore                            : "Non rhyming    :
: EMail   : kg@kgb.une.edu.au           :  slang - the    :
: Snail   : A.B.R.I.                    :  possibilities  :
: Mail      University of New England   :  are useless"   :
:           Armidale NSW 2351 Australia :     L.J.J.      :
: Fax     : +61 2 6772 5376             :                 :
+---------------------------------------+-----------------+

Re: Debug plpgSQL stored procedures

От
"Jim C. Nasby"
Дата:
On Mon, Sep 05, 2005 at 05:17:41PM -0400, Daniel Morgan wrote:
> Richard Huxton wrote:
>
> >Daniel Morgan wrote:
> >
> >>Does PostgreSQL provide a way to step-debug into plpgSQL stored
> >>procedures?
> >
> It is a shame.  PostgreSQL is really rocking these days.  Especially
> with 8.0 on Windows.  I was really impressed how far it has come since
> the 6.x days running on Cygwin.

3rd hit on google:
http://www.sqlmanager.net/products/postgresql/manager/documentation/hs20160.html
--
Jim C. Nasby, Sr. Engineering Consultant      jnasby@pervasive.com
Pervasive Software      http://pervasive.com    work: 512-231-6117
vcard: http://jim.nasby.net/pervasive.vcf       cell: 512-569-9461

Re: Debug plpgSQL stored procedures

От
Sebastian Hennebrueder
Дата:
Klint Gore schrieb:

>On Mon, 05 Sep 2005 21:59:33 +0100, Richard Huxton <dev@archonet.com> wrote:
>
>
>>Daniel Morgan wrote:
>>
>>
>>>Does PostgreSQL provide a way to step-debug into plpgSQL stored procedures?
>>>
>>>
>>Afraid not. One of the commercial versions of PG offered it as a feature
>>IIRC, but I could be wrong, and if so it was some time ago.
>>
>>
>
>The EMS manager can apparently do it.
>http://www.sqlmanager.net/en/
>
>klint.
>
>
I am using it, but I allready had some issues when valid code was not
debugged. In generally it seems to work. You should test it with your
code carefully.

--
Best Regards / Viele Grüße

Sebastian Hennebrueder

----

http://www.laliluna.de

Tutorials for JSP, JavaServer Faces, Struts, Hibernate and EJB