Received: from localhost (unknown [200.46.208.211]) by mail.postgresql.org (Postfix) with ESMTP id E2D32633C39 for ; Thu, 31 Dec 2009 14:17:40 -0400 (AST) Received: from mail.postgresql.org ([200.46.204.86]) by localhost (mx1.hub.org [200.46.208.211]) (amavisd-maia, port 10024) with ESMTP id 00762-03 for ; Thu, 31 Dec 2009 18:17:28 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from serv01.siteground178.com (ns1.siteground178.com [67.15.255.19]) by mail.postgresql.org (Postfix) with ESMTP id 0CE46633C0A for ; Thu, 31 Dec 2009 14:17:30 -0400 (AST) Received: from [67.15.255.19] (port=57286 helo=intermodalsoftwaresolutions.net) by serv01.siteground178.com with esmtpa (Exim 4.69) (envelope-from ) id 1NQPaQ-0004PK-Sd; Thu, 31 Dec 2009 12:17:26 -0600 Received: from phpmailer ([76.106.235.204]) by intermodalsoftwaresolutions.net with HTTP (PHPMailer); Thu, 31 Dec 2009 12:17:26 -0600 Date: Thu, 31 Dec 2009 12:17:26 -0600 To: Gary Chambers Cc: pgsql-sql@postgresql.org From: Michael Gould Subject: Re: Proper case function Message-ID: X-Priority: 3 X-Mailer: PHPMailer [version 1.71] X-Mailer: FeLaMiMail In-Reply-To: <302670f20912310940v2307bd0ey368815943615d37e@mail.gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="iso-8859-1" X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - serv01.siteground178.com X-AntiAbuse: Original Domain - postgresql.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - intermodalsoftwaresolutions.net X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.302 tagged_above=-10 required=5 tests=AWL=1.297, BAYES_00=-2.599 X-Spam-Level: X-Archive-Number: 200912/96 X-Sequence-Number: 33534 Gary, Based on what I read it wouldn't handle cases where the result should be MacDonald from macdonald. There are other cases such as the sentence = below ('it''s crazy! i couldn''t believe kate mcdonald, leo dicaprio, (terrence) trent d''arby (circa the 80''s), and jada pinkett-smith all showed up to [cHris o''donnell''s] party...donning l''oreal lIpstick! They''re heading = to o''neil''s pub later on t''nite. the_underscore_test. the-hyphen-test) This wouldn't handle the quotes and proper case all of the words. Best Regards Mike Gould "Gary Chambers" wrote: >> Has anyone got a proper case function that they are willing to share. =A0We're >> moving from SQL Anywhere to PostgreSQL and decided that much of our = data is >> upper case when it really should be proper cased. =A0The columns that = we will >> be putting proper case data in are all defined using the contrib module >> citext which makes searching very nice. >=20 > Why doesn't the initcap function work as you require? >=20 > -- Gary Chambers >=20 > /* Nothing fancy and nothing Microsoft! */ >=20 > --=20 > Sent via pgsql-sql mailing list (pgsql-sql@postgresql.org) > To make changes to your subscription: > http://www.postgresql.org/mailpref/pgsql-sql >=20 -- Michael Gould, Managing Partner Intermodal Software Solutions, LLC 904.226.0978 904.592.5250 fax