Option A - Databases Flashcards

1
Q

What is a database?

A

A database is a system that allows users to store data in a structured way using tables and fields.

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

It also provides _ means for us to _ the data.

A

various,access

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

Data vs Information

A

Data:1. Raw facts2. Unprocessed3. No context4. Just text and numbersInformation:1. Data+context2. Processed and structured3. Interpreted by the user4. Data is given meaning

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

Database vs spreadsheet

A

Spreadsheets are used to manipulate data(using mathematical operations) while databases are used to store data. Databases also have relationships betwen tables and allow the user to make queries to find specific data

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

Database vs informtion system

A

Databases contain data that is used by information systems. Informations systems are complete systems that present data as information.

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

Why are databases needed?

A
  • Data organisation* Data integrity* Data security* Scalability* Perfomance* Data sharing
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Elaborate on data organisation.| As part of the question: Why are databases needed?

A

Help organise data in a structured manner, Allow us to store, retrieve and manipulate data

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

Elaborate on data integrity.| As part of the question: Why are databases needed?

A
  • provide mechanisms to ensure data is accurate and consistent * Needed when many users/applications access the same data
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Elaborate on data security.| As part of the question: Why are databases needed?

A
  • Allow administrators(authorized) to control and access data* this protects sensetive data from unauthorized users
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

Elaborate on scalabilitity.| As part of the question: Why are databases needed?

A

can be scaled by organisations who need to handle large amounts of data

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

Elaborate on perfomance.| As part of the question: Why are databases needed?

A
  • optimized, which allows users to access and manipulate data quickly and efficiently
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

Elaborate on data sharing.| As part of the question: Why are databases needed?

A
  • they enable sharing which allows collaborations across different systems and applications
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What are database transactions?

A

Logical unit of work consisting of one or many operations that are executed together as a single atomic unit.

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

Transactions ensure that either _ operations are _ or _ are _ at all.

A

all,completed,none,executed

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

Transactions ensure that a _ remains in a _ _ even in the event of _ or _ _.

A

database,consistent,state,errors,system,failures

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

Database states refer to the _ of a database at any given _.

A

condition,time.

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

States are used to keep track of _ made to the database.

A

changes

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

Maintaining _ across _ maintains _.

A

consistancy,states,integrity.

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

What are database updates?

A

updates refer to changes made to the database.

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

_ operations maintain _ and integrity.

A

update, consistency

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

Why are locking mechanisms necessary?

A

They prevent conflict and inconsistencies.

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

_ transactions are conducted _.

A

concurrent,sequentially

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

Using _ created at _ allows changes to be _

A

logs,commit,reverted

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

What are the ACID properties of a database transaction?

A

Atomicity, consistency,isolation,durability

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

Explain atomacity.| As part of : What are the ACID properties of a database transactions?

A
  • Atomic: all transactions are executed sucessfully or none are executed at all.* It ensures consistency
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
26
Q

Explain consistency.| As part of : What are the ACID properties of a database transactions?

A
  • Ensures a consistent state of the database is maintained before and after a transaction is executed
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
27
Q

Explain isolation.| As part of : What are the ACID properties of a database transactions?

A
  • transactions are isolated(changes made by one transaction are not visible to the other until completion)
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
28
Q

Explain durability.| As part of : What are the ACID properties of a database transactions?

A
  • Once changes are made they are permanant despite errors or system failure
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
29
Q

Define concurrency.

A

The ability of users to access data simultaneously.

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

Define concurrency control.

A

The process of managing concurrent access to maintain consistency and integrity. Involves implementing mechanisms to prevent conflict.

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

What are the techniques for managing concurrency?

A

Locking, time-stamping, MVCC

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

What do locking mechanisms ensure?| As part of: What are the techniques for managing concurrency?

A

Only one user can make a change at a time. They do this by placing a lock which can not be acessed or modified until it is released.

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

What is time stamping?| As part of: What are the techniques for managing concurrency?

A

Assigning a unique timestamp to each transaction. If simultaneous attempts are made to access data, time stamps are used to determine priority.

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

What is MVCC?

A

Creating multiple versions of data or a record to allow users/applications to modify simultaneously. Users/applications see a version of the data that reflects the state of the database at the time.| MVCC-multi-version concurrency control.

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

What are the functions databases need to be perfomed on them?

A

Query functions and update functions

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

What are query functions?| As part of: functions databases need to be perfomed on databases

A
  • Used to retrieve specific data or a subset of data which meets a specific criteria* SELECT in SQL and FIND in NoSQL* Allow analysis and reporting
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
37
Q

What are update functions?| As part of: functions databases need to be perfomed on them

A
  • Used to modify data in the database* UPDATE and DELETE in SQL and save() and remove() in NoSQL* Essential for maintaining accuracy and integrity of data - allow users to correct errors, update data and remove obsolete data
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
38
Q

What is data validation?

A

Checking whether data entered into a system matches predefined rules and constraints. Ensures that the data entered is correct.

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

What is data verification?

A

Process of checking whether data in the database is accurate, complete and consistent. Ensures that data is a true representation of its original source.

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

Data verification is perfomed on a _ basis.

A

periodic

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

Tools for data verification include _ checks, _ tools or a combination of both.

A

manual, automated

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

What is a DBMS?

A

A DBMS is used to store, manage and retrieve data in a structured and organised manner.

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

What is the purpose of a DBMS?

A

Provide a centralised, controlled and efficient environment for managing data. This enables organisations to access large amounts of data in a consistent and organised way.

44
Q

What are the benefits of using a DBMS?

A
  • Data organisation and management* Data security and privacy* Data consistency and integrity* Data sharing and collaboration* Data analysis and reporting* Data backup and recovery
45
Q

How can a DMBS be used to promote data security?

A

Authentication and access control, data validation, locking, encryption, audit trail, backup and recovery,data masking(masks sensetive data with ficticious data)

46
Q

Define the term schema.| Long answer

A
  • Schema refers to the logical structure of the database
  • defines organisations and relationships amoung data elements or objects
  • defines the type of data that can be stored
  • relationships between different types of data
  • constraints or rules given
  • (blueprint for the database)
47
Q

What is conceptual schema?

A
  • High level representation of the the overall logical structure of the database
  • Provides an overall view of data, abstraction, storage and processing
  • Defines entities attributes and relations
48
Q

What is the physical schema?

A
  • Describes how data is physically stored in the database system. This includes:* File organisation* Indexing methods* Storage structures* Access paths* Deals with low level implementation aspects: optimizing perfomance and storage efficiency
49
Q

What is the logical schema?

A
  • More detailed version of the conceptual schema* Describes how data will be represented and organised in the database. Focuses on:* Data types* Keys* Constraints* Provides the blueprints for database design
50
Q

What is a data dictionary?

A

Collection of metadata which provides information about data in database| Also known as metadata repository or data catelog

51
Q

The data dictionary serves as a _ source for database _, _, and _ . It provides a _ way to document the _ and _ of a database.

A

reference,administrators,developers,users,standardised,structure,content

52
Q

What does a data dictionary include?

A
  • Data elements and descriptions
  • Table and relationship descriptions
  • Business rules and constraints
  • Data access permissions
  • Database management information
53
Q

Elaborate on data element descriptions.

As part of: What does a data dictionary include?

A

data type, length and format of elements

54
Q

Define the term table.

A

Collection of related data in rows and columns. Used to store data in a database and named after the data they contain.

55
Q

Define the term record.

A

A collection of data that represents a single entity in a table. Record=row.

56
Q

Define the term field.

A

A field is a single piece of data stored in a record. It represents a specific attribute or characteristic of the record. Field=column.

57
Q

Define the term primary key.

A

A field or combinations of fields which uniquely identify each record.

58
Q

Define the term secondary key.

A

A field which is not the primary key but can be used to query data in the table.

59
Q

Define the term candidate key.

A

A field which can be used as the primary key but is not currently in use for that purpose.

60
Q

Define the term Composite primary key.

A

A primary key that consists of two or more fields in a table.

61
Q

What does the candidate key ensure?

A

It ensures no two records are identical.

62
Q

What is a composite key used for?

A

Used when a single key is not sufficient to uniquely identify each record.

63
Q

What is the join operation?

A

A join operations combines multiple tables into a single table based on a related field.

64
Q

What is a join operation used for?

A

Data analysis and reporting.

65
Q

What issues can redundant data cause?

A
  • Data inconsistency* Issues with data integrity* Storage costs * Maintainence costs* Security risks
66
Q

Explain data incosistency issues.| As part of: What issues can redundant data cause?

A

If there are repetitions in data copies of the same data may become incosistent.

67
Q

Explain data integrity issues.| As part of: What issues can redundant data cause?

A

Redudant data can compromise data integrity mkaing it more difficult to maintain accuracy and completeness of the data.

68
Q

What is difficult to ensure when redundant data is present?| As part of: What issues can redundant data cause?

A

It is hard to ensure that all copies of data are updated consistently and accurately.

69
Q

Explain storage space issues.| As part of: What issues can redundant data cause?

A

Redundant data takes up more storage in the database which increases costs and reduces perfomance

70
Q

Explain maintenance cost issues.| As part of: What issues can redundant data cause?

A

Redundant data can increase the cost of maintaining and updating the database. More effort is required to keep all copies up to date.

71
Q

Explain security risk issues.| As part of: What issues can redundant data cause?

A

Redundant data increases the number of attack points for malicious actors. If it is not secured it can be easily accessed and manipulated by unauthorized users.

72
Q

What is referential integrity?

A

A concept in a normalised database that ensures that the relationship between tables are maintained and that the data is accurate and consistent across tables. It does this preventing invalid data from being entered into the database.

73
Q

What are the different datatypes?

A

INT,FLOAT,DECIMAL,NUMERIC,CHAR,VARCHAR,NVARCHAR,DATE,TIME,DATETIME,TIMESTAMP and BLOB

74
Q

How can a query provide a view of a database?

A
  • Selecting fields: users can select fields they want to see* Filtering data: data can be filtered based on specific criteria* Sorting data: queries can sort data in a specific way* Grouping data: queries can group data based on specific criteria* Calculating data: queries can make calculations using data based on specific criteria
75
Q

Compare the complexity of simple queries and complex queries.

A
  • Simple queries only involve a single table and a small number of fields* Complex queries involve multiple tables, complex operations and advanced functions
76
Q

Compare the purpose of simple queries and complex queries.

A
  • Simple queries retrieve specific data from a database* Complex queries perform advanced data manipulation and analysis
77
Q

Compare the perfomance of simple queries and complex queries.

A
  • Simple queries are usually faster and more efficient than complex queries* Complex queries are slower and resource intensive, especially if they involve large amounts of data or complex calculations
78
Q

Compare the ease of use of simple queries and complex queries.

A
  • Simple queries are easier to understand* Complex queries require advanced technical skills and knowledge
79
Q

What are the different methods to create a query?

A

GUIs, query languages, stored procedures, data access layers, ORM and web based interfaces.

80
Q

Describe GUIs. As part of: What are the different methods to create a query?

A

Queries can be created using a visual interface. Users can select tables and fields, add filters and sorting criteria and build complex queries using drag and drop options

81
Q

Describe query languages. As part of: What are the different methods to create a query?

A

provide syntax for creating queries

82
Q

Describe stored procedures. As part of: What are the different methods to create a query?

A

Set of precompiled SQL statements that can be executed on a database. Perform specific tasks that meet specific criteria

83
Q

Describe data access layers. As part of: What are the different methods to create a query?

A

provide a set of methods to retrieve data

84
Q

Describe ORM. As part of: What are the different methods to create a query?

A

map tables to object oriented code

85
Q

Describe web based interface. As part of: What are the different methods to create a query?

A

Used to create and execute queries from a browser

86
Q

What are the roles of a database administrator?

A

Design and implmentation, maintenance and perfomance tuning, data security, user management, data modelling and architecture, monitoring and troubleshooting and training and support.

87
Q

Elaborate on design and implementation.

As part of: What are the roles of a database administrator?

A

Responsible for designing and implementing :
* Architecture
* Physical storage
* Organisation
* logical relationships
* Security and access controls

88
Q

Elaborate on data security.

As part of: What are the roles of a database administrator?

A

Using security measures such as encryption, access control rights to ensure security and privacy of databases.

89
Q

Elaborate on user management.

As part of: What are the roles of a database administrator?

A

Responsible for managing user accounts and permissions ensuring appropriate access control mechanisms are in place to ensure security and privacy of data.

90
Q

Elaborate on data modelling and architecture.

As part of: What are the roles of a database administrator?

A

Responsible for defining data models and architecture that support an organisations requirements(goals and objectives).

91
Q

Elaborate on monitoring and troubleshooting.

As part of: What are the roles of a database administrator?

A

Responsible for monitoring databases and troubleshooting any issues that arise.

92
Q

Elaborate on training and support.

As part of: What are the roles of a database administrator?

A

Responsible for providing training and support to other stakeholders to help them effectively understand the data and use the database.

93
Q

What are the methods of data recovery?

A
  • System log
  • Deffered update
  • Mirroring
94
Q

Deffered updates _ _ and reduce the _ of _.

A

improve perfomance, risk, incosistencies

95
Q

What happens in a deffered update?

A

Changes made to a database are not immediately written to a disk but held in a memory until commit. During commit all changes are written in a single batch. This reduces overhead risk and improves perfomance. But data may not be available for other transactions which may lead to concurrency issues.

96
Q

What happens during mirroring?

A

The database is duplicated on a seperate server. The copy can be used to recover the database. This method provides high availablity and fast recovery times but it can be complex to maintain.

97
Q

How can personal data be secured through technological methods?

A
  • Encryption
  • Access controls
  • Secure data storage: Data should be stored in a secure location such as a surveillance room with cameras. Data backups should be stored offsite.
  • Regular audits
98
Q

How can personal data be secured through human methods?

A
  • Employee training
  • Access control
  • Background checks
  • Privacy notices and policies
99
Q

Elaborate on employee training.

A

Employees should be trained on the importance of data privacy as well as company policies and procedures for protecting data.

100
Q

1.

Elaborate on background checks.

A

Employees should undergo background checks to ensure they have a trustworthy background.

101
Q

Elaborate on privacy policies and notices.

A

Policies should be made available to everyone. They should state the organisations privacy practices and procedures.

102
Q

Elaborate on table and relationship descriptions.

As part of: What does a data dictionary include?

A

Helps users understand the structure and organisation of the database

103
Q

Elaborate on business rules and constraints.

As part of: What does a data dictionary include?

A

Data validation rules, default values and other constraints

104
Q

E

Elaborate on Data access permissions.

As part of: What does a data dictionary include?

A

Ensures data is accessed and used appropriately by users

105
Q

Elaborate on database management information.

As part of: What does a data dictionary include?

A

the version of the software, server configuration and other details