ArcadeDB Version: 22.11.1
JDK Version: openjdk version "11.0.17" 2022-10-18
OS: Ubuntu 22.04.1 LTS
Expected behavior
I'm trying to escape a single quote in a string enclosed in single quotes using the Postgres interface.
Which MAGIC in SELECT 'abc MAGIC def' will produce the output abc ' def?
chicken@asteroid:~$ psql --host=localhost testdatabase root
Password for user root:
psql (14.5 (Ubuntu 14.5-0ubuntu0.22.04.1), server 10.5)
Type "help" for help.
testdatabase=> SELECT 'abc MAGIC def';
'abc MAGIC def'
-----------------
abc ' def
(1 row)
It would be great to get something universal not limited to single quotes.
Actual behavior
The straight forward approach \' throws an error.
Postgres has escape strings (E'abc \' def') : https://www.postgresql.org/docs/current/sql-syntax-lexical.html#SQL-BACKSLASH-TABLE . Especially the hexadecimal byte values (\xhh) would be useful to escape anything.
Steps to reproduce
Connect to ArcadeDB with the psql client and run SELECT 'abc \' def':
chicken@asteroid:~$ psql --host=localhost testdatabase root
Password for user root:
psql (14.5 (Ubuntu 14.5-0ubuntu0.22.04.1), server 10.5)
Type "help" for help.
testdatabase=> SELECT 'abc \' def';
ERROR: Syntax error on executing query: Encountered " <IDENTIFIER> "def "" at line 1, column 16.
Was expecting one of:
<EOF>
<LIMIT> ...
<SKIP2> ...
<OFFSET> ...
<TIMEOUT> ...
<AS> ...
<LET> ...
<UNWIND> ...
";" ...
"," ...
...
ArcadeDB Version: 22.11.1
JDK Version: openjdk version "11.0.17" 2022-10-18
OS: Ubuntu 22.04.1 LTS
Expected behavior
I'm trying to escape a single quote in a string enclosed in single quotes using the Postgres interface.
Which
MAGICinSELECT 'abc MAGIC def'will produce the outputabc ' def?It would be great to get something universal not limited to single quotes.
Actual behavior
The straight forward approach
\'throws an error.Postgres has escape strings (
E'abc \' def') : https://www.postgresql.org/docs/current/sql-syntax-lexical.html#SQL-BACKSLASH-TABLE . Especially the hexadecimal byte values (\xhh) would be useful to escape anything.Steps to reproduce
Connect to ArcadeDB with the psql client and run
SELECT 'abc \' def':