|
1 |
| -<!-- $Header: /cvsroot/pgsql/doc/src/sgml/func.sgml,v 1.59 2001/05/24 09:29:29 petere Exp $ --> |
| 1 | +<!-- $Header: /cvsroot/pgsql/doc/src/sgml/func.sgml,v 1.60 2001/06/13 22:51:02 momjian Exp $ --> |
2 | 2 |
|
3 | 3 | <chapter id="functions">
|
4 | 4 | <title>Functions and Operators</title>
|
@@ -3306,6 +3306,13 @@ Not defined by this name. Implements the intersection operator '#'
|
3306 | 3306 | <entry>masklen('192.168.1.5/24')</entry>
|
3307 | 3307 | <entry>24</entry>
|
3308 | 3308 | </row>
|
| 3309 | + <row> |
| 3310 | +<entry>set_masklen(inet,integer)</entry> |
| 3311 | +<entry>inet</entry> |
| 3312 | +<entry>set netmask length for inet value</entry> |
| 3313 | +<entry>set_masklen('192.168.1.5/24',16)</entry> |
| 3314 | +<entry>192.168.1.5/16</entry> |
| 3315 | + </row> |
3309 | 3316 | <row>
|
3310 | 3317 | <entry>netmask(inet)</entry>
|
3311 | 3318 | <entry>inet</entry>
|
@@ -3342,7 +3349,9 @@ Not defined by this name. Implements the intersection operator '#'
|
3342 | 3349 | All of the functions for <type>inet</type> can be applied to
|
3343 | 3350 | <type>cidr</type> values as well. The <function>host</>(),
|
3344 | 3351 | <function>text</>(), and <function>abbrev</>() functions are primarily
|
3345 |
| - intended to offer alternative display formats. |
| 3352 | + intended to offer alternative display formats. You can cast a text |
| 3353 | + field to inet using normal casting syntax: inet(fieldname) or |
| 3354 | + fieldname::inet. |
3346 | 3355 | </para>
|
3347 | 3356 |
|
3348 | 3357 | <para>
|
|