Received: from barry.xythos.com ([64.139.0.223]) by postgresql.org (8.11.3/8.11.4) with ESMTP id fAQKa3m28560 for ; Mon, 26 Nov 2001 15:36:03 -0500 (EST) (envelope-from barry@xythos.com) Received: from xythos.com (localhost.localdomain [127.0.0.1]) by barry.xythos.com (8.11.6/8.11.6) with ESMTP id fAQKYhx09672; Mon, 26 Nov 2001 12:34:43 -0800 Message-ID: <3C02A763.4030300@xythos.com> Date: Mon, 26 Nov 2001 12:34:43 -0800 From: Barry Lind User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.6) Gecko/20011120 X-Accept-Language: en-us MIME-Version: 1.0 To: Bruce Momjian CC: pgsql-jdbc@postgresql.org Subject: Re: JDBC bug? References: <200111262013.fAQKDb415577@candle.pha.pa.us> Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-Archive-Number: 200111/279 X-Sequence-Number: 2476 Bruce Momjian wrote: >>I haven't seen any evidence in this thread of a JDBC bug. The original >>posting refered to calls in the DatabaseMetaData classes doing >>toLowerCase(). This is appropriate because the DatabaseMetaData class >>is querying the pg_* tables to get information about database objects, >>thus since the backend stores the identifiers in lower case, therefore >>the jdbc code needs to do a toLowerCase(). The followup below is more >> > > But the backend doesn't store identifiers in lowercase if they have > created mixed-case identifiers with double-quotes, right? I am > confused. > Correct. But if you ask the API to get information about table myTable, you should get an answer back for a table created as (create table myTable (foo text)). The only way to do this is to lowercase the input to match what the database is storing (mytable in this case). I agree that if the table is created with a mixed case identifier (create table "myTable" (foo text)) then there isn't a need to lower case in the driver. Therefore the fact that there are a bunch of calls to toLowerCase() in the jdbc code for DatabaseMetaData doesn't mean that there is a bug here as they are entirely appropriate under some circumstances. If someone produces a test case that demonstrates a bug I will be glad to look into it. But up to this point there has only been a lot of speculation on code that may be entirely correct. Test cases demonstrating a real problem would be much apprecieated in this case. thanks, --Barry > > >>of a complaint on how SQL is case insensitive and if you have created >>your objects with quoted mixed case identifiers you need to access them >>via quoted mixed case identifiers. I haven't seen any evidence that >>basic SQL operations (select, insert, update, delete) have a bug in them. >> >