Re: autogenerating error code lists (was Re: [COMMITTERS] pgsql: Add foreign data wrapper error code values for SQL/MED.)

Tom Lane <tgl@sss.pgh.pa.us>

From: Tom Lane <tgl@sss.pgh.pa.us>
To: Jan Urbański <wulczer@wulczer.org>
Cc: Robert Haas <robertmhaas@gmail.com>, pgsql-hackers@postgresql.org, Shigeru HANADA <hanada@metrosystems.co.jp>
Date: 2010-12-26T19:57:26Z
Lists: pgsql-hackers

Commits

Same data as JSON: GET /api/v1/messages/:b64id/commits the thread's linked commits as JSON, with link sources. API reference →
  1. Add foreign data wrapper error code values for SQL/MED.

=?UTF-8?B?SmFuIFVyYmHFhHNraQ==?= <wulczer@wulczer.org> writes:
> How about a format like this then:

> # Comment
> Section: Class 2F - SQL Routine Exception
> macro_name sqlstate plpgsqlname is_error

> That is: # and blank lines are comments, lines starting with "Section:"
> are section names (needed for SGML output), the rest are whitespace
> separated strings. is_error is 0 or 1, if it's 0 we don't generate a
> plpgsql condition for it.

Or just leave out the plpgsqlname if we don't want a condition to be
generated?

Things might line up nicer if the sqlstate is the first column.

			regards, tom lane