摘要
提出一种在保存数据约束条件下,把关系数据库信息转换为XML文档,并在得到的XML文档信息中能完整地体现所保存的数据约束的新方法。解决了只注意数据结构的无损转换,而忽略数据约束的保存问题。具体做法是:为使关系模式与XML模式相互兼容,把关系数据库中存在数据联系的关系合并成一个新关系;把每个新关系按其数据的约束条件转换为XML文档树后,将多个XML合并成一棵XML文档树;在此树上可根据实际需求选择整个(部分)XML文档树转换为XML文档。
A new method of translating relational database into XML documents with data constraint preservation was put forward. The information of obtained XML documents could embody completely saved data constraints. It considered not only lossless transformation of database structure, but also data constraint storage. The concrete steps were taken: firstly, in order to make relational mode and XML mode compatible, the relations that had data connections in relational database were integrated into a new relation; then, every new relation was converted to an XML document according to data constraint conditions, and XML document trees were merged into an XML document tree; finally, in the light of user requirements, a whole or a part of XML document tree was converted to an XML document.
出处
《辽宁石油化工大学学报》
CAS
2004年第4期67-70,73,共5页
Journal of Liaoning Petrochemical University