Re: Getting relation/attribute names from inside UDT input/output function

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Humberto Luiz Razente" <hlr(at)icmc(dot)usp(dot)br>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Getting relation/attribute names from inside UDT input/output function
Date: 2006-05-10 15:50:24
Message-ID: 1447.1147276224@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

"Humberto Luiz Razente" <hlr(at)icmc(dot)usp(dot)br> writes:
> I wrote the UDT input/output functions for my complex type
> and everything is working well.
> But now, in the input function, I need to get the relation/attribute
> names where a new object is being inserted.

Since, in general, there *is* no such place where the value would be
inserted, this is impossible. Consider

SELECT 'foo'::yourtype

Better rethink what you're trying to accomplish.

regards, tom lane

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Scott Marlowe 2006-05-10 15:52:56 Re: how do i unsubscribe
Previous Message Allie.Hopkins@gmail.com 2006-05-10 15:49:35 call function with different select statement