Skip to main navigation Skip to search Skip to main content

Maintainability Assessment and Modernization Strategies for Legacy SQL Server Systems

  • Susanne Danninger

    Student thesis: Master's Thesis

    Abstract

    Many organizations depend on relational databases that have been in productive use
    for decades. Their business logic sits in stored procedures. Such a database grows over
    many years and through many developers, and its maintainability becomes invisible
    long before it becomes a problem. Existing static analysis tools read one artifact at a
    time: the procedure code, the schema, or the dependencies between objects. Each of
    them reports findings without stating what should follow from them.
    This thesis presents a framework that measures four aspects of such a database at
    once. These are the complexity of the individual procedures, anti-patterns specific to T
    SQL, the dependencies of a procedure on the other database modules and on the tables
    it relies on, and the structural quality of the schema. Established software metrics are
    adapted to T-SQL where they apply. Where they do not, database-specific indicators
    are added. The most important of these captures the coupling that runs through shared
    tables instead of through calls. The code-level and dependency measurements yield one
    action score and one priority band per procedure. Schema defects are reported for the
    system as a whole and are not charged to the procedures that touch an affected table. A
    fixed set of named rules then assigns each procedure the modernization strategies whose
    conditions it meets. There are five such strategies, and a procedure can receive several of
    them or none. Every recommendation names the rule and the measured value that pro
    duced it, so it can be traced back to a single measurement instead of to a combined score.
    The framework was applied to a database of ÖBB Produktion GmbH containing 1612
    stored procedures. Three results stand out. Complexity is concentrated in a small mi
    nority of procedures. The coupling of this system runs almost entirely through shared
    tables, not through calls. The NOLOCK hint, which trades correctness for speed, is
    used across the whole codebase as a convention rather than as a local decision. Just
    over half of the procedures received no recommendation at all. This is itself a result:
    a framework meant for prioritization has to be able to say where no work is needed.
    The framework also made a group of duplicated procedures visible, which it was never
    designed to detect.
    Date of Award2026
    Original languageEnglish (American)
    Awarding Institution
    • FH OÖ
    SupervisorHerwig Mayr (Supervisor) & Alexander Grünwald (Supervisor)

    Studyprogram

    • Software Engineering

    Cite this

    '