| From: | "George Weaver" <georgew1(at)mts(dot)net> |
|---|---|
| To: | "Brian Knox" <laotse(at)aol(dot)net>, <pgsql-sql(at)postgresql(dot)org> |
| Subject: | Re: "record" datatype - plpgsql |
| Date: | 2003-05-29 19:01:54 |
| Message-ID: | 005001c32624$0f0f3980$0100007f@cleartag |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-sql |
Hi Brian;
Assuming "NEW" has been declared as foo%rowtype, you can access the
columns thus
NEW.xxx where xxx is the column name
HTH.
George
----- Original Message -----
From: "Brian Knox" <laotse(at)aol(dot)net>
To: <pgsql-sql(at)postgresql(dot)org>
Sent: Thursday, May 29, 2003 11:11 AM
Subject: [SQL] "record" datatype - plpgsql
> Given a variable of the "record" data type in pl/pgsql, is it possible to
> get the names of the columns ( attributes ) of that record?
>
> eg, given record "NEW" for table "foo", is there a way to get information
> concerning the columns that make up that record?
>
> Brian Knox
>
> ---------------------------(end of broadcast)---------------------------
> TIP 5: Have you checked our extensive FAQ?
>
> http://www.postgresql.org/docs/faqs/FAQ.html
>
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Chadwick Rolfs | 2003-05-29 19:53:14 | Re: [SQL] faster output from php and postgres (one resolution) |
| Previous Message | Tom Lane | 2003-05-29 18:46:34 | Re: Index scan never executed? |