Received: from malur.postgresql.org ([217.196.149.56]) by arkaria.postgresql.org with esmtp (Exim 4.80) (envelope-from ) id 1ZLCQj-00080w-Ki for pgsql-jdbc@arkaria.postgresql.org; Fri, 31 Jul 2015 15:41:05 +0000 Received: from localhost ([127.0.0.1] helo=postgresql.org) by malur.postgresql.org with smtp (Exim 4.84) (envelope-from ) id 1ZLCQi-0001qt-IN for pgsql-jdbc@arkaria.postgresql.org; Fri, 31 Jul 2015 15:41:04 +0000 Received: from magus.postgresql.org ([2a02:c0:301:0:ffff::29]) by malur.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84) (envelope-from ) id 1ZLCQi-0001qh-2e for pgsql-jdbc@postgresql.org; Fri, 31 Jul 2015 15:41:04 +0000 Received: from rad0.itstriangle.com ([199.38.107.90]) by magus.postgresql.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_CBC_SHA384:256) (Exim 4.84) (envelope-from ) id 1ZLCQa-0006DW-30 for pgsql-jdbc@postgresql.org; Fri, 31 Jul 2015 15:41:01 +0000 Received: from itstriangle.com (localhost [127.0.0.1]) by rad0.itstriangle.com (8.14.4/8.14.4) with ESMTP id t6VFel7F013112; Fri, 31 Jul 2015 11:40:48 -0400 Received: FROM [192.168.157.52] ([216.220.4.222]) BY itstriangle.com WITH ESMTP ; Fri, 31 Jul 2015 11:40:46 -0400 Message-ID: <55BB99F7.4040001@ttc-cmc.net> Date: Fri, 31 Jul 2015 09:53:27 -0600 From: dmp User-Agent: Mozilla/5.0 (X11; Linux i686; rv:24.0) Gecko/20100101 Firefox/24.0 SeaMonkey/2.21 MIME-Version: 1.0 To: =?ISO-8859-1?Q?Bal=E1zs_Zsoldos?= , PostgreSQL JDBC Subject: Re: Why is columnNames in Connection.prepareStatement(sql, columnNames[]) automatically quoted References: In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit X-Pg-Spam-Score: -1.9 (-) List-Archive: List-Help: List-ID: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: X-Mailing-List: pgsql-jdbc Precedence: bulk Sender: pgsql-jdbc-owner@postgresql.org Balázs Zsoldos wrote: > One of the solutions is that I quote in every database and every statement. If > that is the only way, I can accept that. The one who has to write SQL statements > by hand on the command line might get a bit angry :-). Hello Balázs, I have a generic access tool for databases and support Derby, H2, HSQL, MariaDB, MS SQL, MSAccess, MySQL, Oracle, PostgreSQL, and SQLite. Early on I did not quote table, column names, etc. In not doing so it became obvious the tool would not be able to work with some users mixed upper and lower case character definitions for identifiers. Most of the database do use quotes for identifiers for the reason Dave indicated to support upper and lowercase character definitions for users. I also advise properly quoting field data that are not explicity defined as numbers. Case by case context of course. danap. -- Sent via pgsql-jdbc mailing list (pgsql-jdbc@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-jdbc