This is a migrated thread and some comments may be shown as answers.

Persistent Storage with sqlite database

1 Answer 294 Views
AppBuilder companion app
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Kay
Top achievements
Rank 1
Kay asked on 26 Jan 2014, 06:02 PM
I have 2 questions regarding sqlite when running on the AppBuilder companion app:

1. Access to db file
I tested your sample project "Sqlite" (formerly sample-sqlite) in the AppBuilder companion app on ios7.
After relaunching the app previously entered items are displayed but the todo list seems no longer accessible.
Data Items cannot be deleted. New items cannot be added.
- Do you have an update of your sample code where this effect does not occur?

2. Path to db file
I did not find documentation about the path where the database file is saved - did not find it in the /Documents folder (fileSystem.root.fullPath).
- Where is it saved? (would be helpful for updating the file from a server)
- Is it a persistent memory area?

Thanks & Regards



1 Answer, 1 is accepted

Sort by
0
Kaloyan
Telerik team
answered on 29 Jan 2014, 05:06 PM
Hi Kay,

Thank you for bringing these questions.

  1. I just tested the SQLite sample app deployed via the AppBuilder Companion App and it worked as expected. I was able to add items to the list and to delete them. Even after relaunching the application, the items were there and I was able to use the add/delete functions. However, I would strongly recommend deploying the applications on a connected devices in order to test Integrated Cordova plugins. You will find how to do this, here.
  2. The SQLite plugin provides a persistent local data storage. The db locations should be as follows:
    For Android - /data/data/{app.package}/databases/ or /data/data/{app.package}/app_database/
    For iOS - Document Folder/Your App Docs/

Further, you can check what's behind the integrated plugin here, or check its forum following this link.

I hope this answers your questions.

Regards,
Kaloyan
Telerik

Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

Tags
AppBuilder companion app
Asked by
Kay
Top achievements
Rank 1
Answers by
Kaloyan
Telerik team
Share this question
or