Re: [HACKERS] ordinal decimal number

Поиск
Список
Период
Сортировка
От Hannu Krosing
Тема Re: [HACKERS] ordinal decimal number
Дата
Msg-id 38736AB7.54CCA399@tm.ee
обсуждение исходный текст
Ответ на Re: [HACKERS] ordinal decimal number  (Karel Zak - Zakkr <zakkr@zf.jcu.cz>)
Ответы Re: [HACKERS] ordinal decimal number  (Karel Zak - Zakkr <zakkr@zf.jcu.cz>)
Список pgsql-hackers
Karel Zak - Zakkr wrote:
> 
> On Wed, 5 Jan 2000, Oliver Elphick wrote:
> 
> > "J. Roeleveld" wrote:
> >   >> Hi,
> >   >>
> >   >> I add to the to_char() routine "ordinal-number" feature, but my
> >   >> English is insufficient for this :-(  (sorry)
> >   >
> >   >There are enough people that speak English, what we don't have enough
> >   >of on this world are people that know what they can and can't do :)
> >   >
> >   >> I good know how is it for non-decimal numbers, but if number has
> >   >> decimal part?
> >   >>
> >   >> Example: 2.6  --> 2.6th
> >   >>             or  2.6  --> 2.6nd
> >   >
> >   >It's:  2.6 --> 2.6th
> >
> > It isn't really possible to have an ordinal with decimal places in
> > English; it sounds very awkward.
> >
> > Ordinals designate placing in a list; a computer example would be an
> > array index.  How can such a number have decimal places?

I guess they are awkward in most languages, except for designating powers 
where they _could_ be used by extension of their use for integer powers?
e raised to the pi-th power ?

btw, should 2.2 be 2.2nd or 2.2th (two point tooth :)

what about rationals 7 2/3 th ?

what about legal float numbers like infinity (is it infinitieth)
and NaN - NaN-th or NaNd :)

for me 2.2nd represents not decimal but hierrachy, so it should be possible to
have
2.2.2.2nd

>  I implement it to to_char (ordinal with decimal places), but is user choise
> if use or not use it...

Is your code locale-aware ?

I guess that this is something that could probbaly be found in localisation
tables,
except perhaps for floats.

------------------
Hannu


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Jan Wieck
Дата:
Сообщение: Re: [HACKERS] Index corruption
Следующее
От: Lamar Owen
Дата:
Сообщение: InterBase interview on Linux Journal