gvSIG bugs #2188
Error en método dalValueToJDBC de la clase JDBCHelper
Status: | Closed | % Done: | 0% | |
---|---|---|---|---|
Priority: | Normal | Spent time: | - | |
Assignee: | - | |||
Category: | - | |||
Target version: | 2.1.0-2217-devel | |||
Severity: | Add-on version: | |||
gvSIG version: | 2.1.0 | Add-on build: | ||
gvSIG build: | Add-on resolve version: | |||
Operative System: | Add-on resolve build: | |||
Keywords: | Proyecto: | |||
Has patch: | Yes | Hito: | ||
Add-on name: | Unknown |
Description
En la clase JDBCStoreProviderWriter, en el método performInsert salta la excepción:
org.postgresql.util.PSQLException: Can't infer the SQL type to use for an instance of java.util.Date. Use setObject() with an explicit Types value to specify the type to use.
al intentar insertar una feature de tipo Date cuando en la base de datos el campo es de tipo Time.
Se soluciona poniendo las siguientes líneas en el método dalValueToJDBC de la clase JDBCHelper:
if (attributeDescriptor.getType() == DataTypes.TIME) { return new Time(((Date)object).getTime()); }
Associated revisions
Apply patch related to ticket "Error en método dalValueToJDBC de la clase JDBCHelper"
refs #2188
History
#1 Updated by Joaquín del Cerro Murciano over 10 years ago
- Status changed from New to Fixed
- Has patch changed from No to Yes
#2 Updated by Joaquín del Cerro Murciano over 10 years ago
- Target version set to 2.1.0-2217-devel
#3 Updated by Álvaro Anguix over 10 years ago
- Status changed from Fixed to Closed