On Mon, 03 Feb 2014 19:20:33 +0100
christopher.l...@thurweb.ch wrote:

> Hi All
> 
[snip]> 
> But I was never happy with that solution, and it now seems to me
> that a Qt Desktop app would be much better suited to configuring /  
> populating the DB. (more screen, better keyboard etc.).

....

> But exactly how should this work? I see several possibilities, all  
> with pros and cons.
 
> a) The Desktop app creates a LocalStorageDB, and the entire DB is  
> transferred to the Jolla. This means that Landed would have to
> deploy the DB on a file level, then access it via the LocalStorage
> api as normal.

....

> b) The Desktop app dumps a human readable exchange file (csv, xml,  
> json) which is picked up by Landed, parsed and converted to SQL  
> INSERTS then called via the LocalStorage API

> At the moment I favour option b) as the most likely to work and be  
> accepted, with option d) as the wildcard probably wont't work, but  
> might turn out to be the easy option.
> 
> Thanks in advance for your thoughts,

One question first. Are you intending to do the swap of files at home?
If so, why not fire up some sort of server on the home machine which,
when you fire up the app on the phone, is accessed by the app which
then proceeds to download the latest version of the database. You just
need to set up a procedure to make sure you're not going to overwrite
the 'father' generation of the database with the 'son' version, or even
worse the 'grandfather' version (that assumes that you have three
versions).

Another option is a dropbox client on the phone - I think one is
already available.

How about a line in the SQL file which has a creation date? That way
you easily run a check from the code on both the desktop app and the
phone to make absolutely certain that the version of the db you're
using is the latest all-singing, all-dancing version.

I personally wouldn't be doing all the export/import stuff. That seems
prone to errors/corruption IMHO.

Just my two pennies worth.

CDW (not Chris to avoid confusion ;-))
_______________________________________________
SailfishOS.org Devel mailing list

Reply via email to