Coalescing in Temporal Databases

Coalescing is a unary operator applicable to temporal databases; it is similar to duplicate elimination in conventional databases. Tuples in a temporal relation that agree on the explicit attribute values and that have adjacent or overlapping time periods are candidates for coalescing. Uncoalesced relations can arise in many ways, e.g., via a projection or union operator, or by not enforcing coalescing on update or insertion. In this paper we show how semantically superfluous coalescing can be eliminated. We then turn to efficiently performing coalescing. We sketch a variety of iterative and non-iterative approaches, via SQL and embedded SQL, demonstrating that coalescing can be formulated in SQL-89. Detailed performance studies show that all such approaches are quite expensive. We propose a spectrum of coalescing algorithms within a DBMS, based on nested-loop, explicit partitioning, explicit sorting, temporal sorting, temporal partitioning, and combined explicit/temporal sorting, and summarize a performance study involving a subset of these algorithms. The study shows that coalescing can be implemented with reasonable efficiency, and with modest development cost. Permission to copy without fee all or part of this material is granted provided that the copies are not made or distributed for direct commercial advantage, the VLDB copyright notice and the title of the publication and its date appear, and notice is given that copying is by permission of the Very Large Data Base Endowment. To copy otherwise, or to republish, requires a fee and/or special permission from the Endowment. Proceedings of the 22nd VLDB Conference Mumbai(Bombay), India, 1996 Name Title Ron President [1981,~~,Z~~~98~,~~,~~~ Ron President [1985/01/20~1989/01/20) Figure 1: Uncoalesced Valid-Time Relation

[1]  llsoo Ahn,et al.  Temporal Databases , 1986, Computer.

[2]  Richard T. Snodgrass,et al.  The temporal query language TQuel , 1987, TODS.

[3]  Alan R. Simon,et al.  Understanding the New SQL: A Complete Guide , 1993 .

[4]  Joseph M. Hellerstein,et al.  Practical predicate placement , 1994, SIGMOD '94.

[5]  Michael H. Böhlen The Temporal Deductive Database System ChronoLog , 1994 .

[6]  Shashi K. Gadia,et al.  A query language for a homogeneous temporal database , 1985, PODS '85.

[7]  Michael Stonebraker,et al.  Predicate migration: optimizing queries with expensive predicates , 1992, SIGMOD Conference.

[8]  Shamkant B. Navathe,et al.  A Temporal Relational Model and a Query Language , 1989, Inf. Sci..

[9]  Arie Segev,et al.  A glossary of temporal database concepts , 1992, SGMD.

[10]  Shashi K. Gadia,et al.  A homogeneous relational model and query languages for temporal databases , 1988, TODS.

[11]  Shamkant B. Navathe,et al.  Temporal Extensions to the Relational Model and SQL , 1993, Temporal Databases.

[12]  Christian S. Jensen,et al.  An Algebra for TSQL2 , 1995, The TSQL2 Temporal Query Language.

[13]  Richard T. Snodgrass,et al.  The TSQL2 Temporal Query Language , 1995 .

[14]  Joe Celko SQL for Smarties: Advanced SQL Programming , 1995 .

[15]  Suryanarayana M. Sripada Temporal Reasoning in Deductive Databases , 1991 .

[16]  Richard R. Muntz,et al.  Stream Processing: Temporal Query Processing and Optimization , 1993, Temporal Databases.

[17]  Nandlal L. Sarda Algebra and Query Language for A Historical Data Model , 1990, Comput. J..

[18]  Albert Croker,et al.  The historical relational data model (HRDM) and algebra based on lifespans , 1986, 1987 IEEE Third International Conference on Data Engineering.

[19]  Goetz Graefe,et al.  Query evaluation techniques for large databases , 1993, CSUR.

[20]  Jeffrey D. Ullman,et al.  Principles of Database and Knowledge-Base Systems, Volume II , 1988, Principles of computer science series.

[21]  Per-Ake Larson,et al.  Performing Group-By before Join , 1994, ICDE 1994.

[22]  Christian S. Jensen,et al.  Efficient evaluation of the valid-time natural join , 1994, Proceedings of 1994 IEEE 10th International Conference on Data Engineering.

[23]  Richard R. Muntz,et al.  Temporal Query Processing and Optimization in Multiprocessor Database Machines , 1992, VLDB.

[24]  Christian S. Jensen,et al.  Evaluating and Enhancing the Completeness of TSQL2 , 1995 .

[25]  Edwin McKenzie An Algebraic Language for Query and Update of Temporal Databases , 1988 .

[26]  Patrick E. O'Neil,et al.  Database Principles, Programming, Performance , 1994 .

[27]  Jeffrey D. Ullman,et al.  Principles Of Database And Knowledge-Base Systems , 1979 .

[28]  Nikos A. Lorentzos The Interval-extended Relational Model and Its Applications to Valid-time Databases , 1993, Temporal Databases.

[29]  Richard T. Snodgrass,et al.  Evaluation of relational algebras incorporating the time dimension in databases , 1991, CSUR.

[30]  Nandlal L. Sarda,et al.  Extensions to SQL for Historical Databases , 1990, IEEE Trans. Knowl. Data Eng..

[31]  David J. DeWitt,et al.  An Evaluation of Non-Equijoin Algorithms , 1991, VLDB.

[32]  Jacov Ben-Zvi,et al.  The time relational model , 1982 .

[33]  Jan Chomicki,et al.  Querying TSQL2 Databases with Temporal Logic , 1996, EDBT.

[34]  Hamid Pirahesh,et al.  Querying Historical Data in IBM DB2 C/S DBMS Using Recursive SQL , 1995, Temporal Databases.

[35]  Abdullah Uz Tansel,et al.  Adding time dimension to relational model and extending relational algebra , 1986, Inf. Syst..

[36]  Patrick O'Neil Database systems: principles, programming, performance , 1994 .

[37]  Arie Segev,et al.  Join Processing and Optimization in Temporal Relational Databases , 1993, Temporal Databases.

[38]  S. Misbah Deen,et al.  HQL - A Historical Query Language , 1988, BNCOD.

[39]  Richard R. Muntz,et al.  Query processing for temporal databases , 1990, [1990] Proceedings. Sixth International Conference on Data Engineering.

[40]  Arie Segev,et al.  A consensus glossary of temporal database concepts , 1994, SIGMOD 1994.

[41]  Abdullah Uz Tansel,et al.  A Historical query language , 1991, Inf. Sci..

[42]  Elizabeth O'Neil,et al.  Database--Principles, Programming, and Performance , 1994 .

[43]  Joe Celko,et al.  Joe Celko's SQL for smarties: advanced SQL programming (2nd editor) , 1995 .

[44]  Per-Åke Larson,et al.  Exploiting uniqueness in query optimization , 1994, Proceedings of 1994 IEEE 10th International Conference on Data Engineering.

[45]  Gad Ariav,et al.  A temporally oriented data model , 1986, TODS.

[46]  James F. Allen Maintaining knowledge about temporal intervals , 1983, CACM.

[47]  Roger G. Johnson,et al.  Extending relational algebra to manipulate temporal data , 1988, Inf. Syst..

[48]  Michael Stonebraker,et al.  Implementation techniques for main memory database systems , 1984, SIGMOD '84.

[49]  Sushil Jajodia,et al.  Temporal Databases: Theory, Design, and Implementation , 1993 .

[50]  David J. DeWitt,et al.  Duplicate record elimination in large data files , 1983, TODS.