SQL Flashcards

1
Q

an organized collection of structured information, or data, typically stored electronically in a computer system

A

Databases

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

What does DBMS stand for?

A

database management system

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

Serves as an interface between the database and its end users or programs, allowing users to retrieve, update, and manage how the information is organized and optimized. Also facilitates oversight and control of databases, enabling a variety of administrative operations such as performance monitoring, tuning, backup, and recovery.

A

database management system

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

type of database that stores and provides access to data points that are related to one another. based on the relational model, an intuitive, straightforward way of representing data in tables. Stores data into relations (tables)

A

Relational Databases

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

What does SQL stand for?

A

Structured Query Language

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

a programming language used by nearly all relational databases to query, manipulate, define data, and to provide access control

A

SQL

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

translations on high level queries into low level expressions that can be used at physical level of file system, query optimization and actual execution of query to get the result.

A

Query Processing

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

core part of a DBMS that provides access to the data in a database managed by the DBMS.

A

DBMS Engine

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

What are the sublanguages of SQL?

A

DDL, DML, DCL, TCL

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

What is DDL?

A

Data Definition Language

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

What does DDL do?

A

Used for creating database tables, defining the database structure

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

what are the commands for DDL?

A

Create
Alter
Drop

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

what is DML?

A

Data Manipulation Language

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

What does DML do?

A

All operations on individual rows

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

what are the commands for DML?

A

Select
Insert
Update
Delete

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

what is DCL?

A

Data Control Language

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

What does DCL do?

A

For DB admin, allow users to have different permissions

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

what are the commands for DCL?

A

Grant

Revoke

19
Q

what is TCL?

A

Transaction Control Language

20
Q

What does TCL do?

A

Concerned with grouping SQL commands and executing them as a batch

21
Q

what are the commands for TCL?

A

Commit
Savepoint
Rollback
Transact

22
Q

refers to the SQL variant used by a database vendor

A

SQL Dialect

23
Q

refer to the different categories of the statements/commands in SQL

A

SQL Sublanguages

24
Q

Used for setting guidelines in what data belongs to a column

A

Constraints

25
Q

what are the Constraint types

A
Data type
Not Null
Unique
Check
Primary Key - unique and not null
Foreign Key
26
Q

used to uniquely identify a data set, and also to establish relationships between entities

A

Keys

27
Q

what are the different keys?

A

Candidate key
Primary key
Foreign Key
Composite Key

28
Q

Minimal set of columns in a table that every other column depends on

A

Candidate key

29
Q

Unique identifier for a row in a table

A

Primary key

30
Q

A set of columns which hold the values of some primary key to establish a relationship to another row

A

Foreign Key

31
Q

Any key that’s more than one column

A

Composite Key

32
Q

Ensures the accuracy and consistency of data within a relationship

A

Referential integrity

33
Q

Relationships in SQL : This means that two sets of data are unique to each other

A

1:1

34
Q

Relationships in SQL : This means that one set of data can have many instances of the other data set

A

1:m

35
Q

Relationships in SQL : This means that both data sets can have many instances of each other

A

m:m

36
Q

Relationships in SQL : Put both entities in the same table or separate the entities in two tables with a FK reference that is Unique and Not Null

A

1:1

37
Q

Relationships in SQL : Two tables, FK that is not unique

A

1:m

38
Q

Relationships in SQL : 3 tables one of which is a join/junction table

A

m:m

39
Q

shows the relationships of entity sets stored in a database. Visual representation of your DB design.

A

ER Diagram

40
Q

Designing a database in a certain way to ease data management

A

Normalization

41
Q

What are the normal forms?

A

1NF
2NF
3NF

42
Q

Normal Forms: Atomic Values, No repeating groups of columns, No duplicate rows

A

1NF

43
Q

Normal Forms: Has to be 1NF, NO partial dependencies, No composite keys mean you’re 2NF by default

A

2NF

44
Q

Normal Forms: Has to be 2NF, NO transitive dependencies

A

3NF