Re: [sqlsmith] Failed to generate plan on lateral subqueries - Mailing list pgsql-hackers

From Andreas Seltenreich
Subject Re: [sqlsmith] Failed to generate plan on lateral subqueries
Date
Msg-id 87bn9xhqzl.fsf@elite.ansel.ydns.eu
Whole thread Raw
In response to Re: [sqlsmith] Failed to generate plan on lateral subqueries  (Peter Geoghegan <pg@heroku.com>)
List pgsql-hackers
Peter Geoghegan writes:

> On Sun, Dec 6, 2015 at 9:52 AM, Andreas Seltenreich <seltenreich@gmx.de> wrote:
>> I've added new grammar rules to sqlsmith and improved some older ones.
>
> Could you possibly teach sqlsmith about INSERT ... ON CONFLICT DO
> UPDATE/IGNORE? I think that that could be very helpful, especially if
> it could be done in advance of any stable release of 9.5.

In summary, it can't be added ad-hoc, but might still happen in advance
of the release of 9.5.

Adding upsert needs significiant effort because historically,
non-boolean value expression productions yield a random type.  This is
not a problem for generating queries, but it is for inserts.  Also,
sqlsmith can at the moment only generate sensible value expressions from
column references.  Generating a proper upsert would require supporting
type-constraining of productions as well as adding productions for
pulling values out of thin air (e.g., generating atomic value subselects
or calling argumentless functions).

regards,
Andreas



pgsql-hackers by date:

Previous
From: Robert Haas
Date:
Subject: Re: Rework the way multixact truncations work
Next
From: Masahiko Sawada
Date:
Subject: Re: Tab-comletion for RLS