Re: Wrong query result w/ propgraph single lateral col reference - Mailing list pgsql-hackers

From Ashutosh Bapat
Subject Re: Wrong query result w/ propgraph single lateral col reference
Date
Msg-id CAExHW5tqKgVxNP7ecQUXRnDwFpKFCa1MdkQCrFEfi91rzQBS9g@mail.gmail.com
Whole thread
In response to Re: Wrong query result w/ propgraph single lateral col reference  (Peter Eisentraut <peter@eisentraut.org>)
Responses Re: Wrong query result w/ propgraph single lateral col reference
List pgsql-hackers
On Wed, Jul 8, 2026 at 2:35 PM Peter Eisentraut <peter@eisentraut.org> wrote:
>
> I would like this code to be organized differently.  Note that the
> existing insert_*_record functions don't do any error checking; they are
> just there to make catalog modifications.  There are various check_*
> functions that pretty much correspond to syntax rule checks, but these
> are run after the catalog changes, hence the present issue.  Maybe we
> should have a set of "pre-check" functions in addition?
>

I chose to perform the checks in insert_*_record() functions to keep
them at a central place instead of dispersing all over like the
check_* functions. The latter need to peform their checks considering
the overall shape of the property graph, however, the specification
checks are fairly local - like duplicate property or label names
specified in the same command or duplicate labels being inserted -
they won't usually need checks across labels or elements for example.
I am afraid we might have to sprinkle pre_check_* functions at
multiple places - thus leading to a risk of missing places as this
code evolves.

Do you expect insert_element_record() to perform sanity checks of
labels or insert_label_record() to perform sanity checks on
properties? Or do you expect a hierarchy of pre_check_ functions
cascading from elements to labels to properties?

--
Best Wishes,
Ashutosh Bapat



pgsql-hackers by date:

Previous
From: David Rowley
Date:
Subject: Re: Add bms_offset_members() function for bitshifting Bitmapsets
Next
From: Daniel Gustafsson
Date:
Subject: Re: allow spread checkpoints when changing checksums online