SQL Flashcards

1
Q

SQL

A

Structured Query Languages

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

SQL Databases

A
  1. MySQL
  2. Microsoft SQL Server
  3. BigQuery [Google Data Cloud]
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Syntax

A

A set of guidelines unique to every programming language. This structured language includes words, symbols, and punctuation, as well as their proper placement.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

SQL Query Syntax

A

SELECT

FROM

WHERE

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

SELECT

A

Use SELECT to choose the columns you want to return.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

FROM

A

Use FROM to choose the tables where the columns are located.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

WHERE

A

Use WHERE to filter for certain information.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Query

A

A request for data or information from a database.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Semicolon (;)

A

This is known as a statement terminator. It’s used to end a statement. Though part of the American National Standards Institute (ANSI) SQL-92’s recommended common syntax standard, it isn’t universally used or enforced by all databases.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Comments

A

You can place comments alongside a SQL query to help you remember what the name represents. This is done using either dashes (–), /* and / or a hash symbol (#). Not all databases support the use of / and */ and the hash symbol.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

/* and */

A

Used to place a comment alongside a SQL query for name referencing. Not used by all databases.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

#

A

Used to place a comment alongside a SQL query for name referencing. Not used by all databases. [MySQL doesn’t recognise the #.]

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

A

Used to place a comment alongside a SQL query for name referencing. Most commonly used.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

SELECT*

A

The asterick selects all of the columns in a table. Use sparingly and with caution.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

Aliases

A

You can assign a new name to a column using the AS command. An example of this would be “field1 AS last_name”. An alias doesn’t change the actual name of a column in a database.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly