Re: SQL Property Graph Queries (SQL/PGQ)

From: Ashutosh Bapat <ashutosh(dot)bapat(dot)oss(at)gmail(dot)com>
To: Peter Eisentraut <peter(at)eisentraut(dot)org>
Cc: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: SQL Property Graph Queries (SQL/PGQ)
Date: 2024-07-22 12:01:42
Message-ID: CAExHW5uF7KMcABuNVB1de6JRY3ne-jYEP3+8ycQZGkFA=1OTLw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Jul 17, 2024 at 11:04 AM Ashutosh Bapat
<ashutosh(dot)bapat(dot)oss(at)gmail(dot)com> wrote:
>
> On Mon, Jul 8, 2024 at 7:07 PM Ashutosh Bapat
> <ashutosh(dot)bapat(dot)oss(at)gmail(dot)com> wrote:
> >
> >
> >
> > On Thu, Jun 27, 2024 at 6:01 PM Peter Eisentraut <peter(at)eisentraut(dot)org> wrote:
> >>
> >> Here is a new version of this patch. I have been working together with
> >> Ashutosh on this. While the version 0 was more of a fragile demo, this
> >> version 1 has a fairly complete minimal feature set and should be useful
> >> for playing around with. We do have a long list of various internal
> >> bits that still need to be fixed or revised or looked at again, so there
> >> is by no means a claim that everything is completed.
> >
> >
> > PFA the patchset fixing compilation error reported by CI bot.
> > 0001 - same as previous one
> > 0002 - fixes compilation error
> > 0003 - adds support for WHERE clause in graph pattern missing in the first patch.
> >
>
> There's a test failure reported by CI. Property graph related tests
> are failing when regression is run from perl tests. The failure is
> reported only on Free BSD.

I thought it's related to FreeBSD but the bug could be observed
anywhere with -DRELCACHE_FORCE_RELEASE. It's also reported indirectly
by valgrind.

When infering properties of an element from the underlying table's
attributes, the attribute name pointed to the memory in the heap tuple
of pg_attribute row. Thus when the tuple was released, it pointed to a
garbage instead of actual column name resulting in column not found
error.

Attached set of patches with an additional patch to fix the bug.

0001 - same as previous one
0002 - fixes pgperltidy complaints
0003 - fixes compilation failure
0004 - fixes issue seen on CI
0005 - adds support for WHERE clause in graph pattern missing in the
first patch.

Once reviewed, patches 0002 to 0005 should be merged into 0001.

--
Best Wishes,
Ashutosh Bapat

Attachment Content-Type Size
0002-pgperltidy-fixes-20240722.patch text/x-patch 1.2 KB
0004-Fix-spurious-column-not-found-error-20240722.patch text/x-patch 1.0 KB
0003-Fix-compilation-error-20240722.patch text/x-patch 950 bytes
0005-support-WHERE-clause-in-graph-pattern-20240722.patch text/x-patch 7.2 KB
0001-WIP-SQL-Property-Graph-Queries-SQL-PGQ-20240722.patch text/x-patch 502.8 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Andrey M. Borodin 2024-07-22 12:08:55 Re: WIP: parallel GiST index builds
Previous Message Tomas Vondra 2024-07-22 11:53:31 Re: WIP: parallel GiST index builds