Re: Problems with Error Messages wrt Domains, Checks
От | David G. Johnston |
---|---|
Тема | Re: Problems with Error Messages wrt Domains, Checks |
Дата | |
Msg-id | CAKFQuwYgV8CLbmV0MaPziKm_Uj2VC37dbzqvLP_3O9QjZLG-3g@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: Problems with Error Messages wrt Domains, Checks (Tom Lane <tgl@sss.pgh.pa.us>) |
Ответы |
Re: Problems with Error Messages wrt Domains, Checks
|
Список | pgsql-hackers |
"David G. Johnston" <david.g.johnston@gmail.com> writes:
> Frankly, I'm not seeing "invalid constant regular expressions" as being a
> large scale problem - but I'll agree that having the error include the
> actual literal being parsed as a RegEx should be done.
Agreed. Doing anything about the other stuff discussed in this thread is
fairly large-scale work, but adjusting our regex error messages is easy.
Another one that seems to fall into the "fairly large-scale work" would be the:
ERROR: more than one row returned by a subquery used as an expression
(that's it, nothing else prints in psql when I run the offending query - using "--echo-all" to at least see what query I sent caused the issue)
Found this via Google
Printing out the offending expression would be nice if possible - printing the set (size > 1) of values that were returned would probably help as well, though usually the problem data is in a where clause while the set would contain target list data - and its those where clause items that matter more. In the case of a correlated subquery exhibiting this problem the outer query vars being passed in is what would be most helpful.
David J.
P.S. I consider this to be on-topic to the general "hard to debug" topic this thread covers even if its doesn't involve domains...I may gripe more prominently later...
В списке pgsql-hackers по дате отправления: