Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id 9F355476314 for ; Thu, 26 Sep 2002 20:17:57 -0400 (EDT) Received: from jupiter2.breezing.com (jupiter.breezing.com [63.172.201.30]) by postgresql.org (Postfix) with ESMTP id B701647610D for ; Thu, 26 Sep 2002 20:17:56 -0400 (EDT) Received: by jupiter2.breezing.com from localhost (router,SLMail V5.0); Thu, 26 Sep 2002 20:09:45 -0400 for Received: from [63.172.201.5] [63.172.201.5] by jupiter2.breezing.com [63.172.201.30] (SLmail 5.0.0.4342) with ESMTP id 781001BC2A504C5181383D70CF88C9AA for plus 2 more; Thu, 26 Sep 2002 20:09:44 -0400 Mime-Version: 1.0 X-Sender: jordan@jupiter.breezing.com Message-Id: In-Reply-To: <200209270133.35024.barwick@gmx.net> References: <5.1.0.14.0.20020927090709.02f125d0@cooee.squiz.net> <200209270133.35024.barwick@gmx.net> Date: Thu, 26 Sep 2002 20:17:35 -0400 To: Ian Barwick , Chris , pgsql-sql@postgresql.org From: Jordan Reiter Subject: Re: Case Sensitive "WHERE" Clauses? Content-Type: text/plain; charset="us-ascii" X-SLUIDL: E30B70E3-BFE84DFA-B07F0FB9-447C72DF X-Virus-Scanned: by AMaViS new-20020517 X-Archive-Number: 200209/348 X-Sequence-Number: 9625 > > > > Are string comparisons in postgresql case sensitive? >> > >> >Yes, unless you specify otherwise. >> > >> >Are you sure you are using the right database? I can >> >reproduce similar results, but only like this: >> >> You're using MySQL in these examples .. not Postgres :) > >Full points for paying attention ;-) > >This, erm, characteristic of the former caused me a lot of grief once... > >Anyone know what the ANSI standard is? I don`t recall any other >database apart from MySQL which default to case-insensitive >CHAR or VARCHAR columns. Microsoft Products (SQL Server, Access) are case-insensitive. I find it hard to understand why it's advantageous that column names are NOT case sensitive, while field content is. You have a *lot* more control over the database columns than you do over the content that goes into the fields. In my opinion, allowing someone to refer to a column as first_name, First_Name, or FIRST_NAME just encourages bad programming. -- Jordan Reiter mailto:jordan@breezing.com Breezing.com http://breezing.com 1106 West Main St phone:434.295.2050 Charlottesville, VA 22903 fax:603.843.6931