Chapter 2 Flashcards

1
Q

What is wrong with the following query?

Select FirstName, LastName
From Employees
Where PostalCode Between 98900-98911;

a. The query should end with a colon
b. The PostalCode column should be displayed after the Select keyword.
c. the query is missing a comma
d. The hyphen causes an error.

A

d. The hyphen causes an error.

The hyphen should be replaced by the AND operator.

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

What keyword should you use to display columns?

a. Between
b. Where
c. Row
d. Select

A

d. Select

The select keywords is used to tell the database which columns to display.

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

Which of the following is not a where clause operator?

a. IS NULL
b. AND
c. SELECT
d. =

A

c. Select

The SELECT keyword is used to tell the database which columns to display.

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

Which of the following should you use to display all columns in a table?

a. Semicolon
b. Keys
c. Asterisk
d. Syntax

A

c. Asterisk

An asterisk after the SELECT keyword indicates that you want to see all of the columns displayed.

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

What keyword should you use to tell the database which table to retrieve columns from?

a. WHERE
b. SYBASE
c. FROM
d. SET

A

c. From

The from keyword tells the database to look in the specified table.

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