<< Click to Display Table of Contents >> Navigation: 5. Detailed description of the Actions > 5.2. Input Actions > 5.2.4. SQLite Reader – GIS support > 5.2.4.1. GIS Support |
The SQLite engine integrated inside Anatella supports the Spatialite Exentions to do advanced GIS queries on your GIS databases.
The Spatialite library offers mostly the same set of GIS functionalities that are available in PostgreSQL + PostGIS (but faster), Oracle Spatialite or SQL Server. The spatialite library is mostly OGC-SFS compliant (i.e. it’s compliant with the “Open Geospatial Consortium” standard).
When installing the additional Spatialite components inside Anatella, you also get:
•a large documentation (151 pages PDF) on how to use spatialite (with QGIS) to make GIS operations (e.g. geographical joins). For example, with spatialite (and the GIS data from the Government), we can:
oCount the number of "mail boxes" in a given radius around any given agency or Point-Of-Sale.
oEstimate the average area (in square meters) of these houses (e.g. to get an estimate of household revenue)
•An additional external tool named “Spatialite GUI” that is optimized to allow you to easily design GIS queries interactively.
To install the additional Spatialite components inside Anatella, click here:
The complete list of functions available inside the Spatialite extention is given here:
http://www.gaia-gis.it/gaia-sins/spatialite-sql-4.3.0.html
To test if the Spatialite extention has been correctly loaded inside Anatella, run the following SQL command: select spatialite_version()
The external tool named “Spatialite GUI” (available here) allows you to:
•Easily create GIS queries interactively
•Easily manipulate GIS objects.
For example, you can easily import&export shape files:
Here is an example of PDF exportation:
Here is an example of SGV exportation:
…but maybe the easiest way to interactively see your geometries is to use the “Quantum GIS” software (also named QGIS). QGIS is a really popular and widespread desktop GIS app: You can download the latest QGIS from:
http://www.qgis.org/
QGIS contains an internal data provider supporting SpatiaLite: So interacting with any SpatiaLite's DataBase using a classic desktop GIS is simple and easy: Here is an example of using a Spatialite DataBase inside QGIS:
You simply have to connect the SpatiaLite's DB, then choose the layer(s) that you intend to use.
Please note: According to DBMS terminology you are accustomed to handle tables. But in the GIS own jargon the term layers is very often used to identify exactly the same thing.
Below is an example where we used QGIS to represent graphically the proximity to two different railway lines in Italy. The “proximity” to the railway line is divided into 5 classes that are defined this way:
Class |
Min. distance |
Max. distance |
A-class |
0 Km |
1 Km |
B-class |
1 Km |
2.5 Km |
C-class |
2.5 Km |
5 Km |
D-class |
5 Km |
10 Km |
E-class |
10 Km |
20 Km |
Here are the 5 classes (i.e. the A,B,C,D,E classes) represented inside QGIS, for visual inspection: