Unterschiede
Hier werden die Unterschiede zwischen zwei Versionen angezeigt.
| Beide Seiten der vorigen Revision Vorhergehende Überarbeitung Nächste Überarbeitung | Vorhergehende Überarbeitung | ||
| modul:m290:learningunits:lu04:theorie:a_syntax [2024/08/30 10:58] – vdemir | modul:m290:learningunits:lu04:theorie:a_syntax [2024/10/17 12:33] (aktuell) – vdemir | ||
|---|---|---|---|
| Zeile 1: | Zeile 1: | ||
| - | ====== | + | ====== |
| - | ===== Introduction ===== | + | As we know, **SQL** stands for **S**tructured **Q**uery **L**anguage. Consequently, |
| - | As we know, **SQL** stands for **S**tructured **Q**uery **L**anguage. Consequently, | + | |
| - | ===== NOTE ===== | + | {{: |
| - | Please note that the use og CAPITAL LETTERS for SQL commands and tabs can make it easier for you to maintain your program code. | + | |
| + | ===== NOTES | ||
| + | * The content of this chapter is based on the [[https:// | ||
| + | * Please note that the use og CAPITAL LETTERS for SQL commands and tabs can make it easier for you to maintain your program code. | ||
| + | * Make sure, that every complete sql statement is finished by a semicolon (;). | ||
| ===== The Syntax of DML commands ===== | ===== The Syntax of DML commands ===== | ||
| Zeile 13: | Zeile 16: | ||
| * **FROM** myTable | * **FROM** myTable | ||
| * **WHERE** myCondition. | * **WHERE** myCondition. | ||
| - | * **ORDER BY** myColumn3 | + | * **ORDER BY** myColumn2 |
| - | With SELECT we specify which columns we want to retrieve, with FROM we specify the TABLE from which the columns originate, with WHERE we determine the condition under which the data records are selected, and finally, with ORDER BY + [ASC | DESC] we define the order in which the result set is to be displayed on the screen. | + | With **SELECT** we specify which columns we want to retrieve, with **FROM** we specify the TABLE from which the columns originate, with **WHERE** we determine the condition under which the data records are selected, and finally, with **ORDER BY** + |
| - | ===== Example without precondition | + | ===== Basic example |
| Let's take a table **Customers** as shown in the figure below. | Let's take a table **Customers** as shown in the figure below. | ||
| Zeile 45: | Zeile 48: | ||
| ^ English ^ German ^ | ^ English ^ German ^ | ||
| | precondition | Vorbedingung | | | precondition | Vorbedingung | | ||
| + | | exhaustive | ||
| | clause | Abschnitt | | | clause | Abschnitt | | ||
| | to determine | bestimmen | | | to determine | bestimmen | | ||