pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Larry Rosenman <ler@lerctr.org>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Stephan Szabo <sszabo@megazone23.bigpanda.com>
Cc: josh@agliodbs.com
Cc: pgsql-sql@postgresql.org
Subject: Re: Ok, how do I debug THIS?
Date: Tue, 13 May 2003 15:31:13 -0500
Message-ID: <312680000.1052857873@lerlaptop.iadfw.net> (raw)
In-Reply-To: <28980.1052857299@sss.pgh.pa.us>
References: <20030513130508.Q30384-100000@megazone23.bigpanda.com>
	<295850000.1052856801@lerlaptop.iadfw.net>
	<28980.1052857299@sss.pgh.pa.us>



--On Tuesday, May 13, 2003 16:21:39 -0400 Tom Lane <tgl@sss.pgh.pa.us> 
wrote:

> Larry Rosenman <ler@lerctr.org> writes:
>>> Ugh.  cidr doesn't appear to cast to text.  You may be able to go
>>> through inet, but I'm not really sure because I haven't really used
>>> those types.
>
>> looks like I can, **BUT** is this the RIGHT thing?  I suspect it SHOULD
>> cast to text.  IMNSHO.
>
> Probably.  We have an inet->text cast, and the same function would work
> for cidr->text.  I think it's just an oversight that there's no such
> entry in pg_cast.  You could add one by hand ...
How would I do that?

Also, this is what I wound up with for that line, which seems ugly, because
it couldn't find a quote_literal(inet) without the ::text on it:

  quote_literal(NEW.netblock::inet::text) ;


Is that right?


>
> 			regards, tom lane



-- 
Larry Rosenman                     http://www.lerctr.org/~ler
Phone: +1 972-414-9812                 E-Mail: ler@lerctr.org
US Mail: 1905 Steamboat Springs Drive, Garland, TX 75044-6749




view thread (14+ messages)  latest in thread

Message-ID: <312680000.1052857873@lerlaptop.iadfw.net>
Permalink:  ../312680000.1052857873@lerlaptop.iadfw.net/
Also on:    postgresql.org/message-id/312680000.1052857873@lerlaptop.iadfw.net

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: ler@lerctr.org, tgl@sss.pgh.pa.us, sszabo@megazone23.bigpanda.com, josh@agliodbs.com
  Subject: Re: Ok, how do I debug THIS?
  In-Reply-To: <312680000.1052857873@lerlaptop.iadfw.net>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox