Keys For XML Peter Buneman Susan Davidson Wenfei Fan Carmem Hara Wang Chiew Tan.

Slides:



Advertisements
Similar presentations
Muse: A System for Understanding and Designing Mappings Bogdan Alexe Laura Chiticariu Renée J. Miller Daniel Pepper Wang-Chiew Tan UC Santa Cruz U. of.
Advertisements

XML, XML Schema, Xpath and XQuery Slides collated from various sources, many from Dan Suciu at Univ. of Washington.
1 DTD (Document Type Definition) Imposing Structure on XML Documents (W3Schools on DTDs)W3Schools on DTDs.
Relational Databases for Querying XML Documents: Limitations & Opportunities VLDB`99 Shanmugasundaram, J., Tufte, K., He, G., Zhang, C., DeWitt, D., Naughton,
1 Conditional XPath, the first order complete XPath dialect Maarten Marx Presented by: Einav Bar-Ner.
Merging Models Based on Given Correspondences Rachel A. Pottinger Philip A. Bernstein.
1 XEM: Managing the Evolution of XML Documents Author: Hong Su, Diane Kramer. Li Chen, Kajal Claypool and Elke A. Rundensteiner Presented by: Li Shuhong.
1 Lecture 10 XML Wednesday, October 18, XML Outline XML (4.6, 4.7) –Syntax –Semistructured data –DTDs.
Lecture 14 XML Validation. a simple element containing text attribute; attributes provide additional information about an element and consist of a name.
Conceptual XML for Systems Analysis Reema Al-Kamha PhD Dissertation Defense Supported by NSF.
Validating Streaming XML Documents Luc Segoufin & Victor Vianu Presented by Harel Paz.
Containment and Equivalence for an XPath Fragment By Gerom e Mikla Dan Suciu Presented By Roy Ionas.
1 New Ways of Querying the Web by Eliahu Brodsky and Alina Blizhovsky.
Storing and Querying Ordered XML Using a Relational Database System By Khang Nguyen Based on the paper of Igor Tatarinov and Statis Viglas.
Representation of Web Data in a Web Warehouse Ragini A.S. & Shipra Dutta November 20 th, 2001.
Managing XML and Semistructured Data Lecture 14: Constraints and Keys Prof. Dan Suciu Spring 2001.
XML –Query Languages, Extracting from Relational Databases ADVANCED DATABASES Khawaja Mohiuddin Assistant Professor Department of Computer Sciences Bahria.
1 Keys for XML Peter Buneman, Susan Davidson, Wenfei Fan Carmem Hara, Wang-Chiew Tan Carmem Hara, Wang-Chiew Tan University of Pennsylvania Temple University.
1 Modelling Hachim Haddouti Al Akhawayn University SSE
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.
4/20/2017.
IS432: Semi-Structured Data Dr. Azeddine Chikh. 1. Semi Structured Data Object Exchange Model.
Lecture 15 XML Validation. a simple element containing text attribute; attributes provide additional information about an element and consist of a name.
VICTORIA UNIVERSITY OF WELLINGTON Te Whare Wananga o te Upoko o te Ika a Maui SWEN 432 Advanced Database Design and Implementation Document Type Definition.
XML Anisha K J Jerrin Thomas. Outline  Introduction  Structure of an XML Page  Well-formed & Valid XML Documents  DTD – Elements, Attributes, Entities.
 Copyright 2005 Digital Enterprise Research Institute. All rights reserved. Towards Translating between XML and WSML based on mappings between.
Lecture 6 of Advanced Databases XML Schema, Querying & Transformation Instructor: Mr.Ahmed Al Astal.
Ertan Deniz Instructor.  XML Schema  Document Navigation (Xpath)  Document Transformation (XSLT)
XML Schema and Stylus Studio. Introduction to XML Schema XML Schema defines building blocks of a XML document XML Schemas are alternative to DTD Why XML.
A Z Approach in Validating ORA-SS Data Models Scott Uk-Jin Lee Jing Sun Gillian Dobbie Yuan Fang Li.
Chapter 2 Adapted from Silberschatz, et al. CHECK SLIDE 16.
Of 33 lecture 3: xml and xml schema. of 33 XML, RDF, RDF Schema overview XML – simple introduction and XML Schema RDF – basics, language RDF Schema –
XML Data Management 10. Deterministic DTDs and Schemas Werner Nutt.
RRXS Redundancy reducing XML storage in relations O. MERT ERKUŞ A. ONUR DOĞUÇ
University of Crete Department of Computer Science ΗΥ-561 Web Data Management XML Data Archiving Konstantinos Kouratoras.
Formal Specification of Intrusion Signatures and Detection Rules By Jean-Philippe Pouzol and Mireille Ducassé 15 th IEEE Computer Security Foundations.
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.
More XML: semantics, DTDs, XPATH February 18, 2004.
Management of XML and Semistructured Data Lecture 10: Schemas Monday, April 30, 2001.
The Semistructured-Data Model Programming Languages for XML Spring 2011 Instructor: Hassan Khosravi.
A Quick Math Overview (not the last one!) Section 1.4, you should it read carefully! Reading the corresponding material from the book is strongly encouraged.
Database Systems (Atzeni, Ceri, Paraboschi, Torlone) Chapter 3 : Relational algebra and calculus McGraw-Hill and Atzeni, Ceri, Paraboschi, Torlone 1999.
CS 157B: Database Management Systems II February 11 Class Meeting Department of Computer Science San Jose State University Spring 2013 Instructor: Ron.
Unit 3 — Advanced Internet Technologies Lesson 11 — Introduction to XSL.
Description of Information Resources: RDF/RDFS (an Introduction)
Deriving Relation Keys from XML Keys by Qing Wang, Hongwei Wu, Jianchang Xiao, Aoying Zhou, Junmei Zhou Reviewed by Chris Ying Zhu, Cong Wang, Max Wang,
XML Validation. a simple element containing text attribute; attributes provide additional information about an element and consist of a name value pair;
Grouping Robin Burke ECT 360. Outline Extra credit Numbering, revisited Grouping: Sibling difference method Uniquifying in XPath Grouping: Muenchian method.
Grouping Robin Burke ECT 360. Outline Grouping: Sibling difference method Uniquifying in XPath Grouping: Muenchian method Generated ids Keys Moded Templates.
Efficient Discovery of XML Data Redundancies Cong Yu and H. V. Jagadish University of Michigan, Ann Arbor - VLDB 2006, Seoul, Korea September 12 th, 2006.
C Copyright © 2011, Oracle and/or its affiliates. All rights reserved. Introduction to XML Standards.
LDK R Logics for Data and Knowledge Representation Description Logics: family of languages.
SEMI-STRUCTURED DATA (XML) 1. SEMI-STRUCTURED DATA ER, Relational, ODL data models are all based on schema Structure of data is rigid and known is advance.
XML Extensible Markup Language
1 The Relational Data Model David J. Stucki. Relational Model Concepts 2 Fundamental concept: the relation  The Relational Model represents an entire.
CITA 330 Section 4 XML Schema. XML Schema (XSD) An alternative industry standard for defining XML dialects More expressive than DTD Using XML syntax Promoting.
Modified Slides from Dr.Peter Buneman 1 XML Constraints Constraints are a fundamental part of the semantics of the data; XML may not come with a DTD/type.
1 Representing and Reasoning on XML Documents: A Description Logic Approach D. Calvanese, G. D. Giacomo, M. Lenzerini Presented by Daisy Yutao Guo University.
Unit 4 Representing Web Data: XML
Management of XML and Semistructured Data
Chapter 7 Representing Web Data: XML
XML Data Introduction, Well-formed XML.
Semi-Structured data (XML Data MODEL)
CMPT 354: Database System I
Lecture 9: XML Monday, October 17, 2005.
DTD (Document Type Definition)
XML Constraints Constraints are a fundamental part of the semantics of the data; XML may not come with a DTD/type – thus constraints are often the only.
Logics for Data and Knowledge Representation
Semi-Structured data (XML)
Lecture 11: XML and Semistructured Data
Presentation transcript:

Keys For XML Peter Buneman Susan Davidson Wenfei Fan Carmem Hara Wang Chiew Tan

Overview Motivation Definition of Keys Examples of Keys Value Equality Relative Keys Examples of Relative Keys Stronger Keys Examples of Stronger Keys Advantages Disadvantages Conclusion

Motivation Keys are used for citing parts of a document that is important Defects of XPath 1. Complex 2. Technical problems 3. Questions about the equivalence of XPath expressions

In the absence of keys the only way to identify a tuple is to give the entire tuple Smith Math2 - Jones Math2

Definition of Keys Key Specification is a pair (Q,{P 1,..., P n }) where Q is a path expression and {P 1,..., P n } is a set of simple path expressions. Path expression Q identifies a set of nodes target set on which the key constraint is to hold Set {P 1,..., P n } as the key paths. Example (person.employees, {name.firstname, name.lastname})

Formal Definition. A node n satisfies a key specification (Q,{P 1,..., P k }) if for any n1, n2 in n[[Q]], if for all, 1 <=i<= k, there exist z1 belonging to n1[[P i ]] and z2 belonging to n2[[P i ]] such that z 1 = v z 2, then n1 = n2. = v stands for value equality

Value Equality. Stands for equality of the "values" associated with nodes In XML schema nodes may have complex structure Example name may have a complex structure consisting of first-name and last-name subelements

Examples of Keys (_*.person, {id}) Any person element, if it has id subelements, is uniquely identified by the values of the id's. (person, {e}) Any two person nodes immediately under the root have different values (e is the empty path).

(employees, {}) An empty key. This means that the path employees, if it exists, is unique at the root. That is, there is at most one employees node immediately under the root. (_*,{id}) Any element that has id subelements is uniquely identified by the values of the id's

Relative Keys A document satisfies a relative key specification (Q, (Q',S)) if for all nodes n in [[Q]], n satisfies the key (Q',S). (Q, K) is a relative key if K is a key for every "sub- document" rooted at a node in [[Q]].

Examples of Relative Keys (bible.book.chapter, (verse, {number})) A verse number uniquely identifies a verse within a chapter. (bible.book, (chapter, {number})) Chapter numbers uniquely identify a chapter within a book. (bible, (book, {name})) If there is only one bible node immediately under the root, this is the same as specifying a key ( , (bible,{}))

Notation for relative keys The basic syntactic form is Q 1 {P1,...,P k 1 }.Q 2 {P1,...,Pk 2 }.....Q n {P1,...,Pk n } Example bible{}.book{name}.chapter{number}.verse{number }

Specifies:- ( , (bible,{})) (bible, (book, {name})) (bible.book, (chapter, {number})) (bible.book.chapter, (verse, {number}))

Stronger Keys The definition of keys we have adopted in this paper is quite weak To mirror the requirements imposed by a key in relational databases 1. Uniqueness of a key and 2. Equality of key values.

Definition. A node n satisfies a key specification (Q,{P 1,..., P k }) if for all n' in n[[Q]] and for all P i (1<= i<= k), P i is unique at n'. For any n 1, n 2 in n[[Q]], if n 1 [[P i ]] = v n 2 [[P i ]] (1<=i<= k) then n 1 = n 2.

Examples of Stronger Keys (_*.person, {id}) Any two person elements, no matter where they occur, have unique id subelements and differ on those elements. (person, {  }) The interpretation of this key remains unchanged under a strong key semantics.

(employees, {}) Again, the semantics of this key is the same with respect to the strong and weak key specifications. (_*,{k}) This requires that every element has a key k, including any element whose name is k.

Advantages More generic than XML schema. There is no direct notion of a relative key in XML- Schema but it is covered in this paper. The paper covers any alternative XML representations. 1. Tags expressed as attributes. 2. Introduce new type

Disadvantages Definition of target set :- XML Schema is from any arbitrary point where as this paper is from specific point Definition of key paths. There is no general method of checking whether two such specifications are equivalent in the proposal

In defining a key (Q,{P 1,..., P n }), the language used to describe the target path Q needs to be the same as the language used to define the key paths P 1,..., P n. One could choose a simpler language for key paths that is a sublanguage of the language for target paths.

Conclusion More generic way of representing keys The paper takes care of setbacks of XPath