Edinburgh Research Explorer A Practical Theory of Language-integrated Query
Edinburgh Research Explorer A Practical Theory of Language-integrated Query
复制标题
爱丁堡研究探索者语言集成查询的实用理论
DOI:
--
复制
发表时间:
--
期刊:
影响因子:
--
通讯作者:
P. Wadler
中科院分区:
文献类型:
--
作者:
James Cheney;S. Lindley;P. Wadler
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, compo- sition 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 ei- ther fails to produce an SQL query or, in one case, produces an avalanche of SQL queries.