vault backup: 2026-07-23 09:25:21

This commit is contained in:
Benjamin Neumann
2026-07-23 09:25:21 +02:00
parent ec569e7e22
commit 83a9965c03
3 changed files with 47 additions and 4 deletions
+1
View File
@@ -218,6 +218,7 @@
},
"active": "25f5b25d5eca7203",
"lastOpenFiles": [
"SS2026/Datenbanken und Informationssysteme/SQL/DML Data Manipulation Language SQL.md",
"SS2026/Datenbanken und Informationssysteme/SQL/Anhänge/sql_merged.pdf",
"SS2026/Datenbanken und Informationssysteme/SQL/SQL.md",
"SS2026/Datenbanken und Informationssysteme/SQL/DDL Data Definition Language SQL.md",
@@ -0,0 +1,14 @@
### INSERT
```
INSERT INTO <tabelle> (spalte1, spalte2, ...) VALUES (wert1, wert2, ...);
```
### UPDATE
```
UPDATE <tabelle> SET spalte1 = wert1, spalte2 = wert2, ... WHERE <bedingung>;
```
### DELETE
```
DELETE FROM <tabelle> WHERE <bedingung>;
```
@@ -15,12 +15,40 @@ Duplikate möglich!!!
2. UPDATE
3. DELETE
### INSERT
[[DML Data Manipulation Language SQL]]
| SQL | Argumente | Relationale Algebra |
| ---------- | ------------------ | ------------------- |
| **SELECT** | Liste von Namen | $\pi$ |
| **FROM** | Liste von Tabellen | $\times$ |
| **WHERE** | Bedingung | $\sigma$ |
### SELECT
```
INSERT INTO <tabelle> (spalte1, spalte2, ...) VALUES (wert1, wert2, ...);
SELECT MatrNr, Name, Semester from Student
```
### UPDATE
Spalte umbenennen
`SELECT MatrNr AS InsassenNr from Student`
Keine Duplikate
`SELECT DISTINCT Semester AS Jahrgänge from Student`
### WHERE
```
UPDATE <tabelle> SET spalte1 = wert1, spalte2 = wert2, ... WHERE <bedingung>;
SELECT * from Student WHERE Semester = 2
---
SELECT * from Student s WHERE s.Semester = 2 AND s.Name='Byleth'
```
#### Anatomie einer WHERE Klausel
Vergleichsoperatoren: <,>,=,<=,>=,<>
BETWEEN
LIKE
IS NULL
AND, OR, NOT