Re: [sqlite] Problem compiling 3.17.0 in MSVS 12

2017-02-21 Thread Duncan Hall
Brilliant! Thanks

 

 

> cl sqlite3.c -link -dll -out:sqlite3.dll 

 

cl sqlite3.c -DSQLITE_API=__declspec(dllexport) -link -dll -out:sqlite3.dll 

 

> nmake /f makefile.msc 

 

nmake /f makefile.msc DYNAMIC_SHELL=1

___
sqlite-users mailing list
sqlite-users@mailinglists.sqlite.org
http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] System.Data.SQLite for Pocket PC & RTREE

2015-02-09 Thread Duncan Hall
OK. Embarassing as it is, I'm going to have to 'fess up here.
When I attempted to implement a stopwatch which wasn't available, I
discovered that the app was targetting .Net 2. When I rebuilt it targetting
3.5 it worked.

Unfortunately the stopwatch tells me that it takes longer than I would like
(1.5s against 100ms on the desktop), but that is another story.

Thanks for your help and apologies for the overlooking the obvious

Duncan



--
View this message in context: 
http://sqlite.1065341.n5.nabble.com/Re-System-Data-SQLite-for-Pocket-PC-RTREE-tp80344p80473.html
Sent from the SQLite mailing list archive at Nabble.com.
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] System.Data.SQLite for Pocket PC & RTREE

2015-02-07 Thread Duncan Hall

> Thanks.  I've run the schema and query here with the desktop version of
> SpatiaLite and it does not crash.  I suspect the underlying issue may be
> an alignment fault (or stack overflow) due to bad interaction between the
> ARM processor architecture and the SpatiaLite extension.

I'm not using the Spatialite extension for the query, only the indexes
created by it on the desktop which I think is a pretty standard SQLite
RTree. At least it works that way on the desktop.
Maybe I should attempt to create the database from scratch using geometry
bounding boxes for the index, but I can't see how this would be different.
Spatialite databases are really just complex SQLite databases


> Out of curiousity, do you know where to find the loadable module binaries
> for Windows CE (for SpatiaLite)?

That would be nice.
I have been trying to do something like this for years, but lacked the
necessary C skills to compile for Mobile. I think it has been done, but not
for recent versions that I am aware of.
My current projects for Android and IOS ran up against licensing issues for
the Spatialite dependent libraries in IOS so I started using the RTree to
run the query, then decode the Spatialite geometry BLOB afterwards. It seems
to run fine for my purposes without too much performance hit, so I revisited
the Windows Mobile 5/6 platform as we have quite a few still running and
they are still being used and sold  in the mobile GIS world despite
Microsoft's abandonment.
I was delighted to find that you are still supporting it.

Duncan




--
View this message in context: 
http://sqlite.1065341.n5.nabble.com/Re-System-Data-SQLite-for-Pocket-PC-RTREE-tp80344p80423.html
Sent from the SQLite mailing list archive at Nabble.com.
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] System.Data.SQLite for Pocket PC & RTREE

2015-02-05 Thread Duncan Hall



Joe Mistachkin-3 wrote
> Are you able to share the schema for your database?  It may be helpful.


The db was created by Spatialite and has a fairly lengthy schema. I'm not
sure if I should leave anything out so I'll attach a text file.


schema.txt   

Thanks




--
View this message in context: 
http://sqlite.1065341.n5.nabble.com/Re-System-Data-SQLite-for-Pocket-PC-RTREE-tp80344p80411.html
Sent from the SQLite mailing list archive at Nabble.com.
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users


Re: [sqlite] System.Data.SQLite for Pocket PC & RTREE

2015-02-05 Thread Duncan Hall
Thanks for the response

I'm developing for a Mobile 5 or 6 device in Visual Studio 2008.
I'm porting a project that works fine on the desktop in VS 2012.
I have tried the most recent release 1.094 and also 1.095 pre release. I
also tried with an old version 1.082 which is working in another app, but it
could not open the database with the existing code.
Querying my database is fine for standard queries, but any query to the
rtree index causes the app to crash. The code used is below (VB I'm afraid),
and when the first CommandText is run a list of tables includes the
idx_Locale_Geometry, but when the second is run (test query, I have tried
others) the app crashes with a message 'The remote connection to the device
has been lost. Please verify the device connection and restart debugging'


Dim dbDataReader As SQLiteDataReader = Nothing
Dim cmd As SQLiteCommand = m_Connection.CreateCommand()
'cmd.CommandText = "SELECT name FROM sqlite_master WHERE
type='table'"
cmd.CommandText = "SELECT * FROM idx_Locale_Geometry "
Try
 dbDataReader = cmd.ExecuteReader()
Catch ex as Exception
End Try
If dbDataReader.HasRows() Then
While dbDataReader.Read()
   'Get data

End While
Else
Throw New Exception("No data")
End If


The crash is at ExecuteReader() and does not throw an exception and the call
stack clears. A break point at the catch clause is never triggered so I'm
not sure how to find the error. I might have to catch it on the device but
I'm not sure how to do that.


Thanks for your help

Duncan 




--
View this message in context: 
http://sqlite.1065341.n5.nabble.com/Re-System-Data-SQLite-for-Pocket-PC-RTREE-tp80344p80403.html
Sent from the SQLite mailing list archive at Nabble.com.
___
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users