Proceedings of the 8th ACM SIGPLAN International Conference on Certified Programs and Proofs 2019
DOI: 10.1145/3293880.3294107
|View full text |Cite
|
Sign up to set email alerts
|

A Coq mechanised formal semantics for realistic SQL queries: formally reconciling SQL and bag relational algebra

Abstract: In this article, we provide a Coq mechanised, executable, formal semantics for a realistic fragment of SQL consisting of select [distinct] from where group by having queries with NULL values, functions, aggregates, quantifiers and nested potentially correlated sub-queries. Relying on the Coq extraction mechanism to Ocaml, we further produce a Coq certified semantic analyser for a SQL compiler. We then relate this fragment to a Coq formalised (extended) relational algebra that enjoys a bag semantics hence recov… Show more

Help me understand this report

Search citation statements

Order By: Relevance

Paper Sections

Select...
2
2
1

Citation Types

0
45
0

Year Published

2019
2019
2022
2022

Publication Types

Select...
3
3
1

Relationship

1
6

Authors

Journals

citations
Cited by 18 publications
(45 citation statements)
references
References 14 publications
0
45
0
Order By: Relevance
“…The Datacert library [3] provides the most complete mechanized semantics for SQL queries with aggregates, NULL values and correlated queries, and formally relates them to an extension of relational algebra. In this work, we extend the relational algebra part with provenance.…”
Section: Presentation Of the Datacert Librarymentioning
confidence: 99%
“…The Datacert library [3] provides the most complete mechanized semantics for SQL queries with aggregates, NULL values and correlated queries, and formally relates them to an extension of relational algebra. In this work, we extend the relational algebra part with provenance.…”
Section: Presentation Of the Datacert Librarymentioning
confidence: 99%
“…The list includes Leroy's CompCert [24], i.e. a Coq specification and verified optimizing compiler for a large subset of the C programming language, and the DataCert project working towards a certified SQL engine [4,5]. In the same spirit, the JSCert project [7] provides a formal specification of Javascript in Coq and a reference certified interpreter.…”
Section: Related Workmentioning
confidence: 99%
“…The mechanized formalization of data management systems has received a lot of attention in the traditional relational data model [3], SQL and its semantics [2,5,11,12], as well as related query languages and engines [1,4]. Coq is the proof assistant of choice for all these efforts.…”
Section: Related Workmentioning
confidence: 99%
“…Originally developed internally by Facebook as an alternative to RESTful Web Services [21], GraphQL was made public in 2015, along with a reference implementation 1 and a specification-both of which have naturally evolved [16]. Since early 2019, as a result of its successful adoption by major players in industry, GraphQL is driven by an independent foundation 2 . The key novelty compared to traditional REST-based services is that tailored queries can be formulated directly by clients, allowing a very precise selection of which data ought to be sent back as response.…”
Section: Introductionmentioning
confidence: 99%
See 1 more Smart Citation