• Home
  • Search
  • A Static Code Smell Detector for SQL Queries Embedded in Java Code
  • Cite Icon26
  • https://doi.org/10.1109/scam.2017.19Copy DOI Icon

A Static Code Smell Detector for SQL Queries Embedded in Java Code

  • Sep 1, 2017
  • Csaba Nagy +1 more
Show More
  • Abstract
  • Literature Map
  • References
  • Citations
  • Similar Papers
Abstract

A database plays a central role in the architecture of an information system, and the way it stores the data delimits its main features. However, it is not just the data that matters. The way it is handled, i.e., how the application communicates with the database is of critical importance too. Therefore the implementation of such a communication layer has to be reliable and efficient. SQL is a popular language to query a database, and modern technologies rely on it (or its dialects) as query strings embedded in the application code. In many languages (e.g. in Java), an embedded query is typically constructed through several string operations that obstruct developers in understanding the statement finally sent to the database. It is a potential source of fault-prone and inefficient database usage, i.e., code smells. In our paper, we present a tool for the identification of code smells in SQL queries embedded in Java code. Our tool implements a combined static analysis of the SQL statements embedded in the source code, the database schema, and the data in the database. We use a lightweight query extraction algorithm to extract SQL code from the Java code and implement smell detectors on the ASG of our fault-tolerant SQL parser. Depending on the context of the smell, its severity is also determined. Developers can examine the identified issues with the help of an Eclipse plug-in or through command line interfaces.

Similar Papers
  • Conference Article

Towards Understanding the Distribution and Evolution of Code Smells: An Empirical Study on Java and Python Projects (S)

  • Oct 28, 2024
  • Proceedings/Proceedings of the ... International Conference on Software Engineering and Knowledge Engineering
  • Qing Mi +3
  • Book Chapter
  • Citations42

Code Smells Detection Using Artificial Intelligence Techniques: A Business-Driven Systematic Review

  • Aug 16, 2021
  • Tomasz Lewowski +1
  • Conference Article
  • Citations3

TFfinder: A Software tool to discover Temporary Field code smell

  • Dec 18, 2020
  • Ruchin Gupta +1
  • Conference Article
  • Citations4

The Effects of Extract Function Refactoring On High Cyclomatic Complexity Code Smell and Maintainability Index

  • Oct 10, 2023
  • Muhammad Naufal Pratama +2
  • Book Chapter
  • Citations36

Utilising Code Smells to Detect Quality Problems in TTCN-3 Test Suites

  • Jan 01, 2007
  • Helmut Neukirchen +1
  • Conference Article
  • Citations2

A Novel Approach for Improving the Quality of Software Code using Reverse Engineering

  • Jun 19, 2018
  • Hamza A Elghadhafi +2
  • Research Article
  • Citations52

Monitor-Based Instant Software Refactoring

  • Aug 01, 2013
  • IEEE Transactions on Software Engineering
  • Hui Liu +2
  • PDF
  • Research Article
  • Citations1

From code to insight: studying code representation techniques for ML-based God class detection to support intelligent IDEs

  • Jul 25, 2025
  • Automated Software Engineering
  • Elmohanad Haroon +2
  • Research Article
  • Citations6

Unsupervised Machine Learning for Effective Code Smell Detection: A Novel Method

  • Jan 01, 2024
  • Journal of Communications Software and Systems
  • Ruchin Gupta +3
  • Conference Article
  • Citations10

Defining and Applying Detection Strategies for Aspect-Oriented Code Smells

  • Sep 01, 2010
  • Isela Macia +2
  • Conference Article
  • Citations2

Code smells in highly configurable software

  • Sep 01, 2015
  • Wolfram Fenske
  • Conference Article
  • Citations18

Are Code Smell Co-occurrences Harmful to Internal Quality Attributes?

  • Oct 21, 2020
  • Júlio Martins +3
  • Conference Article
  • Citations8

Towards the Definition of Patterns and Code Smells for Multi-language Systems

  • Jul 01, 2020
  • Mouna Abidi +1
  • Conference Article
  • Citations75

Landfill: An Open Dataset of Code Smells with Public Evaluation

  • May 01, 2015
  • Fabio Palomba +6
  • Research Article

Optimizing LSTM for Code Smell Detection: The Role of Data Balancing

  • Jan 01, 2024
  • Infocommunications journal
  • Alnor Adam Khleel Nasraldeen +1
Cactus Communications logo

Copyright 2026 Cactus Communications. All rights reserved.