1. Inleiding databases en environment ........................................................................................................... 5
1.1 Wat is een informatiesysteem? ..................................................................................................................... 5
1.8 Wat is SQL? .................................................................................................................................................. 14
1.8.1 Eigenschappen SQL............................................................................................................................... 14
1.9 Visuele voorstelling Databank - het ER-Diagram......................................................................................... 15
2. Select and fetch ........................................................................................................................................ 18
2.2 FROM clausule ............................................................................................................................................. 19
2.4 WHERE conditie ........................................................................................................................................... 22
2.4.1 BETWEEN … AND .................................................................................................................................. 23
2.4.2 Hoofdlettergevoeligheid....................................................................................................................... 24
2.4.3 LIKE ....................................................................................................................................................... 25
1
, 2.4.4 AND, NOT, OR ....................................................................................................................................... 26
2.4.5 IS NULL en IS NOT NULL........................................................................................................................ 28
2.4.6 Quotes .................................................................................................................................................. 29
2.5 ORDER BY clausule....................................................................................................................................... 29
2.6 Pagination ................................................................................................................................................... 31
2.6.1 OFFSET .................................................................................................................................................. 32
2.6.2 WITH TIES ............................................................................................................................................. 33
3. Joins: het samenvoegen van tabellen ........................................................................................................ 34
3.3 Non equi join................................................................................................................................................ 38
3.4 Auto join ...................................................................................................................................................... 39
3.4.1 Recursieve relationships ....................................................................................................................... 39
3.5 Outer join ..................................................................................................................................................... 45
3.5.1 LEFT [OUTER] JOIN................................................................................................................................ 46
3.5.2 RIGHT [OUTER] JOIN ............................................................................................................................. 46
3.5.3 FULL OUTER JOIN.................................................................................................................................. 47
4. Numerieke en datum functies ................................................................................................................... 49
4.1 Datums en getallen omzetten van en naar tekst......................................................................................... 49
4.1.1 Datumfuncties: formaat ....................................................................................................................... 49
4.1.2 Conversiefuncties: to_char ................................................................................................................... 50
4.1.3 Taal instellen......................................................................................................................................... 50
4.1.4 Omzetten van numeriek naar tekst ..................................................................................................... 50
4.1.5 Conversiefuncties: to_date.................................................................................................................. 51
4.1.6 Conversiefuncties: to_number ............................................................................................................. 52
4.3 Datum functies ........................................................................................................................................... 54
4.3.1 Huidige datum en tijd ........................................................................................................................... 54
4.3.2 Date_part ............................................................................................................................................. 54
4.3.3 Leeftijd ................................................................................................................................................. 55
4.3.4 Rekenen met datum/tijd ...................................................................................................................... 56
5.2 SUM (ALL DISTINCT expressie) ..................................................................................................................... 58
2
, 5.3 MIN / MAX (expressie) ................................................................................................................................. 58
6. Group by ................................................................................................................................................... 59
6.1 Nesten van analytische functies .................................................................................................................. 61
8. Set operatoren .......................................................................................................................................... 64
8.1 UNION ......................................................................................................................................................... 64
8.1.1 Opgelet! ................................................................................................................................................ 65
9.4 POSITION ..................................................................................................................................................... 69
9.7 TRIM ............................................................................................................................................................ 72
Stuvia customers have reviewed more than 700,000 summaries. This how you know that you are buying the best documents.
Quick and easy check-out
You can quickly pay through credit card or Stuvia-credit for the summaries. There is no membership needed.
Focus on what matters
Your fellow students write the study notes themselves, which is why the documents are always reliable and up-to-date. This ensures you quickly get to the core!
Frequently asked questions
What do I get when I buy this document?
You get a PDF, available immediately after your purchase. The purchased document is accessible anytime, anywhere and indefinitely through your profile.
Satisfaction guarantee: how does it work?
Our satisfaction guarantee ensures that you always find a study document that suits you well. You fill out a form, and our customer service team takes care of the rest.
Who am I buying these notes from?
Stuvia is a marketplace, so you are not buying this document from us, but from seller compie. Stuvia facilitates payment to the seller.
Will I be stuck with a subscription?
No, you only buy these notes for $6.43. You're not tied to anything after your purchase.