Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Web and WebWorks Development

Reply
Developer
Posts: 482
Registered: ‎10-24-2008
My Device: 9300
My Carrier: AT&T
Accepted Solution

Widget Sqlite using a packaged .sqlite file?

If I package a sqlite database to be installed with my widget , how to I access that data in the widget? I've been reading the gears documentation and the "attach" and "Detach" commands are both disabled?

_________________________________________
www.jasonmace.com/blackberry
Highlighted
Retired
Posts: 3,708
Registered: ‎10-16-2008
My Device: Z10
My Carrier: Rogers

Re: Widget Sqlite using a packaged .sqlite file?

You will not be able to distribute a SQLite pre-packaged database with your application.  All Gears databases are encrypted on the device and cannot be replaced.

 

You will have to build your database via JavaScript.  For your default data, you could embed XML files in your widget and then loop through them to populate your database in a worker thread.

Tim Neil
Director, Application Platform & Tools Product Management
Follow me on Twitter
Developer
Posts: 482
Registered: ‎10-24-2008
My Device: 9300
My Carrier: AT&T

Re: Widget Sqlite using a packaged .sqlite file?

Thanks Tim.

 

Would it be possible to at least save the schema of my database and import that?

 

just trying to see where I can cut corners and speed things up.

_________________________________________
www.jasonmace.com/blackberry