Subject: Re: PQexec error handling

From: [email-masked] (James Woods 61-89-895256)
Date: Wed, 2 Jun 93 17:07:04 -0700

> PQexec currently returns "R" when you get a non-fatal error
> (sometimes setting PQerrormsg, sometimes not) and calls exit(2)
> on most "fatal" (backend coredump) errors.  this interface is
> less than useful for intelligent error-handling.

This sounds like a great idea.  How about (though this may take a while to 
implement) after the "R" or "E" supplying an integer representing some sort of 
error number which ties into a data structure of some sort which supplies more 
information.  Something which acts similar to the standard errno system.  I
would guess the tedious part about this would be numbering and rationalising all 
the error messages.

Well just a suggestion, and any improvement will be welcome.

thanks
James Woods
[email-masked]

---

From: "David J. Hughes" <[email-masked]>
Date: Wed, 2 Jun 93 22:00:54 -0700

> would guess the tedious part about this would be numbering and rationalising all 

Hmmm, I thought that was what PQerrormsg was for (ie. a textual
representation of the error).  If the setting of PQerrormsg was a little
more uniform, we'd have a much more workable solution.

> Well just a suggestion, and any improvement will be welcome.

Ditto.

bambi
   ___                                  David J. Hughes    [email-masked]
  /   \                /  /    /        
 /  __/ __   __   ____/  /    / __            Senior Network Programmer
/    \ /  \ /  \ /   /  /    / /  \  /      Comms Development & Operation
\____/ \__//   / \__/   \___/ /   / /   Qld. 4229  AUSTRALIA  (+61 75 951450)