Re: [HACKERS] jsonb problematic operators - Mailing list pgsql-hackers

From Merlin Moncure
Subject Re: [HACKERS] jsonb problematic operators
Date
Msg-id CAHyXU0wF+c1gPpaV1XXw4qbnXBNXZoTsHOdbWj+9DvK8bcESOw@mail.gmail.com
Whole thread Raw
In response to Re: [HACKERS] jsonb problematic operators  (Craig Ringer <craig@2ndquadrant.com>)
Responses Re: [HACKERS] jsonb problematic operators
List pgsql-hackers
On Sun, Dec 11, 2016 at 10:59 PM, Craig Ringer <craig@2ndquadrant.com> wrote:
> PgJDBC allows you to write ??, which is ugly, but tolerable, since the
> JDBC spec doesn't have an escape syntax for it.

This is the core problem; *JDBC* is busted.  SQL reserves words but
not punctuation marks so any assumption by client side code that
characters are not going to be interpreted by the server are going to
cause problems.  As noted earlier ":" is equally problematic as that
is hibernate's parameter marker and hibernate is probably in even
greater usage than naked JDBC in the java community.

Imagine trying to embed, say, perl, in java and reserving the very
same punctuation marks and then complaining to the perl community that
their language is broken due to usage overlap...that's what's
happening here.  If we really wanted to fix this, maybe the right way
to think about the problem is a highly reduced character set and a
pre-processor or an extension.

merlin



pgsql-hackers by date:

Previous
From: Fujii Masao
Date:
Subject: Re: [HACKERS] [COMMITTERS] pgsql: Add support for temporary replication slots
Next
From: Heikki Linnakangas
Date:
Subject: Re: [HACKERS] Password identifiers, protocol aging and SCRAM protocol