×

zbMATH — the first resource for mathematics

Querying XML documents in logic programming. (English) Zbl 1139.68014
Summary: Extensible Markup Language (XML) is a simple, very flexible text format derived from SGML. Originally designed to meet the challenges of large-scale electronic publishing, XML is also playing an increasingly important role in the exchange of a wide variety of data on the Web and elsewhere. XPath language is the result of an effort to provide address parts of an XML document. In support of this primary purpose, it becomes in a query language against an XML document. In this paper we present a proposal for the implementation of the XPath language in logic programming. With this aim we will describe the representation of XML documents by means of a logic program. Rules and facts can be used for representing the document schema and the XML document itself. In particular, we will present how to index XML documents in logic programs: rules are supposed to be stored in main memory, however facts are stored in secondary memory by using two kind of indexes: one for each XML tag, and other for each group of terminal items. In addition, we will study how to query by means of the XPath language against a logic program representing an XML document. It evolves the specialization of the logic program with regard to the XPath expression. Finally, we will also explain how to combine the indexing and the top-down evaluation of the logic program.
MSC:
68N17 Logic programming
Software:
CDuce; XDuce
PDF BibTeX XML Cite
Full Text: DOI
References:
[1] Almendros-Jiménez, Proceedings of the Workshop on Logic Programming (2007)
[2] Almendros-Jiménez, Journal of Universal Computer Science 12 pp 1651– (2006)
[3] Chamberlin, XQuery from the experts (2004)
[4] Apt, Handbook of Theoretical Computer Science pp 493– (1990)
[5] Rémy, Applied Semantics: Advanced Lectures (2002)
[6] DOI: 10.1147/sj.414.0597 · Zbl 05420854 · doi:10.1147/sj.414.0597
[7] Abiteboul, Data on the Web: From Relations to Semistructured Data and XML (2000)
This reference list is based on information provided by the publisher or from digital mathematics libraries. Its items are heuristically matched to zbMATH identifiers and may contain data conversion errors. It attempts to reflect the references listed in the original paper as accurately as possible without claiming the completeness or perfect precision of the matching.