XML VS SQLite
来源:互联网 发布:js隐藏标签 编辑:程序博客网 时间:2024/06/18 16:17
Advantages of sqlite over xml:
- everything in one file,
- performance loss is lower than XML as cache gets bigger,
- you can keep feed metadata separate from cache itself (other table), but accessible in the same way,
- SQL is probably easier to work with than XPath for most people.
Disadvantages of sqlite:
- can be problematic with multiple processes accessing same database (probably not your case),
- you should know at least basic SQL. Unless there will be hundreds of thousands of items in cache, I don't think you will need to optimize it much,
- maybe in some way it can be more dangerous from security standpoint (SQL injection). On the other hand, you are not coding web app, so this should not happen.
Here is a summary
For tree data, XML is much easier to query and modify using XPATH.
For small datasets (less than 10M), XML blew away sqlite in performance.
For large datasets (greater than 10M-100M), XML load time and memory usage became a big problem, to the point that some computers become unusable.
We couldn't get any opensource xml database to fix the problems associated with large datasets.
SQLITE doesn't have the memory problems of XML dom, but it is generally slower in processing the data (it is on the hard drive, not in memory). (note- sqlite tables can be stored in memory, perhaps this would make it as fast.... We didn't try this because we wanted to get the data out of memory.)
Storing and querying tree data in a table is not enjoyable. However, managing transactions and indexing partially makes up for it.
- 【学习】XML VS SQLite
- XML VS SQLite
- SQLite vs MySQL vs PostgreSQL
- VS生成sqlite.lib
- VS编译SQLite
- vs编译sqlite源码
- VS 与 SQLite数据库 连接
- [iOS] SQLite vs. Core Data
- android SQLite getWritableDatabase VS getReadableDatabase
- JSON vs YAML vs XML
- Annotation VS. XML VS. interface
- PB vs XML vs JSON
- JSON vs ProtoBuf vs XML
- clientaccesspolicy.xml vs. crossdomain.xml
- XML attribute vs XML element
- XML VS. CSV
- xml db vs. RDB
- JSON VS XML
- 汇编软件MASM和调试工具DEBUG的使用
- 关于Windows7 64的注册表读写问题
- uvaoj-1225:数数字
- spring(AOP)多个切面
- Leetcode之first missing positive
- XML VS SQLite
- POJ 1985 Cow Marathon(树的直径)
- JUnit Test WebService
- 可以输入的下拉框,可以筛选内容,可输入筛选下拉框(原创)
- Leetcode之Sort List
- HDU-1010-Tempter of the Bone( DFS + 深度优先搜索 )
- 在java中的基础点
- ubuntu 搭建(编译)生产力版的LNMP环境
- RHCE 学习笔记(20) ACL