版权所有:内蒙古大学图书馆 技术提供:维普资讯• 智图
内蒙古自治区呼和浩特市赛罕区大学西街235号 邮编: 010021
作者机构:Univ Edinburgh Edinburgh EH8 9YL Midlothian Scotland Univ Strathclyde Glasgow G1 1XQ Lanark Scotland
出 版 物:《ACM SIGPLAN NOTICES》 (ACM SIGPLAN Not.)
年 卷 期:2013年第48卷第9期
页 面:403-416页
核心收录:
学科分类:08[工学] 0835[工学-软件工程] 0812[工学-计算机科学与技术(可授工学、理学学位)]
基 金:Google Research Award EPSRC [EP/J014591/1, EP/K034413/1] Royal Society University Research Fellowship EPSRC [EP/K034413/1, EP/J014591/1] Funding Source: UKRI
主 题:lambda calculus LINQ F# SQL quotation anti-quotation
摘 要: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.