Search Postgresql Archives

Re: US Telephone Number Type

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Jul 10, 2006 at 10:33:52AM -0700, Karen Hill wrote:
> Hello,
> 
> How would one go about creating a US telephone type in the format of
> "(555)-555-5555" ?  I am at a loss on how it could be accomplished in
> the most correct way possible while not going into the various
> different country styles e.g. +01 (555) 555-5555.

How do you mean "styles". The above number is, when printed in standard
international format +15555555555. The number needed to dial
international is not relevent. What makes it tricky is that people
don't agree on how numbers should be formatted.

> Is the difficulty of creating a telephone type the reason it is not in
> postgresql already?

It wouldn't be hard, it's just not clear what the advantage is over
just having a string and some functions to display the number.

> Should the telephone type be able to do something such as:
> 
> SELECT * from tableFOO where telephone.areacode = 555;

Maybe, but is that useful? Maybe America is different, but my
experience in NL and AU is that you rarely care about the areacode
anyway, so why would you want to pull it out?

Have a nice day,
-- 
Martijn van Oosterhout   <kleptog@xxxxxxxxx>   http://svana.org/kleptog/
> From each according to his ability. To each according to his ability to litigate.

Attachment: signature.asc
Description: Digital signature


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux