Re: [PATCH] Add --syntax to postgres for SQL syntax checking - Mailing list pgsql-hackers

From David G. Johnston
Subject Re: [PATCH] Add --syntax to postgres for SQL syntax checking
Date
Msg-id CAKFQuwZq7misHStk3AqfRNBWjUWS0An6PpkaDmqWG5o2kh3zMg@mail.gmail.com
Whole thread Raw
In response to Re: [PATCH] Add --syntax to postgres for SQL syntax checking  (Josef Šimánek <josef.simanek@gmail.com>)
List pgsql-hackers
On Wed, May 15, 2024 at 12:35 PM Josef Šimánek <josef.simanek@gmail.com> wrote:
st 15. 5. 2024 v 21:33 odesílatel David G. Johnston
<david.g.johnston@gmail.com> napsal:

> Now, in my ideal world something like this could be made as an extension so that it can work on older versions and not have to be maintained by core.  And likely grow more features over time.  Is there anything fundamental about this that prevents it being implemented in an extension and, if so, what can we add to core in v18 to alleviate that limitation?

Like extension providing additional binary? Or what kind of extension
do you mean? One of the original ideas was to be able to do so (parse
query) without running postgres itself. Could extension be useful
without running postgres backend?


Pushing beyond my experience level here...but yes a separately installed binary (extension is being used conceptually here, this doesn't involve "create extension") that can inspect pg_config to find out where backend/postmaster library objects are installed and link to them.

David J.

pgsql-hackers by date:

Previous
From: Josef Šimánek
Date:
Subject: Re: [PATCH] Add --syntax to postgres for SQL syntax checking
Next
From: Tom Lane
Date:
Subject: Re: [PATCH] Add --syntax to postgres for SQL syntax checking