[英]Where does sqlite store the database file on win7 offline?
I'm following this , using js in html to call 'openDatabase("AddressBook",....'. It works, it stores values and calls them them back correctly when I reopen the page but I can't find where the AddressBook DB file is. I've searched my pc, C:\ and appdata etc but I can't find it. I've tried downloading the sqlite3 tool and setting a DB separately and transporting it to the folder but it doesn't seem to recognize it. If I change the name of the DB called it starts a new one and if I then put the previous DB name it shows the stored DB from before. I'd like to know I can locate it and transport it before I learn anymore.我正在关注这一点,在 html 中使用 js 调用'openDatabase(“AddressBook”,....'。它可以工作,它存储值并在我重新打开页面时正确调用它们但我找不到地址簿数据库文件是。我搜索了我的电脑,C:\ 和 appdata 等,但我找不到它。我尝试下载 sqlite3 工具并单独设置数据库并将其传输到文件夹,但它没有似乎可以识别它。如果我更改名为它的数据库的名称,它会启动一个新的数据库,然后如果我输入以前的数据库名称,它会显示以前存储的数据库。我想知道我可以找到它并在之前传输它我学习了。
Can anyone advise where it might be?谁能告诉它可能在哪里? Is there a way to force it into the same folder as the js files?
有没有办法将它强制放入与 js 文件相同的文件夹中?
That guide seems seems to misunderstand the APIs that it is using.该指南似乎误解了它正在使用的 API。 It keeps saying that its using
SQLite
.它一直说它使用
SQLite
。 It's not.它不是。 It looks like it is using the deprecated
WebSQL
spec.看起来它正在使用已弃用的
WebSQL
规范。 The file isn't in your filesystem, it's part of the browser's internal storage and there is no guarantee of how the browser is actually storing it so you can't directly access it from outside the browser.该文件不在您的文件系统中,它是浏览器内部存储的一部分,并且无法保证浏览器实际存储它的方式,因此您无法从浏览器外部直接访问它。
I'm making the assumption that it is using WebSQL because it mentions using openDatabase
and executeSql
.我假设它正在使用 WebSQL,因为它提到使用
openDatabase
和executeSql
。 WebSQL has been deprecated and is no longer maintained in most browsers. WebSQL 已被弃用,并且在大多数浏览器中不再维护。 You can get a detailed reasoning from this answer Why is Web SQL database deprecated?
您可以从这个答案中得到详细的推理Why is Web SQL database deprecated? .
. That guide you're following is also 9 years old and doesn't even discuss WebSQL's deprecation.
您遵循的指南也已有 9 年历史,甚至没有讨论 WebSQL 的弃用。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.