Re: Pass ParseState as down to utility functions.
Michael Paquier <michael@paquier.xyz>
From: Michael Paquier <michael@paquier.xyz>
To: jian he <jian.universality@gmail.com>
Cc: Tom Lane <tgl@sss.pgh.pa.us>, Kirill Reshke <reshkekirill@gmail.com>, Alvaro Herrera <alvherre@alvh.no-ip.org>, PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2025-01-27T04:57:23Z
Lists: pgsql-hackers
On Fri, Dec 27, 2024 at 03:01:58PM +0800, jian he wrote:
> please check attached for changes within ATPrepAlterColumnType
Sorry for the late reply. This is more complete. Two strings are
more complex after doing the coerce_to_target_type(), but honestly I
am not these are worth having a parser_errposition() as they also have
an errhint().
> Maybe we can change to
> errmsg("conflicting NO INHERIT declarations for not-null constraints
> on column \"%s\"", column->colname),
> errhint("specified primary key or identity sequence imply an inherited
> not-null constraint will be created")
>
> what do you think?
Hmm. Not sure that this is an improvement. Will think a bit more
about it.
--
Michael
Commits
-
Print out error position for some ALTER TABLE ALTER COLUMN type
- 65281391a937 18.0 landed
-
Print out error position for some more DDLs
- 0f23dedc9176 18.0 landed
-
Print out error position for CREATE DOMAIN
- 39240bcad56d 18.0 landed
-
Add some regression tests for missing DDL patterns
- 0172b4c9449e 18.0 landed
-
Re-implement the ereport() macro using __VA_ARGS__.
- e3a87b4991cc 13.0 cited