Received: from maia.hub.org (unknown [200.46.208.211]) by mail.postgresql.org (Postfix) with ESMTP id B7FE065A0A2 for ; Thu, 21 Jan 2010 11:23:06 -0400 (AST) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.208.211]) (amavisd-maia, port 10024) with ESMTP id 00376-01-6 for ; Thu, 21 Jan 2010 15:22:47 +0000 (UTC) Received: from mx1.hub.org (mx1.hub.org [200.46.208.106]) by mail.postgresql.org (Postfix) with ESMTP id 0B38465A0CB for ; Thu, 21 Jan 2010 11:22:37 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from leary.csoft.net (leary.csoft.net [205.205.214.5]) by mx1.hub.org (Postfix) with ESMTP id BB6B33262C51 for ; Thu, 21 Jan 2010 11:22:34 -0400 (AST) Received: by leary.csoft.net (Postfix, from userid 1112) id 0F3ACA38B; Thu, 21 Jan 2010 10:22:23 -0500 (EST) Date: Thu, 21 Jan 2010 10:22:23 -0500 (EST) From: Kris Jurka X-X-Sender: books@leary.csoft.net To: Saurabh Jain cc: pgsql-jdbc@postgresql.org Subject: Re: Java equivalent data type for chkpass. In-Reply-To: <278314.65519.qm@web8501.mail.in.yahoo.com> Message-ID: References: <278314.65519.qm@web8501.mail.in.yahoo.com> User-Agent: Alpine 2.00 (BSO 1167 2008-08-23) MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-2.541 tagged_above=-10 required=5 tests=AWL=0.058, BAYES_00=-2.599 X-Spam-Level: X-Archive-Number: 201001/63 X-Sequence-Number: 20259 On Thu, 21 Jan 2010, Saurabh Jain wrote: > I am updating chkpass data type column using JDBC preparedstatement, but it > give me following exception. > > org..postgresql.util.PSQLException: ERROR: column "password" is of type > chkpass but expression is of type character varying > > Is anybody aware of the data type we should set for this password column? > You should use setObject(index, value, Types.OTHER) to indicate that it's not the exact type of value (String apparently), but something else instead. Kris Jurka