1. Writing Purpose
This article is as Project Tracy (see http://wrwcmaster.spaces.live.com/blog/cns! 800C7A880C83AB69! 2287. entry.
The reason for this issue is that it is better to compare which database Tracy should use as the local storage. I have also translated an article "select the appropriate data storage (SSCE, Access, XML, etc.)"
The second cause is that the introduction of the XML database architecture and details was seen on cnblogs some time ago:
So the purpose of this article is to introduce the feasibility of using XML as a database and the research results of other people so far.
2. XML database Introduction
There are two types of XML data:
1. XML-enabled: accept input and output in XML format, but the storage is still in the traditional database form
2. Native XML (NXD, Native XML database) uses XML documents as the core storage unit, while traditional relational databases use a row in the table as the most basic logical storage unit.
XML as a database
Advantages:
Self-description (the tag used describes the structure and type of the data, despite the lack of semantics)
Interchangeable (portable) (Unicode)
Ability to describe data in a tree or graphic structure
Disadvantages:
It is parsed and converted into text, so data access is slow.
Lack of efficient storage, indexing, security, transaction and data consistency, multi-user access, triggers, and query of multiple files
3. XML database performance
A. query speed
Reading local disk files is usually faster than reading real relational databases. (This is actually very common sense, but the key is not the speed of reading files, but the speed of finding the desired information from the read files. Will XML be faster than databases in this regard? After I finish the experiment. I guess because it is read from the memory, the speed should not be slow)
You can consider adding XML indexes, but there is no good idea about specific algorithms.
B. Comparison between other small Databases
It is a good choice to use XML without concurrency requirements.
Summary:
XML database Applicability
1. Small files, small data volume
2. Quick deployment is required
3. good readability
4. Less security considerations
5. Throwing away SQL statements is mainly applicable to your own read/write APIs.
6. Less concurrency
7. The performance requirement is not high. You can use a local database.
In these cases, the XML document can be used as a local database. The most common case is to configure the INI file.
This is why I strongly recommend using XML as the local storage of Tracy between SSCE, Access and XML.
So far, I don't think it is necessary to develop the requirements for other providers, such as OLE DB Provider. However, in order to ensure that this is not just a kind of sentiment, we will use experiments to prove the efficiency of XML.
References
XML database architecture and details
Http://www.cnblogs.com/chenxizhang/archive/2009/08/12/1544105.htm
XML and database
Http://blog.csdn.net/onestab/archive/2006/11/20/1397135.aspx