A Survey of Large Language Model-Based Generative AI for Text-to-SQL: Benchmarks, Applications, Use Cases, and Challenges
Preprint
Abstract
Text-to-SQL systems facilitate smooth interaction with databases by translating natural language queries into Structured Query Language (SQL), bridging the gap between non-technical users and complex database management systems. This survey provides a comprehensive overview of the evolution of AI-driven text-to-SQL systems, highlighting their foundational components, advancements in large language model (LLM) architectures, and the critical role of datasets such as Spider, WikiSQL, and CoSQL in driving progress. We examine the applications of text-to-SQL in domains like healthcare, education, and finance, emphasizing their transformative potential for improving data accessibility. Additionally, we analyze persistent challenges, including domain generalization, query optimization, support for multi-turn conversational interactions, and the limited availability of datasets tailored for NoSQL databases and dynamic real-world scenarios. To address these challenges, we outline future research directions, such as extending text-to-SQL capabilities to support NoSQL databases, designing datasets for dynamic multi-turn interactions, and optimizing systems for real-world scalability and robustness. By surveying current advancements and identifying key gaps, this paper aims to guide the next generation of research and applications in LLM-based text-to-SQL systems.Keywords
All Related Versions
This publication has 10 references indexed in Scilit:
- Next-Generation Database Interfaces: A Survey of LLM-Based Text-to-SQLIEEE Transactions on Knowledge and Data Engineering, 2025
- A Survey on Employing Large Language Models for Text-to-SQL TasksACM Computing Surveys, 2025
- ETM: Modern Insights into Perspective on Text-to-SQL Evaluation in the Age of Large Language ModelsFuture Internet, 2025
- MedT5SQL: a transformers-based large language model for text-to-SQL conversion in the healthcare domainFrontiers in Big Data, 2024
- UQE: A Query Engine for Unstructured Databases2024
- RASAT: Integrating Relational Structures into Pretrained Seq2Seq Model for Text-to-SQL2022
- PICARD: Parsing Incrementally for Constrained Auto-Regressive Decoding from Language Models2021
- RAT-SQL: Relation-Aware Schema Encoding and Linking for Text-to-SQL Parsers2020
- CoSQL: A Conversational Text-to-SQL Challenge Towards Cross-Domain Natural Language Interfaces to Databases2019
- A Pilot Study for Chinese SQL Semantic Parsing2019