Re: [HACKERS] Re: [PATCHES] char/varchar locale support

From: Michal Mosiewicz <mimo(at)interdata(dot)com(dot)pl>
To: hackers(at)postgresql(dot)org
Cc: "Thomas G(dot) Lockhart" <lockhart(at)alumni(dot)caltech(dot)edu>
Subject: Re: [HACKERS] Re: [PATCHES] char/varchar locale support
Date: 1998-05-18 16:35:47
Message-ID: 35606363.3884309@interdata.com.pl
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Thomas G. Lockhart wrote:

> btw, if we do implement NATIONAL CHARACTER I would like to do so by
> having it fit in with the full SQL92 character sets and collating
> sequences capabilities. Then one could specify what NATIONAL CHAR means
> for an installation or perhaps at run time without having to
> recompile...

I fully agree that there should be a CREATE COLLATION syntax or similiar
with ability to add collation keyword in every place that needs a
character comparision, like btree indexes, orders, or simply comparision
operators.

This mean that we should start probably from creating three-parameter
comparision functions with added a third parameter to select collation.

Additionally, it's worth to note that using strcoll is highly expensive.
I've got some reports from people who used postgreSQL with national
characters and noticed performance drop-downs up to 20 times (Linux). So
it's needed to create a cheap comparision functions that will preserve
it's translation tables during sessions.

Anyhow, if anybody wants to try inefficient strcoll, long time ago I've
sent a patch to sort chars/varchars using it. But I don't recommend it.

Mike

--
WWW: http://www.lodz.pdi.net/~mimo tel: Int. Acc. Code + 48 42 148340
add: Michal Mosiewicz * Bugaj 66 m.54 * 95-200 Pabianice * POLAND

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 1998-05-18 17:35:52 Re: [HACKERS] Query cancel and OOB data
Previous Message Brett McCormick 1998-05-18 16:31:08 Re: [HACKERS] Re: [PATCHES] char/varchar locale support