Re: Error handling in plperl and pltcl

From: Thomas Hallgren <thhal(at)mailblocks(dot)com>
To: Richard Huxton <dev(at)archonet(dot)com>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, James William Pye <flaw(at)rhid(dot)com>, Jan Wieck <JanWieck(at)Yahoo(dot)com>, Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Error handling in plperl and pltcl
Date: 2004-12-01 09:56:45
Message-ID: thhal-04i2JAlFRcC4yUi8pxQkJIq22g0eQWZ@mailblocks.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Richard Huxton,

> It feels more distinct to me. I'll grant you I'm only a sample size of
> 1 though.

Perhaps more distinct, but:

- Using savepoints together with try/catch is not exactly an unknown
concept. Try Google and you'll see a fair amount of examples advocating
the approach that I suggest.
- If I have to learn yet another new thing, I'd like to learn how to use
savepoints since that knowledge can be used everywhere.
- There's no such thing as a pgtry in the Tcl language (nor in any other
language), thus you change the language as such.
- Tcl code will look different depending on if it's client code or code
residing in the backend. I.e. the construct is not portable. Then again,
perhaps the Tcl bindings are very different anyway so that argument may
be less important. For PL/Java it makes a lot of sense since the client
and server implementation uses a common set of interfaces.

Regards,
Thomas Hallgren

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Simon Riggs 2004-12-01 10:03:40 Re: nodeAgg perf tweak
Previous Message Richard Huxton 2004-12-01 09:34:50 Re: Error handling in plperl and pltcl