Re: primary key on lower(varchar) - Mailing list pgsql-novice

From
Subject Re: primary key on lower(varchar)
Date
Msg-id 20060108071150.27599.qmail@web33302.mail.mud.yahoo.com
Whole thread Raw
In response to Re: primary key on lower(varchar)  (<me@alternize.com>)
List pgsql-novice
--- me@alternize.com wrote:

>  > I don't really see the use-case for what you want
> anyway.  Why don't
> > you just require the field to be all lower case,
> eg with a CHECK
> > constraint?
>
> simple case: lets say the table "translated_names"
> contains an foreign key,
> the translated word and the language the word is in.
> obviously,
> "Brotaufstrich" and "brotaufstrich" must relate to
> the same record. if i'm
> just saving the records in lowercase (or uppercase)
> i'm loosing the proper
> letter case...
>
> the workaround of adding 2 word fields (word_lower,
> word_normal)  and
> setting word_lower to primary key unfortunately
> wastes a lot of diskspace
> espially when the table grows large...
>
> - thomas

isn't it easier to set up a serial for your primary key?



__________________________________________
Yahoo! DSL – Something to write home about.
Just $16.99/mo. or less.
dsl.yahoo.com


pgsql-novice by date:

Previous
From:
Date:
Subject: Re: primary key on lower(varchar)
Next
From: Charley Tiggs
Date:
Subject: Re: primary key on lower(varchar)