X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [200.46.204.144]) by svr1.postgresql.org (Postfix) with ESMTP id 2FEBF5373A for ; Fri, 22 Apr 2005 12:17:50 -0300 (ADT) Received: from svr1.postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 66140-01 for ; Fri, 22 Apr 2005 15:17:39 +0000 (GMT) Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by svr1.postgresql.org (Postfix) with ESMTP id 5B91353733 for ; Fri, 22 Apr 2005 12:17:36 -0300 (ADT) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.13.1/8.13.1) with ESMTP id j3MFHXeG000987; Fri, 22 Apr 2005 11:17:33 -0400 (EDT) To: Palle Girgensohn Cc: pg@fastcrypt.com, pgsql-jdbc@postgresql.org Subject: Re: BUG? res.next() == false, but psql finds tuples? In-reply-to: References: <42690728.9040101@fastcrypt.com> <809.1114182092@sss.pgh.pa.us> Comments: In-reply-to Palle Girgensohn message dated "Fri, 22 Apr 2005 17:09:30 +0200" Date: Fri, 22 Apr 2005 11:17:33 -0400 Message-ID: <986.1114183053@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, hits=0.006 tagged_above=0 required=5 tests=AWL X-Spam-Level: X-Archive-Number: 200504/143 X-Sequence-Number: 12750 Palle Girgensohn writes: > --On fredag, april 22, 2005 11.01.32 -0400 Tom Lane > wrote: >> I'm wondering about misassignment of data types or something. It's not >> clear though how that would result in no error but zero rows returned. >> What are the column data types exactly? > userid is text (setInt()) > courseid is int (setString()) The tcpdump shows that JDBC is specifying the parameter types as 1043 (varchar) and 23 (int4). It's hard to believe that varchar versus text would be an issue ... but ... what happens if you do this in psql? select lang from participant where userid = 'mango'::varchar and course_id = 38; regards, tom lane