Re: [Qgis-developer] New feature: RFC saving style and ui in Spatialite
regarding this feature I produced PullRequest: https://github.com/qgis/QGIS/pull/1221 thank you Luigi Pirelli (luigi.pire...@faunalia.it - lui...@gmail.com) On 28 February 2014 15:58, Gino Pirelli lui...@gmail.com wrote: regarding how to implement saving SLD in spatialite i downgraded my previous using simple text field... avoiding blob or XmlBlob (SL4.1) the reason is to allow more simpler interoparability reading back sld. Using directly text I can read it's value directly. values are utf8 enconded and reading them outside qgis context (I received some comments about this) it's simple to understand that text value has a locale coding. - I decided to avoid sqlite blob because of to simplify interoperability avoiding blob decoding step that it's less uman natural - I decided to avoid XmlBlob format because it's available only with SL 4.1. I plan to use this data type when SL 4.1 will be more used. At the moment I preferred to allow this functionality available in all platform and distribution in witch qgis is available and in some of them (e.g. debian wheezy, Ubuntu 13) SL 4.1 it's not packaged. - I hope to add the same functions to the the new GeoPackage, but this it's not still planned. please let me know if there are comments code is here: https://github.com/luipir/QGIS/tree/spatialite-savestyle diff is here: https://github.com/luipir/QGIS/compare/spatialite-savestyle thank you, Luigi Pirelli (luigi.pire...@faunalia.it - lui...@gmail.com) On 5 February 2014 13:18, Gino Pirelli lui...@gmail.com wrote: Hi, I'm developing a new feature to save SLD and ui in Spatialite provider in the same way this function is available for postgres. this function developed for Faunalia is funded by ARPA Piemonte fork is available at: https://github.com/luipir/QGIS/tree/spatialite-savestyle and actual modification are localized in this commit: f058bea1fe51116b8231eb5c1ca4faee485c38b2 there are some question about how to develop it and are related how to manage XML in a sqlite/spatialite table. this code derive by the postgres provider code where QML and UI xmls are recorded in a XML column. XML is a postgres type. This type is not available in SQlite but it's available in SL 4.1 (called XmlBlob [1]) In this preliminary commit XML is saved in a text column, but saving XML as a blog (blob type in sqlite or XmlBlob in SL) have the advantage to avoid all encoding problems. so the question is... sqlite blob or spatialite xmlbob? Blob type can't allow XML parsing using SQL queries XmlBlob allows this (using libxml2) Blob type is sqlite native type XmlBlob can be used only with SL 4.1 My preference is to use native data type Blob. What's you opinion about blob/ xmlblob or whatever regards, Luigi Pirelli (luigi.pire...@faunalia.it - lui...@gmail.com) [1] https://www.gaia-gis.it/fossil/libspatialite/wiki?name=XmlBlob-intro ___ Qgis-developer mailing list Qgis-developer@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/qgis-developer
Re: [Qgis-developer] New feature: RFC saving style and ui in Spatialite
regarding how to implement saving SLD in spatialite i downgraded my previous using simple text field... avoiding blob or XmlBlob (SL4.1) the reason is to allow more simpler interoparability reading back sld. Using directly text I can read it's value directly. values are utf8 enconded and reading them outside qgis context (I received some comments about this) it's simple to understand that text value has a locale coding. - I decided to avoid sqlite blob because of to simplify interoperability avoiding blob decoding step that it's less uman natural - I decided to avoid XmlBlob format because it's available only with SL 4.1. I plan to use this data type when SL 4.1 will be more used. At the moment I preferred to allow this functionality available in all platform and distribution in witch qgis is available and in some of them (e.g. debian wheezy, Ubuntu 13) SL 4.1 it's not packaged. - I hope to add the same functions to the the new GeoPackage, but this it's not still planned. please let me know if there are comments code is here: https://github.com/luipir/QGIS/tree/spatialite-savestyle diff is here: https://github.com/luipir/QGIS/compare/spatialite-savestyle thank you, Luigi Pirelli (luigi.pire...@faunalia.it - lui...@gmail.com) On 5 February 2014 13:18, Gino Pirelli lui...@gmail.com wrote: Hi, I'm developing a new feature to save SLD and ui in Spatialite provider in the same way this function is available for postgres. this function developed for Faunalia is funded by ARPA Piemonte fork is available at: https://github.com/luipir/QGIS/tree/spatialite-savestyle and actual modification are localized in this commit: f058bea1fe51116b8231eb5c1ca4faee485c38b2 there are some question about how to develop it and are related how to manage XML in a sqlite/spatialite table. this code derive by the postgres provider code where QML and UI xmls are recorded in a XML column. XML is a postgres type. This type is not available in SQlite but it's available in SL 4.1 (called XmlBlob [1]) In this preliminary commit XML is saved in a text column, but saving XML as a blog (blob type in sqlite or XmlBlob in SL) have the advantage to avoid all encoding problems. so the question is... sqlite blob or spatialite xmlbob? Blob type can't allow XML parsing using SQL queries XmlBlob allows this (using libxml2) Blob type is sqlite native type XmlBlob can be used only with SL 4.1 My preference is to use native data type Blob. What's you opinion about blob/ xmlblob or whatever regards, Luigi Pirelli (luigi.pire...@faunalia.it - lui...@gmail.com) [1] https://www.gaia-gis.it/fossil/libspatialite/wiki?name=XmlBlob-intro ___ Qgis-developer mailing list Qgis-developer@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/qgis-developer
[Qgis-developer] New feature: RFC saving style and ui in Spatialite
Hi, I'm developing a new feature to save SLD and ui in Spatialite provider in the same way this function is available for postgres. this function developed for Faunalia is funded by ARPA Piemonte fork is available at: https://github.com/luipir/QGIS/tree/spatialite-savestyle and actual modification are localized in this commit: f058bea1fe51116b8231eb5c1ca4faee485c38b2 there are some question about how to develop it and are related how to manage XML in a sqlite/spatialite table. this code derive by the postgres provider code where QML and UI xmls are recorded in a XML column. XML is a postgres type. This type is not available in SQlite but it's available in SL 4.1 (called XmlBlob [1]) In this preliminary commit XML is saved in a text column, but saving XML as a blog (blob type in sqlite or XmlBlob in SL) have the advantage to avoid all encoding problems. so the question is... sqlite blob or spatialite xmlbob? Blob type can't allow XML parsing using SQL queries XmlBlob allows this (using libxml2) Blob type is sqlite native type XmlBlob can be used only with SL 4.1 My preference is to use native data type Blob. What's you opinion about blob/ xmlblob or whatever regards, Luigi Pirelli (luigi.pire...@faunalia.it - lui...@gmail.com) [1] https://www.gaia-gis.it/fossil/libspatialite/wiki?name=XmlBlob-intro ___ Qgis-developer mailing list Qgis-developer@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/qgis-developer
Re: [Qgis-developer] New feature: RFC saving style and ui in Spatialite
Saving style as spatialite files would probably cause a significant file size overhead - don't all spatialite files take at least 3MB for the SRS tables? On Wed, Feb 5, 2014 at 10:18 AM, Gino Pirelli lui...@gmail.com wrote: Hi, I'm developing a new feature to save SLD and ui in Spatialite provider in the same way this function is available for postgres. this function developed for Faunalia is funded by ARPA Piemonte fork is available at: https://github.com/luipir/QGIS/tree/spatialite-savestyle and actual modification are localized in this commit: f058bea1fe51116b8231eb5c1ca4faee485c38b2 there are some question about how to develop it and are related how to manage XML in a sqlite/spatialite table. this code derive by the postgres provider code where QML and UI xmls are recorded in a XML column. XML is a postgres type. This type is not available in SQlite but it's available in SL 4.1 (called XmlBlob [1]) In this preliminary commit XML is saved in a text column, but saving XML as a blog (blob type in sqlite or XmlBlob in SL) have the advantage to avoid all encoding problems. so the question is... sqlite blob or spatialite xmlbob? Blob type can't allow XML parsing using SQL queries XmlBlob allows this (using libxml2) Blob type is sqlite native type XmlBlob can be used only with SL 4.1 My preference is to use native data type Blob. What's you opinion about blob/ xmlblob or whatever regards, Luigi Pirelli (luigi.pire...@faunalia.it - lui...@gmail.com) [1] https://www.gaia-gis.it/fossil/libspatialite/wiki?name=XmlBlob-intro ___ Qgis-developer mailing list Qgis-developer@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/qgis-developer ___ Qgis-developer mailing list Qgis-developer@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/qgis-developer
Re: [Qgis-developer] New feature: RFC saving style and ui in Spatialite
The 3MB size is the size of an empty DB spatialite . A DB emty is 3MB size . A DBspatialite with 1 single dataset of 10MB is 3MB +10MB = 13MB. A DBspatialite with 3 dataset everyone of 10MB is 3MB + 10MB +10MB + 10MB = 33MB. Also, AFAIK the goal of Luigi is storing in the spatialite the SLD finalized to rendering the same dataset stored in the spatialite, not to store SLD for general usage. Regards, Andrea. On 05/02/2014 22:24, Etienne Tourigny wrote: Saving style as spatialite files would probably cause a significant file size overhead - don't all spatialite files take at least 3MB for the SRS tables? On Wed, Feb 5, 2014 at 10:18 AM, Gino Pirelli lui...@gmail.com mailto:lui...@gmail.com wrote: Hi, I'm developing a new feature to save SLD and ui in Spatialite provider in the same way this function is available for postgres. this function developed for Faunalia is funded by ARPA Piemonte fork is available at: https://github.com/luipir/QGIS/tree/spatialite-savestyle and actual modification are localized in this commit: f058bea1fe51116b8231eb5c1ca4faee485c38b2 there are some question about how to develop it and are related how to manage XML in a sqlite/spatialite table. this code derive by the postgres provider code where QML and UI xmls are recorded in a XML column. XML is a postgres type. This type is not available in SQlite but it's available in SL 4.1 (called XmlBlob [1]) In this preliminary commit XML is saved in a text column, but saving XML as a blog (blob type in sqlite or XmlBlob in SL) have the advantage to avoid all encoding problems. so the question is... sqlite blob or spatialite xmlbob? Blob type can't allow XML parsing using SQL queries XmlBlob allows this (using libxml2) Blob type is sqlite native type XmlBlob can be used only with SL 4.1 My preference is to use native data type Blob. What's you opinion about blob/ xmlblob or whatever regards, Luigi Pirelli (luigi.pire...@faunalia.it mailto:luigi.pire...@faunalia.it - lui...@gmail.com mailto:lui...@gmail.com) [1] https://www.gaia-gis.it/fossil/libspatialite/wiki?name=XmlBlob-intro ___ Qgis-developer mailing list Qgis-developer@lists.osgeo.org mailto:Qgis-developer@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/qgis-developer ___ Qgis-developer mailing list Qgis-developer@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/qgis-developer ___ Qgis-developer mailing list Qgis-developer@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/qgis-developer
Re: [Qgis-developer] New feature: RFC saving style and ui in Spatialite
On 5 February 2014 22:29, aperi2007 aperi2...@gmail.com wrote: Also, AFAIK the goal of Luigi is storing in the spatialite the SLD finalized to rendering the same dataset stored in the spatialite, not to store SLD for general usage. correct ___ Qgis-developer mailing list Qgis-developer@lists.osgeo.org http://lists.osgeo.org/mailman/listinfo/qgis-developer