Type- and Content-Driven Synthesis of SQL Queries from Natural Language
Not on the map. Why?
Abstract (arXiv)
This paper presents a new technique for automatically synthesizing SQL queries from natural language. Our technique is fully automated, works for any database without requiring additional customization, and does not require users to know the underlying database schema. Our method achieves these goals by combining natural language processing, program synthesis, and automated program repair. Given the user's English description, our technique first uses semantic parsing to generate a query sketch, which is subsequently completed using type-directed program synthesis and assigned a confidence score using database contents. However, since the user's description may not accurately reflect the actual database schema, our approach also performs fault localization and repairs the erroneous part of the sketch. This synthesize-repair loop is repeated until the algorithm infers a query with a sufficiently high confidence score. We have implemented the proposed technique in a tool called Sqlizer and evaluate it on three different databases. Our experiments show that the desired query is ranked within the top 5 candidates in close to 90% of the cases.
Key facts. Cited by 5 papers in the map (data through 7 Oct 2026). First posted on arXiv 3 Feb 2017.
Builds on
No reference list yet.
Built on by
Citing papers per year: 2022: 2; 2023: 2; 2024: 0; 2025: 1.
5 papers.
- 2022Importance of Synthesizing High-quality Data for Text-to-SQL Parsingcited by 27
- 2022T5QL: Taming language models for SQL generationcited by 8
- 2023Battle of the Large Language Models: Dolly vs LLaMA vs Vicuna vs Guanaco vs Bard vs ChatGPT -- A Text-to-SQL Parsing Comparisoncited by 6
- 2025Text-to-SQL Domain Adaptation via Human-LLM Collaborative Data Annotationcited by 6
- 2023CSS: A Large-scale Cross-schema Chinese Text-to-SQL Medical Datasetcited by 0
- 2025Text-to-SQL Domain Adaptation via Human-LLM Collaborative Data Annotation21 Feb 2025
- 2023Battle of the Large Language Models: Dolly vs LLaMA vs Vicuna vs Guanaco vs Bard vs ChatGPT -- A Text-to-SQL Parsing Comparison16 Oct 2023
- 2023CSS: A Large-scale Cross-schema Chinese Text-to-SQL Medical Dataset25 May 2023
- 2022Importance of Synthesizing High-quality Data for Text-to-SQL Parsing17 Dec 2022
- 2022T5QL: Taming language models for SQL generation21 Sep 2022