Commands 1 Flashcards

1
Q

extracts data from a database

A

SELECT

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

updates data in a database

A

UPDATE

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

Deletes data from the database

A

DELETE

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

inserts new data into a database

A

INSERT INTO

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

creates a new database

A

CREATE DATABASE

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

modifes a database

A

ALTER DATABASE

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

creates a new table

A

CREATE TABLE

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

modifies a table

A

ALTER TABLE

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

deletes a table

A

DROP TABLE

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

creates an index (search key)

A

CREATE INDEX

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

Deletes an Index

A

DROP INDEX

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

used to sort the result-set in ascending or descending order.

A

ORDER BY

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

clause that lets you specify the maximum number of rows the result set will have.

A

LIMIT

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

specifies where to start from.

A

OFFSET

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

Used to select values within a range

A

BETWEEN

Values must be separated by the and keyword

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

used to specify a range of conditions, any of which can be matched

A

IN

17
Q

Special operator used with the WHERE clause to search for a specific pattern in a column.

A

LIKE

LIKE is a predicate

18
Q

used to specify a set of characters, any one of which must match a character in the specified position

A

The wildcard bracket [ ]

19
Q

keyword in SQL that allows you to rename a column or table using an alias.

A

AS

20
Q

aggregate function that returns the average value for a numeric column.

A

AVG()

21
Q

function that takes the name of a column as an argument and counts the number of rows where the column is notNULL.

A

COUNT()

22
Q

clause that indicates you want to filter the result set to include only rows where the followingconditionis true.

A

WHERE

23
Q

function that takes the name of a column as an argument and returns the smallest value in that column.

A

MIN()

24
Q

function that takes the name of a column as an argument and returns the largest value in that column.

A

MAX()

25
Q

One or more values in adatabase tablethat identifyrecordsin another table.

A

Foreign key

26
Q

One or morefieldsin adatabase tablewhose values are guaranteed to be unique for eachrecord, i.e., whose values uniquely identify the entry.

A

Primary key

27
Q

What clause gives you the month name?

A

MONTHNAME()

28
Q

Used to combine results that appear from multiple SELECT statements and filter duplicates.

A

Union

29
Q

Clause that stores the result of a query in a temporary table using an alias

A

With