Database Administration Fundamentals (WS18SQL1002) – Day 4

We are almost half way done with the course. We have covered how to retrieve data (SELECT), filtering data (WHERE), organizing data (ORDER BY), grouping data (GROUP BY) when using aggregate functions and formatting numeric values (FORMAT()).

SELECT table1.field1, table1.field2...
  table2.field1, table2.field2...
  table3.field1, table3.field2...
FROM table1
INNER|LEFT|RIGHT JOIN table2
  ON table1.shared_field1 = table2.shared_field1
    AND table1.shared_field2 = table2.shared_field2
INNER|LEFT|RIGHT JOIN table3
  ON table1.shared_field1 = table3.shared_field1
    AND table1.shared_field2 = table3.shared_field2...
WHERE condition1
  AND|OR condition2
  ...

Download the class notes for day 4.

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.