Actually, this is just the tip of the iceberg.
Funny, but
postgres=# select '\u'::text;
text
\u
(1 row)
postgres=# select array['\u']::text[];
array
-
{"\\u"}
postgres=# select '{"\u"}'::text[];
text
-
{u}
postgres=# select '{"\
On 05/29/2014 08:15 AM, Andrew Dunstan wrote:
On 05/29/2014 08:00 AM, Teodor Sigaev wrote:
postgres=# select '["\u"]'::json->0;
?column?
--
"\u"
(1 row)
Time: 1,294 ms
postgres=# select '["\u"]'::jsonb->0;
?column?
---
"\\u"
(1 row)
It seems to me that es
On 05/29/2014 08:00 AM, Teodor Sigaev wrote:
postgres=# select '["\u"]'::json->0;
?column?
--
"\u"
(1 row)
Time: 1,294 ms
postgres=# select '["\u"]'::jsonb->0;
?column?
---
"\\u"
(1 row)
It seems to me that escape_json() is wrongly used in
jsonb_put_escap
postgres=# select '["\u"]'::json->0;
?column?
--
"\u"
(1 row)
Time: 1,294 ms
postgres=# select '["\u"]'::jsonb->0;
?column?
---
"\\u"
(1 row)
It seems to me that escape_json() is wrongly used in jsonb_put_escaped_value(),
right name of escape_json() is a es