Introduction To Dtabase Flashcards

1
Q

Drawbacks in using file system to store data

A

• Data redundancy and inconsistency
• Difficulty in accessing data
• Data isolation
• Integrity problems
• Atomicity of updates
- Failures may leave database in an inconsistent state with partial updates carried out
- Example: Transfer of funds from one account to another should either complete or not happen at all
• Concurrent access by multiple users
- Concurrent access needed for performance
- Uncontrolled concurrent accesses can lead to inconsistencies
Security problems
• Example: Two people reading a balance (say 10,000 Naira) and updating it by withdrawing money (say 5,000 Naira each) at the same time
• Security problems
- Hard to provide user access to some, but not all, data

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

Mention levels or abstraction

A

• Physical level: describes how a record (e.g., instructor) is stored.
• Logical level: describes data stored in database, and the relationships among the data.
type instructor = record
ID: string; name: string;
dept_name : string; salary: integer; end;
• View level: application programs hide details of data types. Views can also hide information (such as an employee’s salary) for security purposes.

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

What is an instance

A

Instance - the actual content of the database at a particular point in time

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

What is a aschema

A

A schema is like a plan or layout for how data is stored and organized in a database.

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

Mention types of schemes

A

Logical Schema - the overall logical structure of the database

• Physical schema- the overall physical structure of the database

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

What is physical data independence

A

Physical Data Independence - the ability to modify the physical schema without changing the logical schema

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

Describe data models

A

• A collection of tools for describing
- Data
- Data relationships
- Data semantics
- Data constraints

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

Give the meaning and uses of:
- Relational databases
- DML
- DDL
- DBMS

A

Certainly! Here’s the meaning and uses of each term:

  1. Relational Databases:
    • Meaning: Relational databases are a type of database management system (DBMS) that organizes data into tables, with rows representing individual records and columns representing attributes or fields.
    • Uses: Relational databases are widely used for storing and managing structured data in various applications, including business applications, e-commerce websites, banking systems, and more. They provide efficient methods for querying, updating, and managing data through Structured Query Language (SQL).
  2. DML (Data Manipulation Language):
    • Meaning: DML is a subset of SQL that allows users to manipulate data stored in a database. It includes commands such as SELECT (retrieve data), INSERT (add new data), UPDATE (modify existing data), and DELETE (remove data).
    • Uses: DML is used to perform operations on data within a relational database. It allows users to retrieve specific information, add new records, update existing records, and delete unwanted data, enabling data manipulation and maintenance.
  3. DDL (Data Definition Language):
    • Meaning: DDL is a subset of SQL that allows users to define and manage the structure of a database schema. It includes commands such as CREATE (create new database objects), ALTER (modify existing objects), and DROP (delete objects).
    • Uses: DDL is used to define the structure of database objects such as tables, indexes, views, and constraints. It allows users to create, modify, and delete database objects, enabling the management and organization of data within a database.
  4. DBMS (Database Management System):
    • Meaning: A DBMS is a software system that allows users to create, manage, and interact with databases. It provides tools and utilities for storing, retrieving, updating, and securing data, as well as managing database transactions, concurrency, and recovery.
    • Uses: DBMSs are used in various applications and industries to store and manage structured and unstructured data efficiently. They provide functionalities for data organization, access control, data integrity, and data security, making them essential for modern data-driven applications and systems. Popular examples of DBMSs include MySQL, PostgreSQL, Oracle, SQL Server, and SQLite.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

Distinction between instance and schema

A

In summary:

  • An instance refers to the actual data stored in a database at a specific point in time, including the records, tables, and relationships between them.
  • A schema, on the other hand, defines the logical structure or blueprint of the database, outlining the organization, structure, and relationships of the data within the database, including tables, columns, data types, constraints, and relationships between tables.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

What is query processing

A

Query processing is the process of executing a user’s request for information from a database. It involves understanding the request, figuring out the most efficient way to get the data, and then retrieving or modifying the data as requested.

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

Difference between logical and physical design

A

In simple terms:

  • Logical Design: Defines the structure and relationships of data without considering technical implementation details.
  • Physical Design: Specifies how the logical design will be implemented in the database system, considering factors like storage, indexing, and performance optimization.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly