EDAF75: Database Technology – Spring 2026
Regarding languages
This webpage is mainly written in English, in case we need to use non Swedish-speaking PhD-students for supervision (so that they can see what we're doing). Some of the 'administrativia' will be in Swedish.
Senaste uppdateringarna
- Fredag, 27 februari, 17:25: veckoschemat är uppdaterat.
- Fredag 27 februari, 08:14: API-et för projektet är utlagt.
- Tisdag 24 februari, 22:18: schemat för designmötena är utlagt.
- Lördag 21 februari, 12:52: veckoschemat är uppdaterat, och anmälan till designmötet utlagd (se 'Announcements') – även anteckningar till föreläsning 10 är utlagda.
- Torsdag 19 februari, 19:52: anmälan till designseminarierna utlagd.
Announcements
Anmälan av laborations- och projektgrupp
coursegit (jag använde gitlabs REST-api, dvs samma teknologi som ni skall implementera).
Något måste ha gått fel när jag på måndag slog av skyddet av main, för det fungerade bara på några gruppers repositories, men när jag nu på tisdag körde exakt samma kommandon igen (dvs ett curl --request DELETE på /protected_branches/main) så ser det ut att ha fungerat även för övriga grupper – hör av er om ni fortfarande inte kan 'push'-a eller 'merge'-a till main.
This week (course week 7, Mar 2 - Mar 6)
Nothing new, we'll just review the course material, and look at problems from previous exams.
- Session 12: About the exam.
- On Monday, 13:15-15:00 in E:A, we'll solve problems from the March exam in 2024
En kommentar om mail till LU
Mail på LU fungerar tyvärr numera väldigt dåligt, det finns lite mer information om det längst ner på denna sida.
Quick links
- Course rules (in Swedish)
- TimeEdit schedule – observe that you'll only have to attend one of the Lab sessions in each of course weeks 3-5 (and your group will book a 10 minutes time slot for each one of them, so in each week, you'll need to spend no more than 10 minutes in the lab rooms).
- Course representatives:
- D: ? (please let me know if you're interested)
- C: ? (please let me know if you're interested)
- Moodle (here you can sign up for QA sessions)
- Labs:
- Project
- Exams (in Swedish)
- Jupyter instructions
Course overview
The main focus of this course is relational databases (RDBMS), but we'll also briefly touch upon alternatives (NoSQL) and technologies used in conjunction with databases. Looking at old exams, approximately 80% is about designing, normalizing and querying SQL databases, the remaining 20% is a mix of other things.
The course is divided into 11 sessions, where most sessions consist of one lecture, and some recommended homework – some of the homework will be discussed either during the lectures, or during QA-sessions.
We'll also have three lab exercises, at which you will get the opportunity to discuss your solutions to some homework problems with a teaching assistant.
Finally we have a project where you'll have to:
- attend a design meeting (you and your group will peer review other groups' designs, and at the same time have your own design reviewed by other groups), and
- hand in a working program and some documentation.
Schedule, spring 2026
There is a detailed schedule in TimeEdit.
The course is a work in progress, so I'll add material below as we go along.
Below you find all weeks (including the current week), so you can see all sessions in context – the current week is also shown at the top of this page, so you don't have to scroll if you only want to see what's happening right now.
Observe that the links below often stray way outside the boundaries of this course – the links are there to give you some context, they're not required reading.
Course week 1 (Jan 19 - Jan 23)
We'll talk about how to use SQL – it is a programming language which is specifically designed to make it easy to add, find and update information in relational databases.
- Session 1 Introduction to the Relational Model, Relational Algebra, and SQL.
- To prepare you for this session, I suggest you ponder a couple of questions.
- The notebook I'll use can be fetched here (just unzip it into a directory in which you can run jupyter notebooks).
- The few slides I'll use can be found here.
- After the lecture, the notebook looked like this:
- Session 2 Introduction to dependencies, redundance and anomalies in tables, splitting data into separate tables, and joining tables together.
Different kinds of joins (inner, outer, cross, equijoins).
- Before the lecture, you can try some of the exercises in the notebook for lecture 1.
- The notebook I'll use is here (just unzip it into a directory in which you can run jupyter notebooks), and the slides are here.
- After the lecture, the notebook looked like this:
- QA session: On Moodle you can sign up for a QA session on Friday, 12:15-… (I'll post the location of the QA session on Moodle once I've booked a room for it).
Course week 2 (Jan 26 - Jan 30)
Ni måste anmäla er labgrupp senast 23:59 på fredag denna vecka (läsvecka 2). Jag har fått in anmälningar av dem som vill få en grupp att arbeta med, och på måndag eller tisdag kommer jag att maila er med gruppindelningen.
På tisdag kommer jag sedan att öppna en sida där övriga kan anmäla era grupper (jag lägger själv in de grupper som jag har delat in) – det är denna anmälan som måste göras senast klockan 23:59 på fredag (så att vi vet hur många grupper vi måste skaffa handledare till).
På måndag i läsvecka 3 kommer jag att öppna en websida där ni kan anmäla er till ett 10 minuter långt redovisningspass, vi kommer att ha laborations-sessioner på onsdag 13-15, torsdag 10-12 och fredag 08-10 i läsvecka 3-5, och er grupp skall alltså bara anmäla sig till ett 10-minuter långt pass under någon av dessa sessioner (ett pass i veckan, och ni kan ha olika tider i olika veckor).
Det kommer att finnas ungefär 25 tillgängliga 10-minuterspass vid var och en av sessionerna, och de senaste åren har det aldrig varit något problem för grupperna att hitta lämpliga tider.
This week we'll look into how to create models of everyday systems, and translate those models into relational databases.
- Session 3: E/R modelling using UML
- The lecture will be held on Monday, 13:15 - 15:00 in E:A – to prepare for it you can read through some text here.
- The slides I'll use is here.
- Here are some notes for lecture 3.
- Session 4: Converting E/R models into database schemes using SQL/DDL
- The lecture will be held on Thursday, 13:15 - 15:00 in E:A – to prepare, I suggest you try to finish the example we began on Monday.
- I'll use this notebook, and these slides.
- Here are some notes for lecture 4 (you could also use the notebook to work through the examples in the notes).
- QA session: On Moodle you can sign up for a QA session on Friday, 12:15-… (I'll post the location of the QA session here once I've booked a room for it).
Course week 3 (Feb 2 - Feb 6)
You need to book a meeting with a TA, so you can hand in Lab 1 this week – on Monday I'll post a link to a webpage where you can sign up for a 10 minutes time slot.
We'll see how we can use SQL databases from other languages (Python and Java), we'll also see how to create a REST service, which can be used to serve various front ends with data.
- Session 5: Calling SQL from other languages and (Python and Java)
- The lecture will be held on Monday, 13:15 - 15:00 in E:A – I'll talk about how we can use SQL from Java and Python.
- There are no special preparations for this lecture, other than that it would be good to brush up on your Python skills, if you want to use Python for lab 3 and the project.
- I'll use some text files and and these slides.
- Here are some notes for lecture 5.
- QA session: On Moodle you can sign up for a QA session on Tuesday, 12:15-… (I'll post the location of the QA session here once I've booked a room for it).
- Session 6: Databases and REST API:s
- The lecture will be held on Thursday, 13:15 - 15:00 in E:A – I'll talk about REST services, and how we can write database-backed REST services in Java and Python.
- I'll use these slides
- Here are some notes for lecture 6.
- Lab 1: SQL queries
Course week 4 (Feb 9 - Feb 13)
You need to book a meeting with a TA, so you can hand in Lab 1 this week – during the week, I'll publish a link to a website where you can do it.
This week it's time to get a better understanding of fundamental concepts such as dependencies and redundancies, and learn ways to categorize tables, and transform (normalize) them into a better shape.
- Session 7: Normalization
- To prepare you for this session, I suggest you try to answer a couple of questions.
- The lecture will be held on Monday, 13:15 - 15:00 in E:A – I'll talk about functional dependencies and normalization.
- The slides I'll use can be downloaded here.
- Here are some notes for lecture 7.
- QA session: On Moodle you can sign up for a QA session on Tuesday, 12:15-… (I'll post the location of the QA session here once I've booked a room for it).
- Session 8: More normalization
- The lecture will be held on Thursday, 13:15 - 15:00 in E:B. I'll talk more about normalization.
- The slides I'll use can be downloaded here, and the notebook is here.
- Here are some notes for lecture 8.
- Lab 2: Database modeling
Course week 5 (Feb 16 - Feb 20)
You need to book a meeting with a TA, so you can hand in Lab 3 this week (see the top of this page).
This week we'll talk about how to keep the integrity of a database (to reduce the risk that it gets corrupted), and also talk about ways databases are used, and see some alternatives to SQL databases.
- Session 9: Transactions and triggers.
- The lecture will be held on Monday, 13:15 - 15:00 in E:A – I'll talk about transactions and triggers.
- The slides I'll use are here.
- Here are some notes for lecture 9.
- QA session: On Moodle you can sign up for a QA session on Tuesday, 12:15-… (I'll post the location of the QA session here once I've booked a room for it).
- Session 10: Introduction to the project, indices, the query planner, NoSQL, scaling, SQL injections.
- The lecture will be held on Thursday, 13:15 - 15:00 in E:A – I'll give a short introduction to the project, talk about indices, the query planner, NoSQL, and scaling, and then talk a little bit about SQL injection.
- The slides I'll use are here, and I'll also use a notebook.
- Here are some notes for lecture 10.
- Lab 3: Implementing a REST API
Course week 6 (Feb 23 - Feb 27)
- Session 11: Graph databases.
- Project design meeting. We have two alternative slots for the design meeting, both on Wednesday: either 10-12 or 13-15 – at least one person in your group must participate in one of the meetings (you can sign up here).
- QA session: On Moodle you can sign up for a QA session on Tuesday, 12:15-… (I'll post the location of the QA session here once I've booked a room for it).
Course week 7 (Mar 2 - Mar 6)
Nothing new, we'll just review the course material, and look at problems from previous exams.
- Session 12: About the exam.
- On Monday, 13:15-15:00 in E:A, we'll solve problems from the March exam in 2024
Course week 8 (Mar 9 - Mar 13)
In week 8 we can have QA sessions on Tuesday and Wednesday – see the top of the page.
En kommentar om mail till LU
Normalt skickar vi veckan före kursstart ut ett mail med information till alla som anmält sig till kursen, men det fungerar dessvärre inte längre.
I början av 2024 stängde nämligen Lunds universitet av de IMAP(s) och SMTP(s) servrar man tidigare hade, och tvingade istället på oss ett fruktansvärt dåligt webmail-GUI som kostar oss massor av extra tid, och dramatiskt ökar både risken att vi missar inkommande mail och att vi skickar mail till fel mottagare. Det gör oss dessutom helt beroende av ett amerikanskt företag (Microsoft), vars verksamhet vi inte har någon som helst insyn i, och det känns naivt att tro annat än att våra mail läses och sparas på amerikanska servers (och vad de används för där kan vi bara spekulera i).
Tidigare år kunde jag skicka mail till samtliga grupper med hjälp av enkla Python-scripts, det går inte längre – när jag i en kurs i höstas skulle skicka mail till projektgrupperna var jag tvungen att klicka 17 gånger för var och en av de drygt 50 grupperna, och minst ett av mailen kom aldrig fram (jag missade förmodligen något av de 850 musklick som jag behövde göra).
Det nya klick-baserade mail-systemet gör det dessutom väldigt mycket svårare att hålla koll på mail-kedjor – tidigare kunde jag läsa och skriva mina mail inifrån Emacs, och då var det enkelt att automatisera hantering/arkivering av mail-kedjor för projektgrupperna, och enkelt att hålla koll på vilka mail som hade besvarats. Idag måste jag klicka runt i ett GUI som kanske skulle fungera för någon som vill skicka mail till sina närmaste kollegor, men som absolut inte fungerar för att hantera studenter i en kurs med nära 200 deltagare i 50 grupper. Dessutom varnar det nya systemet inte om era mail inte kommer fram (ni får inget meddelande om ni skulle använda en felaktig adress), och periodvis kan jag inte komma åt min inkorg.
Jag beklagar verkligen de problem som det nya mail-systemet kommer att medföra (missade mail, felskickade mail och fördröjd återkoppling) – institutionen har bett att få tillbaka IMAP och SMTP, men ingenting har hänt hittills.
Det är dessutom inte ovanligt att studenter skickar mail till mig med frågor om innehållet i EDAF75. Jag skulle önska att jag hade möjlighet att svara på individuella mail-frågor om kursinnehållet, men att skriva mail-svar tar mycket längre tid än att svara på frågor direkt (i synnerhet med det nya mailsystemet) – dessutom är mail en väldigt dålig kanal att förklara på, både för att det är lätt att missförstå nyanser i frågor, och för att det är omöjligt att se om ni förstår svaret, och vilken del av svaret som kanske behöver förtydligas. Så en kurs med ca 200 kursdeltagare per lärare skalar väldigt vädigt dåligt för mail-undervisning – om jag bara lägger 10-15 minuter på att läsa en mailfråga och skriva ett svar, så skulle det ändå bli mer än en arbetsvecka för en fråga per student.
Du är istället hjärtligt välkommen med frågor antingen till våra frågestunder (se Moodle), eller i samband med föreläsningar (både i pausen och efteråt).