agora inbox for pgsql-sql@postgresql.org  
help / color / mirror / Atom feed
From: Michael Kleiser <mkl@webde-ag.de>
To: Robert Strötgen <robert@stroetgen.de>
Cc: pgsql-sql@postgresql.org
Subject: Re: German "umlaut insensitive" query
Date: Wed, 01 Sep 2004 16:36:11 +0200
Message-ID: <4135DE5B.2000805@webde-ag.de> (raw)
In-Reply-To: <4135D647.4060203@stroetgen.de>
References: <4135D647.4060203@stroetgen.de>

One solution:

select replace( replace( replace( replace( 'Test ä ö ü ß', 'ä','ae'), 'ö','oe' ), 'ü','ue'), 'ß','ss' );

      replace
------------------
  Test ae oe ue ss

If you also have upcase-characters, you have to extend the statement.


Robert Strötgen schrieb:
> I want to query words with German "umlauts" (special characters) with
> and without normalization. I want to find "grün" (green) written
> "gruen" as well.
> 
> Using "LIKE" with locale de_DE.iso88591 or .utf-8 does not help (Locale 
> support should affect "LIKE",
> http://www.postgresql.org/docs/7.3/static/charset.html#AEN21761).
> 
> Any Idea how to solve this? Define a special Operator? Has anyone
> already done this before?
> 
> I am using PostgreSQL 7.3.2 on Linux.
> 
> TIA,
> Robert Strötgen. :)
> 



view thread (5+ messages)  latest in thread

Message-ID: <4135DE5B.2000805@webde-ag.de>
Permalink:  ../4135DE5B.2000805@webde-ag.de/
Also on:    postgresql.org/message-id/4135DE5B.2000805@webde-ag.de

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: mkl@webde-ag.de, robert@stroetgen.de
  Subject: Re: German "umlaut insensitive" query
  In-Reply-To: <4135DE5B.2000805@webde-ag.de>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox