Improve wrong-tuple-type error reports in contrib/tablefunc.
These messages were fairly confusing, and didn't match the
column names used in the SGML docs. Try to improve that.
Also use error codes more specific than ERRCODE_SYNTAX_ERROR.
Patch by me, reviewed by Joe Conway
Discussion: https://postgr.es/m/18937.1709676295@sss.pgh.pa.us
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/76904eda25500dd4c6969f3a2a7c0f00146fd763
Modified Files
--------------
contrib/tablefunc/expected/tablefunc.out | 85 ++++++++++++++--
contrib/tablefunc/sql/tablefunc.sql | 42 ++++++++
contrib/tablefunc/tablefunc.c | 169 ++++++++++++++-----------------
3 files changed, 195 insertions(+), 101 deletions(-)