Hi Mark, Fetching a "real" type field from libpq doesn't look that intuitive. So this example is super helpful. Thanks.
I am wondering whether we should provide PQgetfloatvalue() which does what that example shows but transparently. It will return a float value of the given field instead of char *. That will standardize the way to fetch real typed values in libpq. That leads to the next question. Do we need to introduce different PQget*value() for standard C/SQL data types. -- Best Wishes, Ashutosh Bapat On Fri, Feb 25, 2022 at 3:12 AM Mark Wong <mark...@gmail.com> wrote: > > Hi everyone, > > Would adding additional examples to testlibpq3.c on handling more data > types be helpful? I've attached a patch adding how to handle a REAL to > current example. > > Regards, > Mark