Revision: 6555
http://sourceforge.net/p/jump-pilot/code/6555
Author: edso
Date: 2020-09-28 13:06:25 +0000 (Mon, 28 Sep 2020)
Log Message:
-----------
little workaround to fetch geom coltype by using sql select as
Modified Paths:
--------------
core/trunk/src/com/vividsolutions/jump/datastore/spatialite/SpatialiteValueConverterFactory.java
Modified:
core/trunk/src/com/vividsolutions/jump/datastore/spatialite/SpatialiteValueConverterFactory.java
===================================================================
---
core/trunk/src/com/vividsolutions/jump/datastore/spatialite/SpatialiteValueConverterFactory.java
2020-09-28 04:49:08 UTC (rev 6554)
+++
core/trunk/src/com/vividsolutions/jump/datastore/spatialite/SpatialiteValueConverterFactory.java
2020-09-28 13:06:25 UTC (rev 6555)
@@ -44,7 +44,12 @@
String tableName = rsm.getTableName(columnIndex).toLowerCase();
String columnName = rsm.getColumnName(columnIndex).toLowerCase();
- GeometricColumnType gcType = metadata.getGeoColTypesdMap().get(tableName +
"." + columnName);
+ // SELECT geom AS geometry ... or
+ // SELECT ST_Centroid(geom) from ...
+ // result in empty tableNames
+ // to "reuse" the GeometricColumnType of a valid table's column by
selecting as you can however eg.
+ // SELECT ST_Centroid(geom) as 'table.geom' from table
+ GeometricColumnType gcType =
metadata.getGeoColTypesdMap().get((tableName==null||tableName.isEmpty()?"":tableName+".")
+ columnName);
if (gcType == null) {
ValueConverter stdConverter = ValueConverterFactory.getConverter(rsm,
columnIndex);
if (stdConverter != null) {
_______________________________________________
Jump-pilot-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel