Re: Recording an ISO-639-1 language code
- From: Lew <lew@xxxxxxxxxxxxxxxx>
- Date: Thu, 28 Jun 2007 23:52:57 -0400
Roedy Green wrote:
On Sun, 24 Jun 2007 20:32:27 GMT, Haggis McMutton
<haggis@xxxxxxxxxxxxx> wrote, quoted or indirectly quoted someone who
said :
There would obviously be need for a function that converts between the
two, is it better to do this or just record it as a string?
You can store it in one byte as an int, or 32 bits as a fixed length
character pair, even longer for a string since you need a length.
It really depends on how many of these you have. If you have a
database of millions of records it might be worth sweating over. Most
likely there are tens of thousands of things more deserving of such
detailed attention.
Consider that you can't do much interesting with ad-hoc SQL queries in
int form.
<http://java.sun.com/javase/6/docs/api/java/util/Locale.html#getISOLanguages()>
<http://java.sun.com/javase/6/docs/api/java/util/Locale.html#getLanguage()>
<http://java.sun.com/javase/6/docs/api/java/util/Locale.html#ENGLISH> et al.
--
Lew
.
- References:
- Recording an ISO-639-1 language code
- From: Haggis McMutton
- Re: Recording an ISO-639-1 language code
- From: Roedy Green
- Recording an ISO-639-1 language code
- Prev by Date: Re: I KNOW, I KNOW ...
- Next by Date: Re: Initiating a class
- Previous by thread: Re: Recording an ISO-639-1 language code
- Next by thread: why does this only except font the second time
- Index(es):