Re: SQL Property Graph Queries (SQL/PGQ)

From: Ashutosh Bapat <ashutosh(dot)bapat(dot)oss(at)gmail(dot)com>
To: Junwang Zhao <zhjwpku(at)gmail(dot)com>
Cc: Vik Fearing <vik(at)postgresfriends(dot)org>, Ajay Pal <ajay(dot)pal(dot)k(at)gmail(dot)com>, Imran Zaheer <imran(dot)zhir(at)gmail(dot)com>, Peter Eisentraut <peter(at)eisentraut(dot)org>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: SQL Property Graph Queries (SQL/PGQ)
Date: 2025-01-28 10:26:45
Message-ID: CAExHW5saaVXr1rpsxBbkGDLKhVirrWEXQPcM_7nUv9R3UEYuWA@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Fri, Jan 24, 2025 at 9:16 PM Junwang Zhao <zhjwpku(at)gmail(dot)com> wrote:
>
> I figured out it's because I have `-DWRITE_READ_PARSE_PLAN_TREES` this option,
> removing this option clears the warning, but I'm not sure if this is a
> hidden issue.
>

Thanks for the hint. I found the issue and the fix appears in 0004.
Some members of RangeTblEntry were not being handled in read/out
functions.

> >
> > 0001-0009 patches are the same as the previous set sans mergeconflict fixes.
> > 0010 - is test for \dGx - to make sure that the extended format output
> > works with \dG. We may decide not to have this patch in the final
> > commit. But no harm in being there til that point.
>
> I have some changes based on the latest patch set. I attached two patches with
> the following summary.
>
> 0001:
> - doc: some of the query in ddl.sgml can not be executed

The standard seems to require a property reference to be qualified by
element pattern variable, even if the property is referenced within
the same element pattern bound to the variable. Hence I accepted your
document fixes which qualify property reference with element pattern
variable.

However, I didn't understand why you changed a LABEL name from order to order_.

> - after path factor was introduced, some comments doesn't apply

Thanks pointing those out. Accepted after rephrasing those and also
correcting some related comments.

>
> 0002:
> - add a get_propgraph_element_alias_name function and do some trivial refactor
>

I see you have added some negative tests - object not found tests, but
I didn't see positive tests. Hence I haven't added those changes in
the attached patchset. But we certainly need those changes. You may
want to submit a patch with positive tests. That code needs to be
fixed before committing anyway.

--
Best Wishes,
Ashutosh Bapat

Attachment Content-Type Size
pg_sql_pgq-20250128.zip application/zip 164.5 KB

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Antonin Houska 2025-01-28 10:30:56 Proposal to make temporary change of memory context a bit safer
Previous Message Bernd Helmle 2025-01-28 10:25:51 Re: Modern SHA2- based password hashes for pgcrypto