varchar, text and cidr
От | Richard Welty |
---|---|
Тема | varchar, text and cidr |
Дата | |
Msg-id | E19jm8N-0002hj-97@skipper.averillpark.net обсуждение исходный текст |
Ответы |
Re: varchar, text and cidr
|
Список | pgsql-general |
so i'm trying to puzzle out how to do something in a client's database. he's using postgresql 7.3.2 on a rh 8.0 system. he has a column with type varchar(18) containing cidr blocks (yes, i know he should use the cidr type, but he didn't.) in my testing, i've determined that i can cast text to cidr, but i can't cast varchar( limit) to cidr. i've worked out that i can do this: select * from vctest where '192.0.2.5'::cidr << baz::text::cidr; baz -------------- 192.0.2.0/24 but is there any particular reason why i have to jump through the typecasting hoop twice here? thanks, richard -- Richard Welty rwelty@averillpark.net Averill Park Networking 518-573-7592 Java, PHP, PostgreSQL, Unix, Linux, IP Network Engineering, Security
В списке pgsql-general по дате отправления: