Re: Parameter marker swapping in {fn timestampdiff()} - Mailing list pgsql-bugs

From Matthew Bellew
Subject Re: Parameter marker swapping in {fn timestampdiff()}
Date
Msg-id CAJnjrPOEm9ztybS=Yf3+Qs1OU+pEW0rQQcDT=TggucsfYTQFNQ@mail.gmail.com
Whole thread Raw
In response to Re: Parameter marker swapping in {fn timestampdiff()}  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-bugs
Thanks, reposted.

On Sun, Mar 26, 2023 at 11:54 AM Tom Lane <tgl@sss.pgh.pa.us> wrote:
Matthew Bellew <matthewb@labkey.com> writes:
> I recently made a small change to a core utility and our sql tests flagged
> some unexpected results.  I traced these to timestampdiff().  Below is a
> running code function (except for creating the JDBC Connection).  I expect
> the same result for all three executeQuery() calls.  The version that uses
> string literals return 366 and the versions that use parameter markers
> return -366.

You probably want to report that on the pgsql-jdbc list.  This list
mainly deals in bugs in core Postgres, so I'm not very sure whether
the JDBC maintainers read it.

                        regards, tom lane

pgsql-bugs by date:

Previous
From: Tom Lane
Date:
Subject: Re: Parameter marker swapping in {fn timestampdiff()}
Next
From: Richard Guo
Date:
Subject: Re: A structure has changed but comment modifications maybe missed