The essence of language-integrated query

James Cheney, Sam Lindley, Philip L. Wadler · 2013

Language-integrated query is receiving renewed attention, in part because of its support through Microsoft’s LINQ framework. We present a theory of language-integrated query based on quotation and normalisation of quoted terms. Our technique supports 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 that normalisation always succeeds in translating any query of flat relation type to SQL. 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. Computing Classification Software and its engineering → Software notations and tools → General programming languages → Language features

Read the paper · More papers on PaperTik