| From: | Soma Interesting <dfunct(at)telus(dot)net> |
|---|---|
| To: | will trillich <will(at)serensoft(dot)com>, pgsql-general(at)postgresql(dot)org |
| Subject: | Re: dynamic field names in a function. |
| Date: | 2001-03-31 00:39:21 |
| Message-ID: | 5.0.2.1.0.20010330163715.022c3eb0@pop.telus.net |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-general |
At 05:47 PM 3/30/2001 -0600, you wrote:
>HOWEVER -- we do have arrays, don't forget... sometimes they can
>be bent to do more than intended (but usually not!)
>
> create table mailing(
> person_id serial,
> sent int4[],
> prefs varchar[],
> current int2
> );
> -- insert, update, munge and frob, then
> select person_id,sent[current] from something;
>
>--
>
>oh, and if your PostgreSQL instance is new enough, you might have
>PERL built in, which could make all of this moot. (now we just
>need someone to DOCUMENT the sucker so we know how perl can talk
>back to postgres for cross-lookups and such...)
Will, you are a powerful postgres wizard and never let anyone tell you
otherwise.
I may be able to use array's if postgres will allow using variables to
reference points in the array.
As for your comment about perl being built in, how can I find this out? I
guess just try CREATE LANGUAGE specifying perl?
| From | Date | Subject | |
|---|---|---|---|
| Next Message | will trillich | 2001-03-31 00:40:13 | Re: function to operate on same fields, different records? |
| Previous Message | will trillich | 2001-03-30 23:47:19 | Re: dynamic field names in a function. |