[postgis-users] Math Operators

Bob Pawley rjpawley at shaw.ca
Fri Jul 24 11:43:49 PDT 2009


I have an expression such as :-

select (st_translate(graphics.utilities_dgm.the_geom, 
  st_x(p_id.p_id.ithe_geom) +
  (ST_distance(p_id.p_id.the_geom, p_id.p_id.ithe_geom)

I need the option of either (+) or (-) after st_x(p_id.p_id.ithe_geom), depending on circumstance. 

At the moment I am writting two expressions. Is there a way of creating one expression that covers both circumstances?

Bob

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20090724/a1f64bb0/attachment.html>


More information about the postgis-users mailing list