sqlite数据库在设备上的位置 [英] Location of sqlite database on the device

查看:124
本文介绍了sqlite数据库在设备上的位置的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我已经使用默认的扩展SQLiteOpenHelper和覆盖onCreate()的方式以编程方式创建了一个sqlite数据库.这样,可以在需要时动态创建数据库.

I've created a sqlite database programmatically with the default way of extending SQLiteOpenHelper and overriding onCreate(). This way the db gets created on the fly when needed.

我想使用sqlite浏览器在OS X机器上检查db文件的内容. 我知道db文件的名称,但是在设备上找不到它.我已经通过USB连接到设备,并使用finder和terminal进行了查找,但是我找不到db文件.

I'd like to check the contents of the db file on my OS X machine with a sqlite browser. I know the name of the db file, but I can't find it on the device. I've connected to the device via USB and looked with finder and terminal, but I just can't find the db file.

Android设备上的sqlite数据库的默认位置是什么?

What is the default location for a sqlite databases on an android device?

推荐答案

您可以找到创建的名为<your-database-name>

You can find your created database, named <your-database-name>

//data/data/<Your-Application-Package-Name>/databases/<your-database-name>

使用文件资源管理器将其拔出,并将其重命名为.db3扩展名以在SQLiteExplorer中使用它

Pull it out using File explorer and rename it to have .db3 extension to use it in SQLiteExplorer

使用DDMS的文件浏览器导航到仿真器目录.

Use File explorer of DDMS to navigate to emulator directory.

这篇关于sqlite数据库在设备上的位置的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆