<!DOCTYPE html PUBLIC '-//W3C//DTD HTML 4.01 Transitional//EN'>
<html>
<head>
 <meta http-equiv='Content-Type' content='text/html;charset=us-ascii'>
 <style>BODY{font:10pt Tahoma, Verdana, sans-serif;}</style>
</head>
<body>
I am running a standalone console application which uses Hibernate3 and connects to a postgis database. I have been successful in reading the geomoetry from the database when I define my geometry column in Hibernate as<br><br>    <property<br>        name="theGeom"<br>        type="java.lang.String"<br>        formula="AsText(force_2d(the_geom))"<br>        length="-1"<br>    /><br><br>This returns the geometry as a WKT string that can easily be read by my application. However, using this definition I am not able to set the value of the geometry. I have read the mailing list about postgis and hibernate and am just more confused. Is there a simple way to define the geometry column to Hibernate to make getting and setting the geometry simple? I would even be pleased with referencing the geometry data as a byte[] or a String from within Java.<br><br>Any help and/or clarification would be appreciated.<br><br>David Robison<br></body></html>