
6 Aug
2011
6 Aug
'11
2:23 p.m.
2011/8/5 Sjoerd Mullender
On 2011-08-02 08:21, Eugene Prokopiev wrote:
How to check whether ip is contained within network? I tried:
sql>select * from transfer_ip where dst << '10.7.1.0/24' limit 10; types inet(0,0) and tinyint(8,0) are not equal for column 'dst' sql>select * from transfer_ip where dst << inet '10.7.1.0/24' limit 10; types inet(0,0) and tinyint(8,0) are not equal for column 'dst'
<< is the left shift operator, so both sides are expected to be a integers.
As I see, this operator is defined for INET type in /usr/lib64/monetdb5/inet.mal Is it impossible to do what I wish?