Re: Some macros for error field codes

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Peter Eisentraut <peter_e(at)gmx(dot)net>
Cc: PostgreSQL Development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Some macros for error field codes
Date: 2003-07-28 07:57:08
Message-ID: 3278.1059379028@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Peter Eisentraut <peter_e(at)gmx(dot)net> writes:
> Should we create some user-friendly macros for the error field codes? I
> have a feeling that PGXYZ_SQLSTATE may make for better code than just 'C'.

I just pushed the ERRCODE_ macros out into their own file. How about
placing that file where client apps can include it directly?

Note though that I think client apps will want to test "is this code in
this class" about as often as they'll want to check for specific
codes. We might need to provide some additional infrastructure to
handle that.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Philip Yarra 2003-07-28 08:02:18 Re: OSF build fixed
Previous Message Peter Eisentraut 2003-07-28 07:50:29 "is_superuser" parameter creates inconsistencies