19.1. SQL Part 1 - Introduction and Azure Data Studio¶
Note
As you read through the articles in the SQL lessons, you may find that you want to try out the queries the authors describe.
You have access to a database called AdventureWorks2019
if you would like to try out some of these queries.
Doing so is additional practice separate from the exercises.
Read the following articles, follow along where instructed:
19.1.1. Introduction to SQL¶
SQL Basics — Hands-On Beginner SQL Tutorial Analyzing Bike-Sharing
As you read this article, skip the “Installation and Setup” section.
Stop at the “Join” section.
The article uses SQLite3, while we are using T-SQL. The biggest difference in sytax is that T-SQL uses
TOP
instead ofLIMIT
.
Additional Resources
Optional reading:
19.1.2. Check Your Understanding¶
Question
What does SQL stand for?
Question
Why do we use SQL?
Question
Is Microsoft Excel a database?
True
False
Question
How are a Relational Database’s items structured?
Question
What does the *
return?
SELECT *
FROM TABLE;
Question
Match the following terms:
Table |
Command which is used to retrieve the desired information. |
Row |
Collection of data. |
Column |
Known as a tuple/record. |
Query |
Represents a unique field. |
Question
Match the following Keyword with its definition:
|
Filters the data that falls into the defined begin and end value. |
|
Sort the data according to the specified column. |
|
Filter the data according to specified conditions. |
|
Used to eliminate duplicate data from the specified columns. |
|
Used to retrieve data from the data table. |
|
Specify the table name to retrieve data from. |
Question
What does the Keyword AS
do?
Question
In T-SQL what expression would return the first 50 rows?