This week's book giveaways are in the Cloud and AI/ML forums. We're giving away four copies each of Cloud Native Patterns and Natural Language Processing and have the authors on-line! See this thread and this one for details.
I'm having a issue trying to get working a JPA nativeQuery.
I'm having a org.hibernate.MappingException: No Dialect mapping for JDBC type: 2002 when a try to do a nativeQuery and get a geometry field type.
I use oracle and org.hibernatespatial.oracle.OracleSpatial10gDialect.
The geom fields is mapped as:
Anybody knows a solution? or how to force the type of the geometry to get wroking this...
Looking at the JDBC documentation, 2002 is a struct data type. The error message tells you the dialect does not support this. You could try upgrading your dialect, or swap the data type to something it can support.
I using the dialect that match to my database. I don't know is there's a best dialect, I will check it.
Now I'm using another query, and using a @SqlResultSetMapping and returning a two whole objects. (dades, features)....No only some fields. Usign this now is working...Not is the best solution but it' works.
I don't undestand how works the dialect, but it's strange that cannot use a nativeQuery with a user defined type (org.hibernatespatial.GeometryUserType) by the dialect.