Re: Variable-length Types
От | KuroiNeko |
---|---|
Тема | Re: Variable-length Types |
Дата | |
Msg-id | 39EA1F05.nailA91QW5LV@ed.ed обсуждение исходный текст |
Ответ на | Variable-length Types (Itai Zukerman <zukerman@math-hat.com>) |
Список | pgsql-sql |
Josh, > Thanks. You're probably right ... reformatting the phone numbers is > going to be a lot less work than a custom type. I remember from the old days of Delphi/InterBase, and even older days of Paradox, there were so called input masks, US phone code mask would be like (999)_000-00-00 or something like that (no default values) Borland has released their Turbo stuff for public domain, so it might be worth looking at.Implementing a generic picture functions (as in PL/I) would probably be easier and cover more cases. However, watch your back with user-supplied format strings, there's a plenty of ruined lives at BugTraq :)I'm just not sure what to do if 8 or 9 digits are supplied?Maybe, reject, assuming that such things should be caught by UI, and if we get such a weird thing, there's something really really wrong? -- Well I tried to be meek And I have tried to be mildBut I spat like a woman And I sulked like a childI have lived behind thewalls That have made me aloneStriven for peace Which I never have known Dire Straits, Brothers In Arms, The Man's Too Strong (Knopfler)
В списке pgsql-sql по дате отправления: