Hi Jan, Here is a wrapper function to directly pass the double precision values to minimize any precision error due to text conversion:
CREATE OR REPLACE FUNCTION ST_MakeBox3D(minx double precision, miny double precision, minz double precision, maxx double precision, maxy double precision, maxz double precision) RETURNS box3d AS 'SELECT ST_MakeBox3D(ST_MakePoint($1, $2, $3), ST_MakePoint($4, $5, $6))' LANGUAGE 'sql' IMMUTABLE STRICT COST 10; -- E.g. a cube: SELECT ST_MakeBox3D(3421250, 5968415, -22.96, 3427355, 5971725, -15.15); or from Python or other environment with parameter support, this will look more like: SELECT ST_MakeBox3D($1, $2, $3, $4, $5, $6); using all six inputs of double precision. -Mike On 19 October 2010 05:48, Jan Saalbach <f...@dubmosphere.de> wrote: > will I lose data/precision if I save the box3ds as text first and once they > are all in the column cast them to box3d? That operation would be purely > inside the database and should work. should it? > > Regards > Jan > > _______________________________________________ > postgis-users mailing list > postgis-users@postgis.refractions.net > http://postgis.refractions.net/mailman/listinfo/postgis-users >
_______________________________________________ postgis-users mailing list postgis-users@postgis.refractions.net http://postgis.refractions.net/mailman/listinfo/postgis-users