ABSTRACT
Modern database systems provide not only powerful data models but also complex query languages supporting powerful features such as the ability to create new database objects and invocation of arbitrary methods (possibly written in a third-party programming language).In this sense query languages have evolved into powerful programming languages. Surprisingly little work exists utilizing techniques from programming language research to specify and analyse these query languages. This paper provides a formal, high-level operational semantics for a complex-value OQL-like query language that can create fresh database objects, and invoke external methods. We define a type system for our query language and prove an important soundness property.We define a simple effect typing discipline to delimit the computational effects within our queries. We prove that this effect system is correct and show how it can be used to detect cases of non-determinism and to define correct query optimizations.
- S. Abiteboul and P. Kanellakis. Object identity as a query language primitive. Journal of the ACM, 45(5):798--842, 1999.]] Google ScholarDigital Library
- S. Alagić. Type-checking OQL queries in the ODMG type systems. ACM TODS, 24(3):319--360, 1999.]] Google ScholarDigital Library
- M. Andries, L. Cabibbo, J. Paredaens, and J. Van den Bussche. Applying an update method to a set of receivers. ACM TODS, 26(1):1--40, 2001.]] Google ScholarDigital Library
- M. Carey and D. DeWitt. Of objects and databases: A decade of turmoil. In Proceedings of VLDB, 1996.]] Google ScholarDigital Library
- S. Cluet and G. Moerkotte. Nested queries in object bases. In Proceedings of Workshop on Database Programming Languages, pages 226--242, 1993.]] Google ScholarDigital Library
- C.J. Date. Some principles of good language design. ACM SIGMOD Record, 14(3):1--7, 1984.]] Google ScholarDigital Library
- J. Van den Bussche and D. Van Gucht. A semideterministic approach to object creation and nondeterminism in database queries. Journal of Computer and System Sciences, 54(1):34--47, 1997.]]Google ScholarDigital Library
- R.G.G. Cattell et al. The Object Data Standard: ODMG 3.0. Morgan Kaufmann, 2000.]] Google ScholarDigital Library
- L. Fegaras. Optimizing queries with object updates. Journal of Intelligent Information Systems, 12(2--3):219--242, 1999.]] Google ScholarDigital Library
- L. Fegaras and D. Maier. Optimizing object queries using an effective calculus. ACM TODS, 25(4):457--516, 2000.]] Google ScholarDigital Library
- D. Gifford and J. Lucassen. Integrating functional and imperative programming. In ACM Conference on Lisp and Functional Programming, 1986.]] Google ScholarDigital Library
- A. Gordon, P. Hankin, and S. Lassen. Compilation and equivalence of imperative objects. Journal of Functional Programming, 9(4):373--426, 1999.]] Google ScholarDigital Library
- A. Gordon and D. Syme. Typing a multilanguage intermediate code. In Proceedings of POPL, 2001.]] Google ScholarDigital Library
- A. Greenhouse and J. Boyland. An object-oriented effects system. In Proceedings of ECOOP, 1999.]] Google ScholarDigital Library
- J. Hellerstein. Optimization techniques for queries with expensive methods. ACM TODS, 23(2):113--157, 1998.]] Google ScholarDigital Library
- A. Igarashi, B.C. Pierce, and P. Wadler. Featherweight Java: A minimal core calculus for Java and GJ. ACM Transactions on Programming Languages and Systems, 23(3):396--450, 2001.]] Google ScholarDigital Library
- H. Liefke and S. Davidson. Updates and nondeterminism in object-oriented databases. Technical Report MS-CIS-99-11, University of Pennsylvania, 1999.]]Google Scholar
- R. Milner, M. Tofte, R. Harper, and D. MacQueen. The Definition of Standard ML. MIT Press, 1997.]] Google ScholarDigital Library
- G. Mitchell, S. Zdonik, and U. Dayal. Object-oriented query optimization: what's the problem? Technical Report CS-91-41, Brown University, 1991.]] Google ScholarDigital Library
- T. Nipkow and D. von Oheimb. Javalight is type-safe---definitely. In Proceedings of POPL, 1998.]] Google ScholarDigital Library
- H. Riedell and M.H. Scholl. The CROQUE model: Formalization of the data model and the query language. Technical Report 23, University of Konstänz, 1996.]]Google Scholar
- P. Seshadri and M. Paskin. PREDATOR: An OR-DBMS with enhanced data types. In Proceedings of ACM SIGMOD, pages 568--571, 1997.]] Google ScholarDigital Library
- A. Trigoni and G.M. Bierman. Inferring the principal type and schema requirements of an OQL query. In Proceedings of BNCOD, 2001.]] Google ScholarDigital Library
- G. Winskel. The Formal Semantics of Programming Languages: An Introduction. MIT Press, 1993.]] Google ScholarDigital Library
- A. Wright and M. Felleisen. A syntactic approach to type soundness. Information and Computation, 115(1):38--94, 1994.]] Google ScholarDigital Library
- XQuery 1.0 formal semantics. Working draft June 2001.]]Google Scholar
Index Terms
- Formal semantics and analysis of object queries
Recommendations
Equivalence of formal semantics definition methods
AbstractThere are numerous methods of formally defining the semantics of computer languages. Each method has been designed to fulfil a different purpose. For example, some have been designed to make reasoning about languages as easy as possible; others ...
Equivalence and minimization of conjunctive queries under combined semantics
ICDT '12: Proceedings of the 15th International Conference on Database TheoryThe problems of query containment, equivalence, and minimization are fundamental problems in the context of query processing and optimization. In their classic work [2] published in 1977, Chandra and Merlin solved the three problems for the language of ...
Formal semantics of a SNOBOL4 subset
The Vienna Definition Language is used to formally define the semantics of a basic but useful subset of SNOBOL4. A brief, informal description of the subset is given, and its concrete syntax and abstract syntax are defined formally. The structure of an ...
Comments