Hi, paallen,
paallen@attglobal.net wrote:
> I am moving some of my old MS Access functions to
> plpgsql.
>
> My function was made to return coordinates, X,Y,Z
> for a point along a curved line.
Depending on the actual kind of data, you might want to look into the
PostgeSQL geometry types, or PostGIS for your geometric data.
> What should I do to speed this up. What is the
> best way to update 3 columns from one function
> call. In MSACCESS I once rig the function to
> cycle through the records with a curser but that
> was slow and would crap out due to the shear number.
It might work to mark the function as "stable", and have it return a
compound type in a subselect with an "AS foo" aliasname. Then you should
be able to address the compound's elements via foo.x, foo.y and foo.z.
Or use PostGIS, it's capable of processing 3D points.
HTH,
Markus
--
Markus Schaber | Logical Tracking&Tracing International AG
Dipl. Inf. | Software Development GIS
Fight against software patents in Europe! www.ffii.org
www.nosoftwarepatents.org