the real code has correct syntax, that's a copy/paste error on my part.<br><br><div class="gmail_quote">On Thu, Feb 2, 2012 at 4:13 PM, Charles Galpin <span dir="ltr"><<a href="mailto:cgalpin@lhsw.com">cgalpin@lhsw.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">I'm not sure about the support for geography but I see you need a comma between id and locGeog<br>
<br>
-- charles<br>
<div><div class="h5"><br>
On Feb 2, 2012, at 5:58 PM, Jay Moss <<a href="mailto:jaymoss3@gmail.com">jaymoss3@gmail.com</a>> wrote:<br>
<br>
> Is there any support for the Geography data type in the PostGIS JDBC driver?<br>
><br>
> I received a classCastException if I try to cast a Geography colum to a PGgeometry:<br>
><br>
> my table:<br>
><br>
> CREATE TABLE k16View (<br>
> id character varying(255) NOT NULL,<br>
> locGeog geography<br>
> CONSTRAINT k16View_pkey PRIMARY KEY (id));<br>
><br>
> my code:<br>
> ...<br>
> ResultSet r = s.executeQuery("select id locGeog from k16View");<br>
> String trackNumber = r.getString(1);<br>
> PGgeometry geog = (PGgeometry) r.getObject(2); // throws ClassCastException<br>
><br>
><br>
><br>
><br>
</div></div>> _______________________________________________<br>
> postgis-users mailing list<br>
> <a href="mailto:postgis-users@postgis.refractions.net">postgis-users@postgis.refractions.net</a><br>
> <a href="http://postgis.refractions.net/mailman/listinfo/postgis-users" target="_blank">http://postgis.refractions.net/mailman/listinfo/postgis-users</a><br>
_______________________________________________<br>
postgis-users mailing list<br>
<a href="mailto:postgis-users@postgis.refractions.net">postgis-users@postgis.refractions.net</a><br>
<a href="http://postgis.refractions.net/mailman/listinfo/postgis-users" target="_blank">http://postgis.refractions.net/mailman/listinfo/postgis-users</a><br>
</blockquote></div><br>