aboutsummaryrefslogtreecommitdiff
path: root/src/backend/tcop/postgres.c
diff options
context:
space:
mode:
authorPeter Eisentraut <peter@eisentraut.org>2022-09-26 15:25:59 +0200
committerPeter Eisentraut <peter@eisentraut.org>2022-09-26 15:25:59 +0200
commit8999f5ed3cd7d26be1121d912086d04d134d398b (patch)
tree6b1b0af38f9cb912da6781fa6e54c9c4ee0746d6 /src/backend/tcop/postgres.c
parentaf51b2f042a0808943125b82c0d6e785259069f2 (diff)
downloadpostgresql-8999f5ed3cd7d26be1121d912086d04d134d398b.tar.gz
postgresql-8999f5ed3cd7d26be1121d912086d04d134d398b.zip
Fix write/read of empty string fields in Nodes.
Historically, outToken has represented both NULL and empty-string strings as "<>", which readfuncs.c then read as NULL, thus failing to preserve empty-string fields accurately. Remarkably, this has not caused any serious problems yet, but let's fix it. We'll keep the "<>" notation for NULL, and use """" for empty string, because that matches other notational choices already in use. An actual input string of """" is converted to "\""" (this was true already, apparently as a hangover from an ancient time when string quoting was handled directly by pg_strtok). CHAR fields also use "<>", but for '\0'. Author: Tom Lane <tgl@sss.pgh.pa.us> Discussion: https://www.postgresql.org/message-id/flat/4159834.1657405226@sss.pgh.pa.us
Diffstat (limited to 'src/backend/tcop/postgres.c')
0 files changed, 0 insertions, 0 deletions