[SailfishDevel] Ship a sqlite dabase with an app

Sebastian Wolf sebastian at ygriega.de
Thu Jul 20 21:21:54 UTC 2017


Hi Pablo,

Am Do. Juli 20 21:29:39 2017 GMT+0200 schrieb J Pablo Navarro:
> Hi SFOS devs!
> 
> I think this is my first email over here and I don't have too much experice 
> with apps, so please be kind :)
> 
> I want to ship an sqlite database with the app. The main reason is that 
> generating this database takes around 15 minutes... and it weights 104 KiB, so 
> I think the best solution would be to shipt it as part of the app instead of 
> download it from somewhere (I don't have a server, so that would be a problem) 
> or generate it the first time the app is opened.
> 
> My question is, what's the best way to do this?

as the others already explained, there are several good ways to achieve that goal. The best one is always a matter of perspective. ;)

I had the same challenge in my first app (I needed to include a full-text search enabled SQLize DB for my dictionary app) and I simply generated it upfront and packaged the DB in the app's RPM file. Works smoothly, is Harbour-compatible and very convenient for you as developer and for your users.

Check out https://github.com/Wunderfitz/harbour-wunderfitz how I did it (project setup etc.).

Best regards, Sebastian


More information about the Devel mailing list