Skip site navigation (1) Skip section navigation (2)

Re: PQgetvalue failed to return column value for non-text data in binary format

From: Jeff Lynn <jmlynn(at)rogers(dot)com>
To: pgsql-interfaces(at)postgresql(dot)org, andrewm(at)object-craft(dot)com(dot)au
Subject: Re: PQgetvalue failed to return column value for non-text data in binary format
Date: 2007-05-22 18:17:53
Message-ID: 465333D1.2020505@rogers.com (view raw or flat)
Thread:
Lists: pgsql-interfaces
Thank you for your comment about text and binary format.  To use text, I 
thought one will have to construct the insert sql statement on the fly, 
which will incurs server parsing, syntax checking followed by 
execution.  With binary format, I can simply prepare a statement and 
then update each binded parameter prior to execute the prepared 
statement over each records.

Is there a way for me to prepare the insert statment and pass in text 
instead of, say, double precision?  I experimented with that the the 
server reject the insert statement with "mismatched datatype" error.

Jeff


Responses

pgsql-interfaces by date

Next:From: Jeff LynnDate: 2007-05-22 18:23:55
Subject: Re: PQgetvalue failed to return column value for non-text data in binary format
Previous:From: Jeroen T. VermeulenDate: 2007-05-22 06:10:25
Subject: Re: PQgetvalue failed to return column value for non-text data in binary format

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group