Are WKB and WKT really used in Spatialite? FDO system is probably using WKB but 
I have never met WKT geometries. More useful might be to support GeoPackage 
geometries and I suppose that DB Query Plugin has good native parser for them. 
I suppose you are making a pure java solution because with SpatiaLite binaries 
I believe it would be possible to simply use AsWKB.

If you play with SQLite/SpatiaLite, test also how your code deals with 
date/datetime/timestamp attributes (DB Query chokes).

-Jukka Rahkonen-

Nicolas Ribot wrote:

Hi Michaël,

Thanks for the insight.

I'm currently refactoring a bit the SpatialDatabases code.
The error you pointed out showed me some problems with current code, and as you 
noted, I have to instantiate a correct, concrete class for each detected 
DSConnection.

I'm finalising my todo list, but right now, FilterQuery and AdhocQuery can be 
ran on Postgis, Oracle, MySQL and Spatialite databases the same way.

I'm currently finishing the support for Spatialite, that can be tricky: 
geometry column can contain WKT, WKB or native Spatialite binary format. Still 
have to correct the ValueConvert to correctly detect and convert each type.

MySQL support is added with support for both WKB storage, internal binary 
storage (code from DBQuery).
Layer extent is now correctly retrieved but has to be tested on big datasets 
(it merely uses a textual aggregation of all geometries to build the resulting 
envelope).

I think I will be able to commit fixes soon.

I'm stuck, though, on the problem Jukka mentioned: if you add a wrong where 
clause to the layer to load, error is detected in the 
com.vividsolutions.jump.workbench.ui.renderer.ImageCachingRenderer( line 90) 
where the error message is displayed in Window toolbar.
I can display an ErrorDialog with SQL error, but do not know how to cleanly 
remove the layer from the panel.

Nicolas


On 12 December 2015 at 15:29, Michaël Michaud 
<m.michael.mich...@orange.fr<mailto:m.michael.mich...@orange.fr>> wrote:
Hi Nicolas,

I had a look but did not find an easy way to fix the problem.

In SpatialDatabasesDSConnection you added a comment that it is no more 
necessary to subclass to PostGIS...

On the other hand,
- SpatialDatabasesDSConnection instantiates
- SpatialDatabasesResultSetConverter which in turn instantiates
- SpatialDatabasesFeatureInputStream which instantiates
- SpatialDatabasesResultSetConverter  which instiates a new
- SpatialDatabasesValueConverterFactory

The getConverter method of the later just return null which seems the root cause
of my NPE.

Seems like the concrete class should still be a subclass of 
SpatialDatabasesDSConnection.
What do you think ?

Another (maybe related) question : In the component to connect a new database, 
there
is a combobox with a single value "PostGIS".  Should we add other drivers in 
order to
instantiate proper connection for each driver. There is commented code from you 
in
JumpConfiguration class showing that you already have implemented such a 
solution
in the past)

Michaël

Le 08/12/2015 10:30, Nicolas Ribot a écrit :
Hi Michaël,

I will look at it.

Nicolas

On 7 December 2015 at 23:12, Michaël Michaud 
<m.michael.mich...@orange.fr<mailto:m.michael.mich...@orange.fr>> wrote:
Hi

Waw, thanks for this refactoring Nicolas !

Just noticed the following regression

in the File > Execute Query plugin
If I try to query a postgis table as I did before, I get the following NPE :
java.lang.NullPointerException
    at 
com.vividsolutions.jump.datastore.spatialdatabases.SpatialDatabasesResultSetConverter.init(SpatialDatabasesResultSetConverter.java:72)

The same NPE occurs with the read/write postgis driver

Any idea ?

Michaël

Le 07/12/2015 18:16, Nicolas Ribot a écrit :
Hi,

Oracle Spatial support has been added to OJ core (read-only).
It works the same way as Postgis support: define a DB connection to Oracle and 
choose spatial layers from the list of found layers to display them in OJ

Oracle 9i -> 12c supported (though only tested recently with Oracle 11i and 
12c).

The SpatialDatabases plugin also contains code to support MariaDB/MySQL and 
Spatialite. (SQL Server in the pipe...)

I was thinking about adding this code to the core, too.
What do you think ?

Nicolas




------------------------------------------------------------------------------

Go from Idea to Many App Stores Faster with Intel(R) XDK

Give your users amazing mobile app experiences with Intel(R) XDK.

Use one codebase in this all-in-one HTML5 development environment.

Design, debug & build mobile apps & 2D/3D high-impact games for multiple OSs.

http://pubads.g.doubleclick.net/gampad/clk?id=254741911&iu=/4140


_______________________________________________

Jump-pilot-devel mailing list

Jump-pilot-devel@lists.sourceforge.net<mailto:Jump-pilot-devel@lists.sourceforge.net>

https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel


------------------------------------------------------------------------------
Go from Idea to Many App Stores Faster with Intel(R) XDK
Give your users amazing mobile app experiences with Intel(R) XDK.
Use one codebase in this all-in-one HTML5 development environment.
Design, debug & build mobile apps & 2D/3D high-impact games for multiple OSs.
http://pubads.g.doubleclick.net/gampad/clk?id=254741911&iu=/4140
_______________________________________________
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net<mailto:Jump-pilot-devel@lists.sourceforge.net>
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel



------------------------------------------------------------------------------

Go from Idea to Many App Stores Faster with Intel(R) XDK

Give your users amazing mobile app experiences with Intel(R) XDK.

Use one codebase in this all-in-one HTML5 development environment.

Design, debug & build mobile apps & 2D/3D high-impact games for multiple OSs.

http://pubads.g.doubleclick.net/gampad/clk?id=254741911&iu=/4140


_______________________________________________

Jump-pilot-devel mailing list

Jump-pilot-devel@lists.sourceforge.net<mailto:Jump-pilot-devel@lists.sourceforge.net>

https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel


------------------------------------------------------------------------------

_______________________________________________
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net<mailto:Jump-pilot-devel@lists.sourceforge.net>
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel

------------------------------------------------------------------------------
_______________________________________________
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel

Reply via email to