Strongly-Normalizing Higher-Order Relational Queries
Wilmer Ricciotti, James Cheney

TL;DR
This paper proves strong normalization for higher-order relational queries, ensuring their reliable translation to SQL, and extends existing proof techniques to handle query duplication and heterogeneity.
Contribution
It provides the first strong normalization proof for higher-order relational query calculus, including handling duplication and mixed semantics, filling a key theoretical gap.
Findings
Established strong normalization for higher-order relational queries.
Extended proof techniques to handle duplication in rewrite rules.
Applied proof to heterogeneous set and multiset query calculus.
Abstract
Language-integrated query is a powerful programming construct allowing database queries and ordinary program code to interoperate seamlessly and safely. Language-integrated query techniques rely on classical results about the nested relational calculus, stating that its queries can be algorithmically translated to SQL, as long as their result type is a flat relation. Cooper and others advocated higher-order nested relational calculi as a basis for language-integrated queries in functional languages such as Links and F#. However, the translation of higher-order relational queries to SQL relies on a rewrite system for which no strong normalization proof has been published: a previous proof attempt does not deal correctly with rewrite rules that duplicate subterms. This paper fills the gap in the literature, explaining the difficulty with a previous proof attempt, and showing how to extend…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
