Questions I need to review on quizzes Flashcards

(17 cards)

1
Q

statement: insert new data

A

INSERT INTO

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

select entries where a column value is between two values

A

SELECT * FROM <table name> WHERE <col name> BETWEEN <val 1> AND <val 2>

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

returns only different values

A

SELECT DISTINCT

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

sorts result set

A

ORDER BY

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

insert new record

A

INSERT INTO <table name> VALUES (<value * as many columns to fill>)

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

insert new value in a specific column

A

INSERT INTO <table name> (<col name>) VALUES (<value>)</value>

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

change column value from a specific column value

A

UPDATE <table name> SET <col name>=<new> WHERE <col name>=<old></old></new>

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

delete where column is a specific value

A

DELETE FROM <table name> WHERE <col name> = <value></value>

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

return number of records

A

SELECT COUNT(*) FROM <table name>

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

limit the returned items to a number of columns

A

SELECT * FROM <table name> LIMIT <numer></numer>

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

join that extracts data of matching rows from both tables

A

full outer join

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

blob stands for

A

binary large object

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

a cursor in sql is

A

read only

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

data type used to store JSON objects

A

NVarchar

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

update auto increment value of a table

A

ALTER TABLE <table name> AUTO_INCREMENT = <value></value>

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

grab current time of the system

A

current_timestamp()