Received: from localhost (maia-1.hub.org [200.46.204.191]) by postgresql.org (Postfix) with ESMTP id CA4839FBBA0 for ; Tue, 22 May 2007 15:18:09 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.191]) (amavisd-maia, port 10024) with ESMTP id 92393-05 for ; Tue, 22 May 2007 15:18:05 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.5 Received: from smtp109.rog.mail.re2.yahoo.com (smtp109.rog.mail.re2.yahoo.com [68.142.225.207]) by postgresql.org (Postfix) with SMTP id F1B799FBB13 for ; Tue, 22 May 2007 15:18:04 -0300 (ADT) Received: (qmail 57158 invoked from network); 22 May 2007 18:18:03 -0000 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=rogers.com; h=Received:X-YMail-OSG:Message-ID:Date:From:User-Agent:MIME-Version:To:Subject:Content-Type:Content-Transfer-Encoding; b=sQYN0CqXgJ/JuPHWMluxuUzJOV9hSgouXaZumRtvKeZ9rcUiVXGhuHXZxXiW8j8JsLnAinXAlvG9zkCdcGL+zu6wGtm4dRs2pKurl1Y/NiHWXbm42skh/RIXJAeoEsv4jibd9UhaW2uR3YACCVNtNUJAiLimS8uZrDhDmq6N43c= ; Received: from unknown (HELO ?127.0.0.1?) (ymlam@rogers.com@216.209.33.106 with plain) by smtp109.rog.mail.re2.yahoo.com with SMTP; 22 May 2007 18:18:03 -0000 X-YMail-OSG: O0B1Ig8VM1kFxxVOlkKVVB_9GVVfNKC8a7fRvFbL5uINXsLoVeXgBFUhbW9PzpPBpQ-- Message-ID: <465333D1.2020505@rogers.com> Date: Tue, 22 May 2007 14:17:53 -0400 From: Jeff Lynn User-Agent: Thunderbird 1.5.0.10 (Windows/20070221) MIME-Version: 1.0 To: pgsql-interfaces@postgresql.org, andrewm@object-craft.com.au Subject: Re: PQgetvalue failed to return column value for non-text data in binary format Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0.798 tagged_above=0 required=5 tests=BAYES_05=-1.11, DNS_FROM_RFC_ABUSE=0.2, DNS_FROM_RFC_POST=1.708 X-Spam-Level: X-Archive-Number: 200705/42 X-Sequence-Number: 6549 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