[postgis-users] postgis.jar error

Markus Schaber schabi at logix-tt.com
Fri Mar 24 08:17:17 PST 2006

Hi, Gilbert,

Gilbert, Antoine wrote:

> When accessing geometry objects in Java using postgis.jar, on a specific
> postgis/postgresql database (windows), we get this error:
> **java.lang.IllegalArgumentException: Unknown Endian type:48***
> * at
> org.postgis.binary.BinaryParser.valueGetterForEndian(BinaryParser.java:68)
>  at org.postgis.binary.BinaryParser.parse(BinaryParser.java:91)
>  at
> com.korem.dp.postgis.geom.AbstractGeometry.getPGgeometry(AbstractGeometry.java:57)
>  at
> com.korem.dp.postgis.geom.MultiPolygonWrapper.getPointListCount(MultiPolygonWrapper.java:62)

Hmm, can you provide us with the specific geometry that gives this error?

And what does com.korem.dp.postgis.geom.AbstractGeometry.getPGgeometry
look like? It seems that you call the BinaryParser yourself, instead of
using the PostGIS driver extension.

It looks like it gets the byte 48 = character '0' as first byte in the
byte[] parsing function. This can only be the case if you feed a hexWKB
representation as byte array into the non-hex WKB parser.

Markus Schaber | Logical Tracking&Tracing International AG
Dipl. Inf.     | Software Development GIS

Fight against software patents in EU! www.ffii.org www.nosoftwarepatents.org

More information about the postgis-users mailing list