Use of PRId64 with PostgreSQL functions

From: "Paragon Corporation" <lr(at)pcorp(dot)us>
To: <pgsql-hackers(at)postgresql(dot)org>
Subject: Use of PRId64 with PostgreSQL functions
Date: 2015-07-31 19:43:07
Message-ID: 000001d0cbc9$200d9350$6028b9f0$
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

I've been currently suffering an issue in mingw64 with changes made in
PostGIS topology code base. Sadly it only happens to me (compiling in

Issue is when code like this was introduced

appendStringInfo(str, "%s%" PRId64, sep, edge->start_node);

Which uses a PostgreSQL function appendStringInfo - as noted here:

AFAICS -- the printf function works fine with the PRId64 so guessing it must
be something special about appenStringInfo

I noticed a thread in March on pgsql-hackers that discussed int limits

in PostgreSQL and Andres Freund made this comment which stuck in my head:

" for another we'd need some uglyness to determine the
correct printf modifier for int64_t (can't use PRId64 etc afaics)."

What exactly did he mean by can't use PRId64?

Regina Obe


Browse pgsql-hackers by date

  From Date Subject
Next Message Alvaro Herrera 2015-07-31 19:45:24 Re: brin index vacuum versus transaction snapshots
Previous Message Alvaro Herrera 2015-07-31 19:29:39 Re: [PROPOSAL] VACUUM Progress Checker.