Re: plpgsql mixing variable in SELECT INTO ?

From: "Ben-Nes Michael" <miki(at)canaan(dot)co(dot)il>
To: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: "postgresql" <pgsql-general(at)postgresql(dot)org>
Subject: Re: plpgsql mixing variable in SELECT INTO ?
Date: 2003-03-05 10:09:03
Message-ID: 009201c2e2ff$3feeaee0$aa0f5ac2@canaan.co.il
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

well i coded select into lft_rgt rgt from forum_tree where bla bla;

This was code i implented at 7.2.x and rgt suposed to tell me how to push a
nested set model of tree ( Joe Celko Model )

I had to fix the "rgt" to "*" after i updated to 7.3.2

--------------------------
Canaan Surfing Ltd.
Internet Service Providers
Ben-Nes Michael - Manager
Tel: 972-4-6991122
Fax: 972-4-6990098
http://sites.canaan.co.il
--------------------------
----- Original Message -----
From: "Tom Lane" <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Ben-Nes Michael" <miki(at)canaan(dot)co(dot)il>
Cc: "postgresql" <pgsql-general(at)postgresql(dot)org>
Sent: Tuesday, March 04, 2003 7:45 PM
Subject: Re: [GENERAL] plpgsql mixing variable in SELECT INTO ?

> "Ben-Nes Michael" <miki(at)canaan(dot)co(dot)il> writes:
> > You mean I cant use the full power of the SELECT as mentioned in the
manual
> > and when using SELECT INTO I must use * and I can refine my query to
some of
> > the fields ?
>
> Certainly you can. But when you assign into a row variable, you have to
> provide all the row variable's columns, in order. How else would you
> expect it to work?
>
> > Also its quite strange that my code worked in 7.3.1-
>
> I don't believe it.
>
> regards, tom lane
>
> ---------------------------(end of broadcast)---------------------------
> TIP 3: if posting/reading through Usenet, please send an appropriate
> subscribe-nomail command to majordomo(at)postgresql(dot)org so that your
> message can get through to the mailing list cleanly
>

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Abhishek Verma 2003-03-05 10:18:06 problem : initdb failed
Previous Message Richard Huxton 2003-03-05 09:58:31 Re: What about SELECT INTO in EXECUTE