Received: from relay.it.pl (relay2.it.pl [195.94.200.10]) by hub.org (8.9.2/8.9.1) with ESMTP id JAA42977 for ; Tue, 9 Mar 1999 09:40:35 -0500 (EST) (envelope-from barteo@it.pl) Received: from zloty.it.com.pl (zloty.it.com.pl [195.116.142.4]) by relay.it.pl with ESMTP id PAA03400 for ; Tue, 9 Mar 1999 15:40:28 +0100 (MET) Received: from it.pl (yen.it.pl [195.116.139.234]) by zloty.it.com.pl with ESMTP id PAA13337 for ; Tue, 9 Mar 1999 15:40:27 +0100 (MET) Sender: root@zloty.it.com.pl Message-ID: <36E533E9.B72B4C64@it.pl> Date: Tue, 09 Mar 1999 15:44:57 +0100 From: Bartek Teodorczyk X-Mailer: Mozilla 4.07 [en] (X11; I; Linux 2.1.130 i586) MIME-Version: 1.0 To: pgsql-interfaces@postgresql.org Subject: Getting field length in libpq Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit I have following problem: I need to get the length of field after executing query. For INT4 fields it is simple (call PQfsize and get 4) but when I have VARCHAR(30) field PQfsize returns -1. I cannot call PQgetlength for example first tuple because this tuple can have 10 chars and PQgetlength returns 10 but I need 30. Have you any solutions? BarTeo