Evaluating ChatGPT for Text-To-SQL: An Empirical Approach

Since the existence of database systems, the querying of data managed by them has been one of the most important and challenging task for their users. For this reason, from the very beginning, there were efforts to allow users to query data using natural language (in most cases English). In such a case, the text has to be processed by a system which generates the corresponding query. In this article we use an empirical approach to evaluate the use of ChatGTP as a representative of Large Language Models (LLMs) for creating and querying relational databases. Our results show that two groups of queries cause significant problems for the system. First, if the system has to „think outside the box", it generates, in several cases, an erroneous query. Second, if a query, which has to be generated is a complex one or its generation demands the use of rarely applied SQL constructs, the corresponding SELECT statement is sometimes faulty.

Authors

Institutions

Publication Details

Published
2025-08-07
DOI
https://doi.org/10.1109/acdsa65407.2025.11166458
Primary Topic
Topic Modeling
Type
article
Field-Weighted Citation Impact
0.00
Controls
|||
ALL TIME
JAN
FEB
MAR
APR
MAY
JUN
JUL
AUG
SEP
OCT
article

Evaluating ChatGPT for Text-To-SQL: An Empirical Approach

Dušan Petković
Topic Modeling
article

Evaluating ChatGPT for Text-To-SQL: An Empirical Approach

Dušan Petković
article en

Abstract

Since the existence of database systems, the querying of data managed by them has been one of the most important and challenging task for their users. For this reason, from the very beginning, there were efforts to allow users to query data using natural language (in most cases English). In such a case, the text has to be processed by a system which generates the corresponding query. In this article we use an empirical approach to evaluate the use of ChatGTP as a representative of Large Language Models (LLMs) for creating and querying relational databases. Our results show that two groups of queries cause significant problems for the system. First, if the system has to „think outside the box", it generates, in several cases, an erroneous query. Second, if a query, which has to be generated is a complex one or its generation demands the use of rarely applied SQL constructs, the corresponding SELECT statement is sometimes faulty.

Rosenheim Technical University of Applied Sciences (DE)
Openalex Percentile: Top 86%
Topic Modeling
AI Navigator

Ask Laika to Summarize, Analyze, and Connect papers live on the map.

Summarize Papers & Methodologies

Extract key findings, datasets, and comparative methods across publications.

Benchmark Rankings & Visual Analytics

Rank top research institutions, authors, funders, topics, and journals by Field-Weighted Citation Impact (FWCI) and paper volume with instant charts.

Connect Distant Disciplines

Bridge topological clusters on the map to find hidden collaborative intersections.