Received: from paris.netalfa.com.br ([200.210.212.12]) by hub.org (8.9.3/8.9.3) with ESMTP id PAA74581 for ; Wed, 21 Jul 1999 15:49:12 -0400 (EDT) (envelope-from robson@netalfa.com.br) Received: from Designer2 ([200.210.212.30]) by paris.netalfa.com.br (8.9.2/8.9.2) with SMTP id QAA22817 for ; Wed, 21 Jul 1999 16:52:11 -0300 (EST) Message-ID: <000601bed3b1$b3cbc2a0$1ed4d2c8@Designer2.netalfa.com.br> Reply-To: "Robson Martins" From: "Robson Martins" To: "pgsql-interfaces" Subject: Re: [INTERFACES] ResultSet.... Date: Wed, 21 Jul 1999 16:46:18 -0300 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 4.72.3110.5 X-MimeOLE: Produced By Microsoft MimeOLE V4.72.3110.3 -----Mensagem original----- De: Constantin Teodorescu Para: Robson Martins Data: Quarta-feira, 21 de Julho de 1999 15:24 Assunto: Re: [INTERFACES] ResultSet.... >Robson Martins wrote: >> >> ahh..Another thing. You gave me the wrong answer to get the count value i >> have to use: >> total = rs.getInt("count"); > >You're wrong ! >Both of them work :-) > >See JDBC documentation bellow: > > >public int getInt(int columnIndex) > throws SQLException > >Gets the value of a column in the current row as a Java int. >Parameters: > columnIndex - the first column is 1, the second is 2, ... >Returns: > the column value; if the value is SQL NULL, the result is 0 >Throws: > SQLException - if a database access error occurs > > > and also > > >public int getInt(String columnName) > throws SQLException > >Gets the value of a column in the current row as a Java int. >Parameters: > columnName - the SQL name of the column >Returns: > the column value; if the value is SQL NULL, the result is 0 >Throws: > SQLException - if a database access error occurs > >Best regards, >Teo > Thanks for the help man.... Hugs...Robson!