X-Original-To: pgsql-odbc-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [64.117.224.130]) by svr1.postgresql.org (Postfix) with ESMTP id 68328D1B512 for ; Wed, 10 Sep 2003 16:54:44 +0000 (GMT) Received: from svr1.postgresql.org ([64.117.224.193]) by localhost (neptune.hub.org [64.117.224.130]) (amavisd-new, port 10024) with ESMTP id 29410-01 for ; Wed, 10 Sep 2003 13:54:14 -0300 (ADT) Received: from ecintweb.eldocomp.com (ecintweb.eldocomp.com [205.159.99.8]) by svr1.postgresql.org (Postfix) with ESMTP id D119AD1B4FE for ; Wed, 10 Sep 2003 13:54:12 -0300 (ADT) Received: by ecintweb.eldocomp.com with XWall v3.27j ; Wed, 10 Sep 2003 09:53:57 -0700 From: Andrew Ayers To: Greg Campbell Cc: "pgsql-odbc@postgresql.org" Subject: Re: ADO Case Sensitivity in Win2000/XP Date: Wed, 10 Sep 2003 09:54:17 -0700 X-Assembled-By: XWall v3.27j Message-ID: <3F5F5739.5070405@eldocomp.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable X-Virus-Scanned: by amavisd-new at postgresql.org X-Archive-Number: 200309/37 X-Sequence-Number: 3235 Greg Campbell wrote: [snip] > The ODBC driver is seeing lower case and I have to double-quote the > lower case in the string to make it work. Lower-casing and > double-quoting all tables names and field name is the kind of backend > specific sql changing I wanted to avoid. Is there a setting on the ODBC > Driver for Windows that will recognize the mixed case properly? IIRC, the setting isn't in the ODBC driver settings, but rather in the=20 setup of PG. Strangely enough, with my application I converted a bunch of Access=20 tables to PG, and noticed that on the backend, all of them seemed to be=20 lowercased (from the POV of psql). On the frontend (a VB6 app), the SQL=20 selects and such were mixed case (as that is how the original Access=20 tables were defined), but the driver handles it all fine (I am using a=20 DSN-less connection, so no special flags are being sent in the=20 connection string, other than setting ksqo to false). One thing to learn from this for future applications is to instead of=20 explicitly performing the SQL selects everywhere, have an include with a=20 function or something you can call, passing the SQL statement, and=20 returning something (the recordset or something, maybe). Everytime you=20 do a select, call this function with your SQL statement. Then, if in the=20 future you need to do something that will change every statement, you=20 can re-parse and change the statement in that one function, instead of=20 contemplating changing multiple areas throughout your code. If you find=20 that despite what you do, you still need to make the change you=20 outlined, perhaps now is the time to do this centralized function. Andrew Ayers Phoenix, Arizona >=20 >=20 > *************************************************************** > This email and all files transmitted with it are=20 > confidential and intended solely for the use of the=20 > individual or entity to whom they are addressed. If you=20 > are receiving this email in error please notify the=20 > system manager. >=20 > This footnote also confirms that this message=20 > has been swept for the presence of computer viruses. > *************************************************************** >=20 >=20 > ---------------------------(end of broadcast)--------------------------- > TIP 4: Don't 'kill -9' the postmaster >=20 -- CONFIDENTIALITY NOTICE -- This message is intended for the sole use of the individual and entity to w= hom it is addressed, and may contain information that is privileged, confid= ential and exempt from disclosure under applicable law. If you are not the = intended addressee, nor authorized to receive for the intended addressee, y= ou are hereby notified that you may not use, copy, disclose or distribute t= o anyone the message or any information contained in the message. If you ha= ve received this message in error, please immediately advise the sender by = reply email, and delete the message. Thank you.