1 The T4SQL Temporal Query Language Presented by 黃泰豐 2007/12/26.

Slides:



Advertisements
Similar presentations
Relational Database and Data Modeling
Advertisements

Extending Temporal Databases to Deal with Telic/Atelic Medical Data Paolo Terenziani 1, Richard T. Snodgrass 2, Alessio Bottrighi 1, Mauro Torchio 3, Gianpaolo.
Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 5 More SQL: Complex Queries, Triggers, Views, and Schema Modification.
From Handbook of Temporal Reasoning in Artificial Intelligence By Jan Chomicki & David Toman Temporal Databases Presented by Leila Jalali CS224 presentation.
Relational Database. Relational database: a set of relations Relation: made up of 2 parts: − Schema : specifies the name of relations, plus name and type.
1 3D_XML A three-Dimensional XML-based Model Khadija Ali, Jaroslav Pokorný Czech Technical University Prague - Czech Republic.
BCDM Temporal Domains - Time is linear and totally ordered - Chronons are the basic time unit - Time domains are isomorphic to subsets of the domain of.
Advanced Databases Temporal Databases Dr Theodoros Manavis
Time in Databases CSCI 6442 With thanks to Richard Snodgrass, 1985 ACM /85/005/0236.
Recording / Financing Fixed Asset Acquisition Human Resources Purchasing Revenue Traditional files approach: separate systems Expenditure Cycles Reporting.
Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 3 The Basic (Flat) Relational Model.
Firewall Policy Queries Author: Alex X. Liu, Mohamed G. Gouda Publisher: IEEE Transaction on Parallel and Distributed Systems 2009 Presenter: Chen-Yu Chang.
CS240A: Databases and Knowledge Bases A Taxonomy of Temporal DBs Carlo Zaniolo Department of Computer Science University of California, Los Angeles.
Temporal Databases. Outline Spatial Databases Indexing, Query processing Temporal Databases Spatio-temporal ….
Recording / Financing Fixed Asset Acquisition Human Resources Purchasing Revenue Traditional files approach: separate systems (Legacy Systems) Expenditure.
Database Systems More SQL Database Design -- More SQL1.
1 Augmenting MatML with Heat Treating Semantics Aparna Varde, Elke Rundensteiner, Murali Mani Mohammed Maniruzzaman and Richard D. Sisson Jr. Worcester.
Methodology Conceptual Database Design
Advanced Database CS-426 Week 13 – Object Relational Databases.
Working with SQL and PL/SQL/ Session 1 / 1 of 27 SQL Server Architecture.
ONTOLOGY SUPPORT For the Semantic Web. THE BIG PICTURE  Diagram, page 9  html5  xml can be used as a syntactic model for RDF and DAML/OIL  RDF, RDF.
Information storage: Introduction of database 10/7/2004 Xiangming Mu.
DBSQL 10-1 Copyright © Genetic Computer School 2009 Chapter 10 Object-Oriented Based DBMS.
CSE314 Database Systems More SQL: Complex Queries, Triggers, Views, and Schema Modification Doç. Dr. Mehmet Göktürk src: Elmasri & Navanthe 6E Pearson.
Chapter 6: Foundations of Business Intelligence - Databases and Information Management Dr. Andrew P. Ciganek, Ph.D.
Chapter 9 Designing Databases Modern Systems Analysis and Design Sixth Edition Jeffrey A. Hoffer Joey F. George Joseph S. Valacich.
A Z Approach in Validating ORA-SS Data Models Scott Uk-Jin Lee Jing Sun Gillian Dobbie Yuan Fang Li.
6 Chapter Databases and Information Management. File Organization Terms and Concepts Bit: Smallest unit of data; binary digit (0,1) Byte: Group of bits.
Topic 5 The Relational Data Model and Relational Database Constraints Faculty of Information Science and Technology Mahanakorn University of Technology.
Instructor: Churee Techawut Basic Concepts of Relational Database Chapter 5 CS (204)321 Database System I.
DatabaseIM ISU1 Fundamentals of Database Systems Chapter 5 The Relational Data Model.
Recent research : Temporal databases N. L. Sarda
DATA-DRIVEN UNDERSTANDING AND REFINEMENT OF SCHEMA MAPPINGS Data Integration and Service Computing ITCS 6010.
Database System Concepts, 6 th Ed. ©Silberschatz, Korth and Sudarshan See for conditions on re-usewww.db-book.com Chapter 2: Intro to Relational.
Chapter 2 Adapted from Silberschatz, et al. CHECK SLIDE 16.
10/17/2012ISC471/HCI571 Isabelle Bichindaritz 1 Technologies Databases.
Object Persistence (Data Base) Design Chapter 13.
1 Relational Databases and SQL. Learning Objectives Understand techniques to model complex accounting phenomena in an E-R diagram Develop E-R diagrams.
Slide Chapter 5 The Relational Data Model and Relational Database Constraints.
Databases Shortfalls of file management systems Structure of a database Database administration Database Management system Hierarchical Databases Network.
6.1 © 2010 by Prentice Hall 6 Chapter Foundations of Business Intelligence: Databases and Information Management.
IS 230Lecture 6Slide 1 Lecture 7 Advanced SQL Introduction to Database Systems IS 230 This is the instructor’s notes and student has to read the textbook.
Chapter 2 Introduction to Relational Model. Example of a Relation attributes (or columns) tuples (or rows) Introduction to Relational Model 2.
Chapter 2: Intro to Relational Model. 2.2 Example of a Relation attributes (or columns) tuples (or rows)
Database Management Supplement 1. 2 I. The Hierarchy of Data Database File (Entity, Table) Record (info for a specific entity, Row) Field (Attribute,
CSE314 Database Systems Lecture 3 The Relational Data Model and Relational Database Constraints Doç. Dr. Mehmet Göktürk src: Elmasri & Navanthe 6E Pearson.
1 Resolving Schematic Discrepancy in the Integration of Entity-Relationship Schemas Qi He Tok Wang Ling Dept. of Computer Science School of Computing National.
Issues in Ontology-based Information integration By Zhan Cui, Dean Jones and Paul O’Brien.
1 MedAT: Medical Resources Annotation Tool Monika Žáková *, Olga Štěpánková *, Taťána Maříková * Department of Cybernetics, CTU Prague Institute of Biology.
Chapter 5 : Integrity And Security  Domain Constraints  Referential Integrity  Security  Triggers  Authorization  Authorization in SQL  Views 
Session 1 Module 1: Introduction to Data Integrity
Concepts and Realization of a Diagram Editor Generator Based on Hypergraph Transformation Author: Mark Minas Presenter: Song Gu.
A Portrait of the Semantic Web in Action Jeff Heflin and James Hendler IEEE Intelligent Systems December 6, 2010 Hyewon Lim.
Temporal Data Modeling
CS240A: Databases and Knowledge Bases TSQL2 Carlo Zaniolo Department of Computer Science University of California, Los Angeles Notes From Chapter 6 of.
Toward Entity Retrieval over Structured and Text Data Mayssam Sayyadian, Azadeh Shakery, AnHai Doan, ChengXiang Zhai Department of Computer Science University.
Chap4 Temporal Database Chap 4: Temporal Extensions to the Relational Model and SQL.
CPT-S Advanced Databases 11 Yinghui Wu EME 49.
Introduction to Core Database Concepts Getting started with Databases and Structure Query Language (SQL)
LECTURE TWO Introduction to Databases: Data models Relational database concepts Introduction to DDL & DML.
Database Management Systems 3ed, R. Ramakrishnan and J. Gehrke1 The Relational Model Chapter 3.
SPECIAL PURPOSE DATABASES 13/09/ Temporal Database Concepts  Time is considered ordered sequence of points in some granularity Use the term choronon.
1 Section 1 - Introduction to SQL u SQL is an abbreviation for Structured Query Language. u It is generally pronounced “Sequel” u SQL is a unified language.
More SQL: Complex Queries, Triggers, Views, and Schema Modification
More SQL: Complex Queries,
Temporal Databases.
More SQL: Complex Queries, Triggers, Views, and Schema Modification
Author: Miran Miklič Comparison and advantages of the Bitemporal and Temporal databases over Tuple-versioning (point-in-time) database.
CS240A: Databases and Knowledge Bases TSQL2
CS240A: Databases and Knowledge Bases A Taxonomy of Temporal DBs
Presentation transcript:

1 The T4SQL Temporal Query Language Presented by 黃泰豐 2007/12/26

2 Referenced Paper  Carlo Combi, Angelo Montanari, and Giuseppe Pozzi. The T4SQL Temporal Query Language. ACM CIKM 2007 Sixteenth Conference on Information and Knowledge Management. Pages , Lisbon, Portugal, Nov

3 Outline  Introduction  Related Work  Data Model with Multiple Temporal Dimensions  T4SQL  Conclusions & Future Work

4 Introduction  a new temporal query language, called T4SQL, supporting multiple temporal dimensions of data  Besides the well-known valid and transaction times, it encompasses two additional temporal dimensions, availability and event times.  T4SQL is capable to deal with different temporal semantics with respect to every temporal dimension.

5 Related Work  TSQL2 * supports both VT (valid time) and TT (transaction time).  It minimizes the syntactical changes from SQL.  It covers most features of existing temporal query languages, and it introduces some original elements. *Richard T. Snodgrass, editor. The TSQL2 Temporal Query Language. Kluwer, 1995.

6 Related Work (cont ’ d)  A new component, called SQL/Temporal, was formally approved in July 1995 as part of the SQL3 draft standard and then withdrawn.  The SQL3 SQL/Temporal component temporally extends the basic relational model by adding the data type PERIOD and the two temporal dimensions VT and TT, and it supports temporal queries.

7 Data Model with Multiple Temporal Dimensions  Temporal Dimensions of Data 1)The valid time records when a given information is valid in the application domain. 2)The transaction time records when the information has been entered, modified, or removed from the database.

8 Two Additional Temporal Dimensions 3)The availability time records when the information is known and treated as true by the information system. 4)The event time records the occurrence times of both the event that starts the validity time and the event that ends it.

9 The T4SQL Data Model  The T4SQL data model is a straightforward extension of the relational model, where every relation is equipped with the four temporal dimensions.  VT, TT, and AT are represented as intervals, while ET is represented by a pair of attributes, that respectively record the occurrence time of the initiating event and of the terminating one.

10 Key Constraint  Given a temporal relation R, defined on a set of (atemporal) attributes X and the special attributes VT, TT, AT, ETi, and ETt, and a set K ⊆ X.  K is a snapshot key for R if the following conditions hold: ∀ a ∈ K (t[a] != null) ∀ t1, t2 ((t1[VT,TT,AT] ∩ t2[VT,TT,AT] != ∅ ∧ t1 != t2) ⇒ t1[K] != t2[K])

11 The Query Language T4SQL  The Clause SEMANTICS T4SQL enables the user to specify different semantics for different temporal dimensions as follows:  SEMANTICS [ON] [[TIMESLICE] ] {, [ON] [[TIMESLICE] ]} Where specifies the semantics to apply to the temporal dimension. The item is a constant either of type PERIOD or of type DATE.

12 Four Types of Semantics 1)ATEMPORAL Semantics If the ATEMPORAL semantics is adopted, the corresponding attribute(s) is considered as atemporal (timeless).

13 Example  to retrieve all the patients for which the symptom “ Fever ” has never been observed SEMANTICS ATEMPORAL ON VALID SELECT PatId FROM PatSymptom ps WHERE ps.PatId NOT IN ( SEMANTICS ATEMPORAL ON VALID SELECT PatId FROM PatSymptom WHERE Symptom = ‘ Fever ’ )

14 2) CURRENT Semantics  When applied to a temporal dimension d, the CURRENT semantics selects all and only those tuples t such that the current date belongs to t[d].

15 Example  to retrieve all the patients from the relation PatSymptom as currently stored SEMANTICS CURRENT ON TRANSACTION ATEMPORAL ON VALID SELECT PatId FROM PatSymptom

16 3) SEQUENCED Semantics  When the SEQUENCED semantics is adopted, T4SQL only considers combinations of tuples from the relations in the FROM clause with overlapping time intervals.

17 Example  to retrieve patients who suffered from fever on the basis of what the database in its current state believed correct on December 1st, 2006 SEMANTICS SEQUENCED ON VALID, CURRENT ON TRANSACTION, SEQUENCED ON AVAILABLE TIMESLICE PERIOD ‘ [ ] ’ SELECT PatId FROM PatSymptom WHERE Symptom = ‘ Fever ’

18 4) NEXT Semantics  The NEXT semantics takes into consideration only pairs of tuples related to the same entity (i.e., pairs of tuples of a given relation with the same snapshot key) and selects those pairs which are consecutive with respect to the temporal ordering.

19 Example  to retrieve for every patient the time period elapsed between two consecutive administrations of the same drug SEMANTICS NEXT ON VALID SELECT PatId, Therapy, (BEGIN(VALID(NEXT(pt)))- END(VALID(pt))) DAY FROM PatTherapy AS pt

20 The Clause SELECT  To separate atemporal attributes from temporal ones, T4SQL uses the token WITH in the SELECT clause.  The syntax of the T4SQL SELECT clause is: SELECT [WITH [AS] {, [AS] }]

21 Example  To retrieve the patients who suffered from the symptom ‘ Fever ’, received the drug ‘ Paracetamol ’, and solved their disease within 5 days from the beginning of the therapy SEMANTICS SEQUENCED ON VALID SELECT PatId WITH PERIOD (BEGIN(VALID(ps)), END(VALID(pt))) AS VALID FROM PatSymptom AS ps, PatTherapy AS pt WHERE ps.Symptom = ‘ Fever ’ AND pt.Therapy = ‘ Paracetamol ’ AND ps.PatId = pt.PatId AND (END(VALID(ps)) - BEGIN(VALID(pt))) DAY < INTERVAL ‘ 5 ’ DAY

22 Conclusions  To propose a new query language, called T4SQL, that operates on multidimensional temporal relations  T4SQL allows one to query temporal relations provided with (a subset of) the temporal dimensions of valid, transaction, availability, and event time, according to different semantics.

23 Future Work  To explore some techniques for translating T4SQL queries into efficient SQL queries  To extend the temporal data model by data definition and data management capabilities