Hi Broun.

If you want the start point of a linestring then you must use:

StartPoint(the_geom)

This function returns a POINT with the coordinates of the start point from
the_geom (for the end point you should use EndPoint(the_geom))

If you want to get the X and Y coordinates you should use the X() and Y()
functions with that points like:

X(StartPoint(the_geom)) and Y(StartPoint(the_geom))

Rodrigo.

On 7/5/07, Broun Uganda <[EMAIL PROTECTED]> wrote:

Dear all,
Am trying to use the postgis reference to extract coordinates (x & y) for
the starting and ending of a line from the_geom to enable me draw points
at the starting and ending of that line. Please advise me which function i
should use in my trigger function.
I want to do something like this:
UPDATE points SET the_geom = MakePoint(New.lines.the_geom(s),-1); where
(s) refers to start of line geometry & (e) refers to end  of line geometry
UPDATE points SET the_geom = MakePoint(New.lines.the_geom(e),-1);


Thanks

Broun


------------------------------
Make every IM count. Download Windows Live Messenger and join the i'm
Initiative now. It's free.   Make it 
count!<http://im.live.com/messenger/im/home/?source=TAGWL_June07>

_______________________________________________
postgis-users mailing list
[email protected]
http://postgis.refractions.net/mailman/listinfo/postgis-users


_______________________________________________
postgis-users mailing list
[email protected]
http://postgis.refractions.net/mailman/listinfo/postgis-users

Reply via email to