Misplaced double quotes in error message

From: Thomas Kellerer <shammat(at)gmx(dot)net>
To: "pgsql-general(at)lists(dot)postgresql(dot)org" <pgsql-general(at)lists(dot)postgresql(dot)org>
Subject: Misplaced double quotes in error message
Date: 2021-10-07 06:17:16
Message-ID: bdda62ba-ec52-60bb-ab43-786187d7066c@gmx.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hello,

consider the following table, query and error message:

create table t
(
"someColumn" int
);

select t.someColumn
from t;

ERROR: column t.somecolumn does not exist
Hint: Perhaps you meant to reference the column "t.someColumn".

For someone proficient in SQL it's pretty clear what the error message means,
but the quotes can be misleading for someone who doesn't really understand
what's going on.

I think if the error message quoted the column name the way it should actually
be used, it would make things easier for someone not used to this, e.g.:

Hint: Perhaps you meant to reference the column t."someColumn".

Because when the user takes the error message literally they might be tempted
to use "t.someColumn" just to be confronted with the same error message again
which then seems even more confusing.

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Marco Lechner 2021-10-07 08:19:25 AW: how to merge two postgresql server instances into one
Previous Message Bryn Llewellyn 2021-10-06 22:46:54 Re: Using make_timestamp() to create a BC value