Re: Bug #670: netmask displayed for a /32 - Mailing list pgsql-bugs

From Tom Lane
Subject Re: Bug #670: netmask displayed for a /32
Date
Msg-id 20403.1021990340@sss.pgh.pa.us
Whole thread Raw
In response to Bug #670: netmask displayed for a /32  (pgsql-bugs@postgresql.org)
Responses Re: Bug #670: netmask displayed for a /32
List pgsql-bugs
pgsql-bugs@postgresql.org writes:
> But the /y portion is shown in this case:
> pmoanalysis=> select ipaddress||'a' from dhcpservers;
>   ?column?
> -------------
>  1.2.3.4/32a
> (1 row)

This implicitly coerces the inet value to text datatype, and the
text(inet) function always displays netmask.  Perhaps you'd prefer
to use host() or abbrev() to do the conversion to text.

            regards, tom lane

pgsql-bugs by date:

Previous
From: "Josh Berkus"
Date:
Subject: Re: [SQL] Bug with Daylight Savings Time & Interval
Next
From: Tom Lane
Date:
Subject: Re: pg_dump && aggregate bug