---
# System prepended metadata

title: SQL - Structured Query Language

---

# SQL (Structured Query Language)
## Agenda
- SQL Clients
- The SQL query language and its parts and functions
- Data Definition
	- Creating Tables, Views & Indexes
	- Defining Constraints
- Data Manipulation
	- Inserting data
	- Updating data
	- Deleting data
- Data Query
	- Selecting data
	- Aggregate Functions
	- Aggregation and Grouping
	- Subquires (Nested queries)
	- Joins and Relational Algebra with SQL
	    - Projection
	    - Selection
	    - Union
	    - Equijoins, Natural Joins, Inner & Outer Joins
- Additional topics
	- Modern SQL
	- Inner & Outer Joins
	- Recursive Common Table Expressions (CTEs) 
## References
### Academic References
1. Sönke Cordts, Gerold Blakowski, Gerhard Brosius: Datenbanken für Wirtschaftsinformatiker: Nach dem aktuellen Standard SQL:2008, Auflage: 2011, Vieweg+Teubner Verlag, ISBN-13: 978-3834813824.
2. Avi Silberschatz, Henry F. Korth, S. Sudarshan: [Database System](https://www.db-book.com/) [Concepts](https://www.db-book.com/) [- 7th](https://www.db-book.com/) [edition](https://www.db-book.com/), McGraw-Hill, ISBN 9780078022159.
3. [Vorlesung "Datenmanagement mit SQL"](https://open.hpi.de/courses/sql) (HPI, Prof. Dr. Felix Naumann)
### Some open-source SQL databases
4. [MySQL Developer Zone](https://dev.mysql.com)
	- [MySQL Hands-On Lab Manual](https://www.oracle.com/technetwork/community/developer-day/mysql-hands-on-lab-403032.pdf)
5. [MariaDB](https://mariadb.org)
6. [PostgreSQL](https://www.postgresql.org)
### SQL Tutorials, Simulators and Helpers
8. [sql.js demo](https://www.db-book.com/university-lab-dir/sqljs.html) : Online SQL interpreter
9. [DB Quacks - Interactive SQL & DuckDB Tutorial](https://dbquacks.com/tutorial/1)
10. [Online SQL Trainer](https://sql-academy.org/en/trainer?sort=byId)
11. [SQL Learning Game](http://www.sql-island.de/)
12. [SQL Tutorial: Learn SQL from Scratch for Beginners](https://www.sqltutorial.org/)
13. [SQL Tutorial](https://www.w3schools.com/sql/)
14. [sqlfmt](https://www.cockroachlabs.com/blog/sql-fmt-online-sql-formatter/?utm_campaign=nl-email&utm_source=mkto&utm_medium=email&utm_term=september-monthly-newsletter&utm_content=newsletter-2021-9&mkt_tok=MzUwLVFJTi04MjcAAAF_QUVud0lphe4Tmfj9DxdPSqV3GFbIJCsHkNvXM-nzGjalQdGt8RqKDxCzalgbYz_I3DPE-tH0RmyWKm26prO1awzY7tF9du-bdJPoW66P): A SQL formatter for writing prettier SQL
15. [SQL Quiz](https://www.w3schools.com/quiztest/quiztest.asp?qtest=SQL)
16. [SQL Practice Questions](https://techbeamers.com/sql-query-questions-answers-for-practice/)
17. [SQLBolt - Learn SQL - Introduction to SQL](https://sqlbolt.com/)
18. [SQL Q&A](https://www.tutorialspoint.com/sql/sql_questions_answers.htm)
19. DBSim:
	- [DBSim: Extensible Database Simulator for Fast Prototyping In-Database Algorithms – Data Science Research](https://dsr.cise.ufl.edu/dbsim-extensible-database-simulator-for-fast-prototyping-in-database-algorithms/index.html)
	- [Extensible Database Simulator for Fast Prototyping In-Database Algorithms \| Proceedings of the 31st ACM International Conference on Information & Knowledge Management](https://dl.acm.org/doi/10.1145/3511808.3557205)
	- [DBSim Codebase](https://github.com/wyfunique/DBSim)
### SQL Sample Databases
20. [Other MySQL Documentation](https://dev.mysql.com/doc/index-other.html) incl. Sakila
	- [MySQL queries on the sakila database](https://github.com/cantugabriela/Sakila-Queries-MySQL)
21. [MySQL ClassicModels Sample Database](https://www.mysqltutorial.org/getting-started-with-mysql/mysql-sample-database/)
### Further Online References
22. [Modern SQL](https://modern-sql.com/de) 
23. [Modern SQL: Three-Valued Logic (3VL) — Purpose, Benefits and Special Cases](https:/modern-sql.com/concept/three-valued-logic)
24. [Extended Backus-Naur-Form](https://en.wikipedia.org/wiki/Extended_Backus%E2%80%93Naur_Form)

## The person behind it
[Donald D. Chamberlin - Wikipedia](https://en.wikipedia.org/wiki/Donald_D._Chamberlin)

## Flashcards
[Structured Query Language SQL - AnkiWeb](https://ankiweb.net/shared/info/1980255676)
