Titanium: Where is the SQLite DB Stored?

家住魔仙堡 提交于 2019-12-08 07:31:12

问题


I started a titanium app that uses a sqlite db. I'm getting strange DB results so just want to browse the database using FF SQLite Manager but I'm not sure where the database is?

This is the code that creates the db (part):

var db = (function() {

  //create an object which will be our public API
  var api = {};

  //maintain a database connection we can use
  var conn = Titanium.Database.open('quote');

I'm running Titanium studio on a Mac.

Thanks,

Billy


回答1:


i thought it was something like

/Library/Application\ Support/iPhone\ Simulator/.../your.app.id/..

have a look. consider that there are two /Library-Folders (in root and in home). sorry for the unprecise answer.




回答2:


All your projects folders are located here:

~/Library/Application\ Support/Titanium/appdata/

They are sorted by app ID. In each folder you'll find a Databases.db file which contents your DBs if the app has one.




回答3:


/data/data/your.app.id/databases/




回答4:


For android , the location is /data/data/your.app.id/databases/

Ordinary, you could not direct see the file, unless you got the root permission。

And, you can use adb series command to get the file to you develop computer, and analyze the db file on you desktop computer.

For iOS, best way to see the db file is run the app in you simulater. the db file usually store at location simalar as this

/Users/[your name]/Library/Application Support/iPhone Simulator/7.1/Applications/3CE12954-6C8A-48E1-BF71-CF483E01CBA1/Library/Private Documents



回答5:


The path is at

~/Library/Developer/CoreSimulator/Devices/{DEVICEID}/data/Containers/Data/Application/{APP_WEIRD_ID}/Library/Private Documents/



来源:https://stackoverflow.com/questions/7178931/titanium-where-is-the-sqlite-db-stored

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!