Semantic Conformance Testing of Relational DBMS

Shuang Liu, Chenglin Tian, Jun Sun, Ruifeng Wang, Wei Lu*, Yongxin Zhao, Yinxing Xue, Junjie Wang, Xiaoyong Du

*Corresponding author for this work

Research output: Contribution to journalConference articlepeer-review

1 Scopus citations

Abstract

Relational DBMS implementations are expected to adhere to SQL standards. However, there are currently no tools available that can automatically verify this conformance. The main reasons are twofold. First, the SQL standard specification, documented in natural language, tends to be ambiguous and is not directly executable. Second, it is difficult to generate test queries that thoroughly coverall aspects, e.g., keywords and parameters, defined in the SQL specification. In this work, we introduce the first method for semantic conformance testing of RDBMSs. Our contributions are threefold. Firstly, we formally define the denotational semantics of SQL and implement them in Prolog, creating an executable reference RDBMS for differential testing against existing RDBMSs. Secondly, we propose three coverage criteria based on these formal semantics, along with a coverage-guided query generation algorithm that effectively generates queries achieving high semantic coverage. Lastly, we apply our approach to six widely-used and thoroughly tested RDBMSs, e.g., MySQL, PostgreSQL and Ocean Base, uncovering 19bugs and 13 inconsistencies, all of which are confirmed by RDBMS developers.

Original languageEnglish
Pages (from-to)850-862
Number of pages13
JournalProceedings of the VLDB Endowment
Volume18
Issue number3
DOIs
StatePublished - 2025
Event51st International Conference on Very Large Data Bases, VLDB 2025 - London, United Kingdom
Duration: 1 Sep 20255 Sep 2025

Fingerprint

Dive into the research topics of 'Semantic Conformance Testing of Relational DBMS'. Together they form a unique fingerprint.

Cite this