Re: Extracting single coordinate from a box

From: Jean-Luc Lachance <jllachan(at)nsd(dot)ca>
To: Donald Fraser <demolish(at)cwgsy(dot)net>
Cc: "[ADMIN]" <pgsql-admin(at)postgresql(dot)org>
Subject: Re: Extracting single coordinate from a box
Date: 2003-08-28 17:57:29
Message-ID: 3F4E4289.9310085E@nsd.ca
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

I think you are forgetting that a box is an array of one dimension with
two points.
So, the first point is B[0] and the second is B[1].

Donald Fraser wrote:
>
> Thanks for the quick response.
>
> ----- Original Message -----
> > "Donald Fraser" <demolish(at)cwgsy(dot)net> writes:
> > > But when I try something like b[0][0] the passer ignores the second array
> > > subscript parameter and returns only a "point".
>
> > You need the extra parentheses because the two subscript operations need
> > to work on fundamentally different datatypes --- if you write f1[1][0]
> > you are asking to subscript a 2-D array which this isn't.
> >
> > [ experiments further ... ] Drat, seems that syntax works in 7.4 but
> > not 7.3. Dunno if that will help you.
>
> I'm using 7.3.4 at the moment and I tried the scenario of using parentheses,
> which didn't work.
> I wrote a function in the end to extract it, but it would have been more
> elegant without it :-(
>
> Thanks again
> Donald
>
> ---------------------------(end of broadcast)---------------------------
> TIP 2: you can get off all lists at once with the unregister command
> (send "unregister YourEmailAddressHere" to majordomo(at)postgresql(dot)org)

In response to

Browse pgsql-admin by date

  From Date Subject
Next Message Mauri Sahlberg 2003-08-28 18:57:36 Re: plpgsql: Bush becomes a null,
Previous Message Josh Goldberg 2003-08-28 17:55:58 Re: plpgsql: Bush becomes a null, can not execute null query