A Practical Theory of Language-integrated Query

Research output: Chapter in Book/Report/Conference proceedingConference contribution


Language-integrated query is receiving renewed attention, in part because of its support through Microsoft's LINQ framework. We present a practical theory of language-integrated query based on quotation and normalisation of quoted terms. Our technique supports join queries, abstraction over values and predicates, composition of queries, dynamic generation of queries, and queries with nested intermediate data. Higher-order features prove useful even for constructing first-order queries. We prove a theorem characterising when a host query is guaranteed to generate a single SQL query. We present experimental results confirming our technique works, even in situations where Microsoft's LINQ framework either fails to produce an SQL query or, in one case, produces an avalanche of SQL queries.
Original languageEnglish
Title of host publicationProceedings of the 18th ACM SIGPLAN International Conference on Functional Programming
Place of PublicationNew York, NY, USA
Number of pages14
ISBN (Print)978-1-4503-2326-0
Publication statusPublished - 2013

Publication series

NameICFP '13


  • antiquotation, f, lambda calculus, linq, quotation, sql


Dive into the research topics of 'A Practical Theory of Language-integrated Query'. Together they form a unique fingerprint.

Cite this