Declarative Amsterdam

Declarative thinking in SQL, its teaching and its unused potential

Günter BurgstallerHTBLuVA Wiener Neustadt

Despite its many warts and wrinkles, SQL is undeniably a declarative success story. Teaching declarative thinking is often impeded by the procedural mindset of students originating from their early training almost exclusively in imperative programming languages. While SQL databases are optimized for executing SQL, students tend to write inefficient and clumsy code using disputable so-called “procedural extensions”. A few typical examples will be presented. While a limited kind of declarative constraints are supported in SQL, implementations generally fall short of the potential of database-wide declarative constraints. Some notions are illustrated by looking at declarative referential integrity, triggers as a poor substitute and an experimental RDBMS called “Rel”. As a concluding impulse for discussion, the presumed waste of talented declarative minds by the overpowering imperative bias in teaching is addressed.

Presentation, 8 November 2022
Günter Burgstaller teaches “Database and Information Systems” at the HTBLuVA Wiener Neustadt’s informatics department since 2009. Austria’s unique technical college system, recognised in the EU as third-level education, trains students from 14 years on to become highly-demanded engineers in the course of five years. Graduates are also eligible for university.
Prior to teaching, Günter Burgstaller worked for 15 years as a database and systems engineer in various IT companies.