Hi Sandro,

thanks for your answer - I will post the question (possibly including the solution) on the appropriate mailing list. Actually, my columns are defined the way you suggested - I will make it more clear in my post to the spatialite mailing-list.

But your answer sounds interesting - so I hope you could answer one further question: Currently I am converting my C# polygons to a string of the form "LINESTRING(x1 y1, ..., xN yN)" which would be the WKT (Well-Known Text) format. If I understand your answer correct I could simply convert my C# polygons to the WKB (Well-Known Binary) format and use BLOB as the DbType in my SQLiteParameter.
Is that correct?

Am 29.01.2013 14:48, schrieb [email protected]:
On Tue, 29 Jan 2013 14:22:07 +0100, Markus Dibo wrote:
Hello dear (System.Data.)SQLite users,

I am using System.Data.SQLite in combination with Spatialite which
works very well.
One problem I currently have ... <snip>


Hi Markus,

I suppose that posting such questions into the SpatiaLite own mailing
list [1] would probably be much more appropriate.

[1] https://groups.google.com/forum/?fromgroups#!forum/spatialite-users

just a very quick answer:

trying to insert several milions of records (namely road segments with
just two columns: Id INTEGER, Geometry LINESTRING)


sorry, but this is not the expected way to declare a Geometry column;
the syntax expected by SpatiaLite is:
CREATE xxx (Id INTEGER);
SELECT AddGeometryColumn('xxx', 'Geometry', 4321, 'LINESTRING', 'XY');

Now, the problem is that I don't have a fitting DbType for LINESTRING
(or other GEOMETRY types).


from the SQLite own perspective all Geometries simply are generic BLOBs;
in order to activate any kind of specific support for Geometry, Linestring, Polygon or Point you absolutely have to explicitly call the "special" Spatial
SQL functions supported by the SpatiaLite extension.

bye Sandro



_______________________________________________
sqlite-users mailing list
[email protected]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to