Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

json.text off by one error #6798

Closed
monetdb-team opened this issue Nov 30, 2020 · 0 comments
Closed

json.text off by one error #6798

monetdb-team opened this issue Nov 30, 2020 · 0 comments

Comments

@monetdb-team
Copy link

@monetdb-team monetdb-team commented Nov 30, 2020

Date: 2019-12-10 17:30:52 +0100
From: @kutsurak
To: SQL devs <>
Version: 11.35.3 (Nov2019)

Last updated: 2019-12-20 15:36:33 +0100

Comment 27474

Date: 2019-12-10 17:30:52 +0100
From: @kutsurak

json.text removes the last character of the last element of the input if the separator is the empty string:

sql>select json.text('"abc"', '');
+------+
| %1 |
+======+
| ab |
+------+
1 tuple
sql>select json.text('["abc", "def"]', '');
+-------+
| %1 |
+=======+
| abcde |
+-------+
1 tuple
sql>select json.text('{"a":"abc", "b":"def"}', '');
+-------+
| L2 |
+=======+
| abcde |
+-------+
1 tuple

Comment 27475

Date: 2019-12-10 17:38:49 +0100
From: MonetDB Mercurial Repository <>

Changeset bcfd744a61b8 made by Panagiotis Koutsourakis kutsurak@monetdbsolutions.com in the MonetDB repo, refers to this bug.

For complete details, see https//devmonetdborg/hg/MonetDB?cmd=changeset;node=bcfd744a61b8

Changeset description:

Add test for Bug #6798

Comment 27476

Date: 2019-12-10 17:38:53 +0100
From: MonetDB Mercurial Repository <>

Changeset 01a51ecc108e made by Panagiotis Koutsourakis kutsurak@monetdbsolutions.com in the MonetDB repo, refers to this bug.

For complete details, see https//devmonetdborg/hg/MonetDB?cmd=changeset;node=01a51ecc108e

Changeset description:

json.text should not delete the last separator if it is empty

This fixes Bug #6798
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
1 participant