Re: SQL Property Graph Queries (SQL/PGQ) - Mailing list pgsql-hackers

From Ashutosh Bapat
Subject Re: SQL Property Graph Queries (SQL/PGQ)
Date
Msg-id CAExHW5te5O-QGVhN6YADeFYDDb2oi=U50u62ojRcVAiZ-AEF-g@mail.gmail.com
Whole thread
In response to Re: SQL Property Graph Queries (SQL/PGQ)  (Kirill Reshke <reshkekirill@gmail.com>)
Responses Re: SQL Property Graph Queries (SQL/PGQ)
Re: SQL Property Graph Queries (SQL/PGQ)
Re: SQL Property Graph Queries (SQL/PGQ)
List pgsql-hackers
Hi Peter,

> On Mon, 16 Mar 2026 at 17:43, Peter Eisentraut <peter@eisentraut.org> wrote:
> >
> > On 11.03.26 08:34, Ashutosh Bapat wrote:
> > > There are two new patches 0004 and 0005 in the attached patchset.
> >
> > I have committed this, including the 0004 patch.

Thanks a lot.

> > Let's consider the
> > 0005 patch separately.

Will share the rebased patch soon. This thread may see discussion
about the commit itself. Should I start a new thread for 0005 or use
this one? New one seems better to me with a new CF entry.

> >
> > The buildfarm shows some instability in the pg_upgrade test, because
> > labels are printed by pg_get_propgraphdef() in implementation-dependent
> > order.  Attached is a quick patch to sort the labels before printing.
> > Check please.

The patch looks fine to me. While reviewing it, I noticed that the
function has an extra loop to count the number of variables. I don't
think it's needed. The count can be obtained from the list length. In
the attached patch, I have removed that loop. Am I missing something?

0001 is your patch
0002 removes the loop + some cosmetic changes

Hi Kirill,

> Do we need to keep relation lock until end of function
> (table_close(pglrel, AccessShareLock);)?

I think you are right. Fixed in the attached.

> I'm not sure if list_sort is
> interruptible.

I don't think it matters here. It will be very rare, if not
impossible, to have so many labels as to let the sorting run for
milliseconds together. The foreach loop afterwards is also not
interruptible. Any reason you think it should be interruptible?

-- 
Best Wishes,
Ashutosh Bapat

Attachment

pgsql-hackers by date:

Previous
From: Bertrand Drouvot
Date:
Subject: Re: PGPROC alignment (was Re: pgsql: Separate RecoveryConflictReasons from procsignals)
Next
From: Alvaro Herrera
Date:
Subject: Re: Adding REPACK [concurrently]