Improve error messages in parse_jsonb_index_flags(). Some of the error messages in this function weren't very well thought out. They mistook reachable cases for unreachable ones, and complained in words that were actually exactly backward from the condition they'd detected, and weren't helpful anyway.
Since this is just substituting better error text and a better SQLSTATE for what was there before, I don't feel a strong need to back-patch. Bug: #19910 Reported-by: Zheng Hacker <[email protected]> Author: Tom Lane <[email protected]> Discussion: https://postgr.es/m/[email protected] Branch ------ master Details ------- https://git.postgresql.org/pg/commitdiff/9b937d1d1d0c54e24280967ba1dd11aff66d1486 Modified Files -------------- src/backend/utils/adt/jsonfuncs.c | 13 +++++++++---- src/test/regress/expected/json.out | 3 ++- src/test/regress/expected/jsonb.out | 3 ++- 3 files changed, 13 insertions(+), 6 deletions(-)
