XML-QL A Query Language for XML Charuta Nakhe

Slides:



Advertisements
Similar presentations
XML Examples. Bank Information Basic structure: A-101 Downtown 500 … Johnson Alma Surrey … A-101 Johnson …
Advertisements

XML e X tensible M arkup L anguage (XML) By: Albert Beng Kiat Tan Ayzer Mungan Edwin Hendriadi.
XML May 3 rd, XQuery Based on Quilt (which is based on XML-QL) Check out the W3C web site for the latest. XML Query data model –Ordered !
Leveraging XML with ColdFusion Jeff Tapper June 2004.
Relational Databases for Querying XML Documents: Limitations & Opportunities VLDB`99 Shanmugasundaram, J., Tufte, K., He, G., Zhang, C., DeWitt, D., Naughton,
Managing XML and Semistructured Data Lecture 8: Query Languages - XML-QL Prof. Dan Suciu Spring 2001.
Web-site Management System Strudel Presented by: LAKHLIFI Houda Instructor: Dr. Haddouti.
From Semistructured Data to XML: Migrating The Lore Data Model and Query Language Roy Goldman, Jason McHugh, Jennifer Widom Stanford University
B.Sc. Multimedia ComputingMedia Technologies Database Technologies.
A Graphical Environment to Query XML Data with XQuery
Query Languages Aswin Yedlapalli. XML Query data model Document is viewed as a labeled tree with nodes Successors of node may be : - an ordered sequence.
1 COS 425: Database and Information Management Systems XML and information exchange.
XML - QL A Query Language for XML Version /2000XML-QL2 Outline * Introduction * Examples in XML-QL * A Data Model for XML * Advanced Examples in.
1 Statistics XML: –Altavista: 800,000 pages returned. –Amazon.com: 242 books. In comparison: –God: 12,000 books, 7 Million pages –Bible: 32,000 books,
1 XML and QUERY Shilpi Ahuja CSE Data Mining 4 th April 2002.
1 New Ways of Querying the Web by Eliahu Brodsky and Alina Blizhovsky.
Database Systems and XML David Wu CS 632 April 23, 2001.
4/15/2002Bo Du 1 - Bo Du, April 15, XML - QL A Query Language for XML.
ebis/etat/ebuy/xdia Joint Effort ebis/etat/ebuy/xdia Joint Effort2 Introduction Extensible Markup language XML SCHEMA DTD.
XML –Query Languages, Extracting from Relational Databases ADVANCED DATABASES Khawaja Mohiuddin Assistant Professor Department of Computer Sciences Bahria.
XML Technologies and Applications Rajshekhar Sunderraman Department of Computer Science Georgia State University Atlanta, GA 30302
Fundamentals, Design, and Implementation, 9/e Text and XML databases Instructor: Dragomir R. Radev Winter 2005.
September 15, 2003Houssam Haitof1 XSL Transformation Houssam Haitof.
1 Advanced Topics XML and Databases. 2 XML u Overview u Structure of XML Data –XML Document Type Definition DTD –Namespaces –XML Schema u Query and Transformation.
Processing of structured documents Spring 2003, Part 8 Helena Ahonen-Myka.
Manohar – Why XML is Required Problem: We want to save the data and retrieve it further or to transfer over the network. This.
XML Fundementals XML vs.. HTML XML vs.. HTML XML Document (elements vs. attributes) XML Document (elements vs. attributes) XML and RDBMS XML and RDBMS.
JSP Standard Tag Library
Database Management Systems 3ed, R. Ramakrishnan and J. Gehrke1 XML Taken from Chapter 7.
©Silberschatz, Korth and Sudarshan5.1Database System Concepts Chapter 5: Other Relational Languages Query-by-Example (QBE) Datalog.
Lecture 21 XML querying. 2 XSL (eXtensible Stylesheet Language) In HTML, default styling is built into browsers as tag set for HTML is predefined and.
Copyright © 2012 Accenture All Rights Reserved.Copyright © 2012 Accenture All Rights Reserved. Accenture, its logo, and High Performance Delivered are.
Dr. Azeddine Chikh IS446: Internet Software Development.
XML CPSC 315 – Programming Studio Fall 2008 Project 3, Lecture 1.
VICTORIA UNIVERSITY OF WELLINGTON Te Whare Wananga o te Upoko o te Ika a Maui SWEN 432 Advanced Database Design and Implementation An Introduction to XQuery.
XML BIS4430 – unit 10. XML Origins Extensible Markup Language (XML) 1998 Inspired by Standard Generalized Markup Language (SGML) and HTML. SGML defines.
1 CIS336 Website design, implementation and management (also Semester 2 of CIS219, CIS221 and IT226) Lecture 6 XSLT (Based on Møller and Schwartzbach,
Chapter 27 The World Wide Web and XML. Copyright © 2004 Pearson Addison-Wesley. All rights reserved.27-2 Topics in this Chapter The Web and the Internet.
XQL, OQL and SQL Xia Tang Sixin Qian Shijun Shen Feb 18, 2000.
XML A web enabled data description language 4/22/2001 By Mark Lawson & Edward Ryan L’Herault.
1 XSLT An Introduction. 2 XSLT XSLT (extensible Stylesheet Language:Transformations) is a language primarily designed for transforming the structure of.
JSTL, XML and XSLT An introduction to JSP Standard Tag Library and XML/XSLT transformation for Web layout.
CIS 451: XML DTDs Dr. Ralph D. Westfall February, 2009.
1 What Is XML? eXtensible Markup Language for data –Standard for publishing and interchange –“Cleaner” SGML for the Internet Applications: –Data exchange.
Lecture 6: XML Query Languages Thursday, January 18, 2001.
Database Systems Part VII: XML Querying Software School of Hunan University
[ Part III of The XML seminar ] Presenter: Xiaogeng Zhao A Introduction of XQL.
JSTL The JavaServer Pages Standard Tag Library (JSTL) is a collection of useful JSP tags which encapsulates core functionality common to many JSP applications.
Sheet 1 DocEng’03, Grenoble, November 2003 Model Driven Architecture based XML Processing Ivan Kurtev, Klaas van den Berg University of Twente, the Netherlands.
Practical RDF Chapter 10. Querying RDF: RDF as Data Shelley Powers, O’Reilly SNU IDB Lab. Hyewon Lim.
Personal Project. Topic Modeling and Presenting Data from a Publication Objectives –Using XML related techniques to model and present data from a publication.
XML e X tensible M arkup L anguage (XML) By: Albert Beng Kiat Tan Ayzer Mungan Edwin Hendriadi.
Introduction to XML XML – Extensible Markup Language.
XML Query: xQuery Reference: Xquery By Priscilla Walmsley, Published by O’Reilly.
XPath --XML Path Language Motivation of XPath Data Model and Data Types Node Types Location Steps Functions XPath 2.0 Additional Functionality and its.
Semi-structured Data In many applications, data does not have a rigidly and predefined schema: –e.g., structured files, scientific data, XML. Managing.
Visual Basic 2010 How to Program © by Pearson Education, Inc. All Rights Reserved.
XML Schema – XSLT Week 8 Web site:
1 XSL Transformations (XSLT). 2 XSLT XSLT is a language for transforming XML documents into XHTML documents or to other XML documents. XSLT uses XPath.
임 순 범 숙명여대 정보과학부 멀티미디어학과 1 III. XML-QL 멀티미디어 데이터베이스 ( ~11.1)
1 XSLT XSLT (extensible stylesheet language – transforms ) is another language to process XML documents. Originally intended as a presentation language:
Querying and Transforming XML Data
XML Data Introduction, Well-formed XML.
XML Data DTDs, IDs & IDREFs.
eXtensible Markup Language (XML)
Alin Deutsch, University of Pennsylvania Mary Mernandez, AT&T Labs
2/18/2019.
CSE591: Data Mining by H. Liu
Semi-structured Data In many applications, data does not have a rigidly and predefined schema: e.g., structured files, scientific data, XML. Managing such.
More XML XML schema, XPATH, XSLT
Presentation transcript:

XML-QL A Query Language for XML Charuta Nakhe

Querying XML document  What is a query language?  Why not adapt SQL or OQL to query XML data?  What is an XML query? What is the database? -- XML documents What is input to the query? – XML document What is the output of the query? – XML document

Requirements of XML query language  Query operations :  Selection: eg. Find books with “S. Sudarshan” as author  Extraction: eg. Extract the publisher field of above books  Restructuring : Restructuring of elements  Combination : Queries over more than one documents  Must be able to transform & create XML structures  Capability for querying even in absence of schema

The XML-QL language  The XML-QL language is designed with the following features: it is declarative, like SQL. it is relational complete, e.g. it can express joins. it can be implemented with known database techniques. it can extract data from existing XML documents and construct new XML documents.  XML-QL is implemented as a prototype and is freely available in a Java version.

Example XML document Inside COM Dale Rogerson Microsoft Database system concepts S. Sudarshan H. Korth McGrawHill

Matching data using patterns Find those authors who have published books for McGraw Hill: WHERE McGraw Hill $t $a IN “bib.xml” CONSTRUCT $t $a the $t and $a are variables that pick out contents. the output is a collection of author names.

Result XML document Database system concepts S. Sudarshan Database system concepts H. Korth

Grouping with Nested Queries Group results by book title : WHERE $p IN “bib.xml”, $t McGraw Hill IN $p CONSTRUCT $t WHERE $a IN $p CONSTRUCT $a Produces one result for each title and contains a list of all its authors

Result XML document Database system concepts S. Sudarshan H. Korth.

Constructing XML data  Results of a query can be wrapped in XML: WHERE McGrawHill $t $a IN “bib.xml” CONSTRUCT $a $t Results are grouped in elements. The pattern matches once for each author, which may give duplicates of books.

Joining elements by value Find all articles that have at least one author who has also written a book since 1995 : WHERE $n I CONTENT_AS $a IN “bib.xml”, $n IN “bib.xml”, y > 1995 CONSTRUCT $a CONTENT_AS $a following a pattern binds the content of the matching element to the variable $a

Tag variables Find all publications in 1995 where Smith is either an author or editor : WHERE $t 1995 Smith IN “bib.xml”, $e IN {author, editor} CONSTRUCT $t Smith $p matches book and article. $e matches author and editor.

Regular-path expressions Find the name of every part element that contains a brand element equal to “Ford”, regardless of the nesting level at which r occurs. WHERE $r Ford IN “bib.xml” CONSTRUCT $r Regular path expressions can specify element paths of arbitrary depth

Other interesting features  Constructing explicit root element  Grouping of data  Transforming XML data  Integrating data from different XML sources

Links for more information  : The XML-QL W3C Note  : The XML-QL home page  : The XML Query Working Group  : XML Query Requirements (W3C Working Draft)  : Robin Cover's page on XML query languages

Example DTD

Creating an explicit root element  Every XML document must have a single root. XML-QL supplies an element as default, but others may be specified: CONSTRUCT { WHERE McGrawHill $t $a IN “bib.xml” CONSTRUCT $a $t }