IT 231: IT and Application (BBM)
By the end of this introductory chapter, you will be able to:
What is a Database? 📊
A database is a structured, organized collection of data, stored and accessed electronically. Think of it as a highly efficient digital filing cabinet.
The ability to store, manage, and retrieve data efficiently is critical for any organization, from a small startup to a global enterprise.
Take 1 minute. List every organisation that holds a record about you in a database. Think about:
Hands up if you listed more than 10. Each of those is a database, and each one stores your name in its own way.
Before databases, data was stored in separate, application-specific files.
This led to major problems:
The database approach centralizes data, treating it as a shared organizational resource.
⚡ Key Idea: A single, integrated repository of data is managed by a controlling agent, the DBMS.
Which approach fits each case? Give one reason.
1. A teacher's own marks sheet for one class → A file is fine: one user, small data, nothing shared.
2. A bank with 50 branches and a mobile app → Database: many users at once, security, no duplicate balances.
3. An online shop's orders, stock and payments → Database: the same data is shared by sales, store and accounts.
4. Your personal shopping list → A file (or paper) is fine: a DBMS would cost more than it saves.
.xls format..xls sheet holds at most 65,536 rows. Each test used several rows, so a template held only about 1,400 cases. Extra rows were silently cut off.Lesson: a spreadsheet is a file, not a database. A DBMS would have stored every row, or rejected the load with an error.
What is a DBMS? 🧠
A Database Management System (DBMS) is the software that interacts with users, applications, and the database itself to capture and analyze data.
It's the gatekeeper that manages everything related to the database.
Examples: MySQL, PostgreSQL, Oracle, Microsoft SQL Server, MongoDB
A database system is more than the data. It has five parts that work together.
Exam tip: list all five and give one example of each.
Use the data through apps and forms, without seeing the tables.
e.g. a bank teller, or you checking your balance in an app.
Write the programs and screens that read and update the database.
e.g. the team that builds a wallet app's payment screen.
Designs and looks after the database: access rights, backups, recovery and performance.
e.g. the IT officer who restores data after a crash.
A database model defines the logical structure of a database. It determines how data is stored, organized, and manipulated.
Data in tables (rows/columns). The most common model. (e.g., MySQL)
Tree-like structure with parent-child relationships.
Flexible models for big data. (e.g., Document, Key-Value, Graph)
We will explore these in more detail later in the unit.
🔍 What is Business Intelligence?
BI refers to the technologies, applications, and practices for the collection, integration, analysis, and presentation of business information. The purpose of BI is to support better business decision-making.
Databases are the foundation of BI. They store the raw data that BI tools turn into actionable insights, reports, and dashboards.
Where do you see databases in action?
A powerful DBMS manages millions of these transactions securely and instantly.
Other examples: Your university's student information system, Daraz's product catalog, a hospital's patient records.
Think: which file-system problems does this avoid? → Redundancy (no extra copies) and inconsistency (one up-to-date source).
Revise the Introduction to Databases and Data Concepts notes before writing these answers.
In computing, data isn't just a random mess. It's organized in a logical pyramid or hierarchy.
Think of it like building with LEGOs: you start with the smallest bricks and build up to a complete structure.
Character → Field → Record → File → Database
The most basic logical element.
S9@A group of related characters representing a characteristic of an entity.
Sita1500sita@example.comEvery field has a data type. It tells the DBMS what values are allowed.
Text: FirstName = Sita
Whole number: StudentID = 10123
Decimal number: Price = 1500.50
Date: AdmissionDate = 2024-09-15
Yes/No: FeePaid = Yes
❓ Phone number: number or text? Text. We never do maths on it, and it can start with 0 or +977.
Record: A collection of related fields that describe a single entity (a person, place, thing, or event).
Field: StudentID → Value: 10123
Field: FirstName → Value: Anjali
Field: LastName → Value: Gurung
Field: Major → Value: BSc.CSIT
A primary key is a field (or a combination of fields) whose value is unique for every record and is never empty.
Real-world keys: a citizenship number, a bank account number, a vehicle registration number, or a product SKU.
For each table, which field should be the primary key?
1. Students: Name, Phone, StudentID, Address → StudentID
2. Vehicles: Owner, Colour, Registration number, Model → Registration number
3. Products: Name, Price, SKU code, Brand → SKU code
4. Bank accounts: Holder name, Branch, Account number → Account number
5. Employees: Name, Email, Date of birth, EmployeeID → EmployeeID (people can change their email address)
6. Flights: Flight number, Date, Pilot → Flight number + Date together. The same flight number flies every day, so one field isn't enough. This is a composite key.
Before any data goes in, the designer describes every field. This "data about data" is metadata.
StudentID · whole number · 5 digits · primary key, required
FirstName · text · up to 20 characters · required
Phone · text · exactly 10 digits
AdmissionDate · date · cannot be in the future
FeePaid · yes/no · starts as "No"
98-41. What happens? → The DBMS rejects it: not 10 digits.A collection of related records.
Example: A `Students.csv` file would contain the records for all students in the university.
An integrated collection of related files (tables).
Example: A `UniversityDB` would contain the `Students` file, `Courses` file, and `Faculty` file, all linked together.
From a single character to an entire database.
A bank keeps customer accounts. Name the level of each item.
1. The letter R in "Ram" → Character
2. AccountNo: 0012345 → Field
3. [0012345, Ram Shrestha, Savings, Rs 52,000] → Record
4. All the bank's customer accounts → File (Table)
5. Accounts + Loans + Transactions, linked together → Database
Extension · if time permits
In English text, one character usually takes 1 byte.
Nepali twist: Devanagari letters take 3 bytes each in the common UTF-8 encoding. So "सीता" (4 characters) needs 12 bytes, while "Sita" needs only 4.
Organizing data is the first step. The real goal is to create meaning.
This leads us to the crucial difference between three key terms...
Data ➡️ Information ➡️ Knowledge
Raw, unorganized facts. Meaningless on its own.
45
NPR
Momo
Data organized into a meaningful context.
"The price of one plate of momo is NPR 45."
Actionable insights derived from information.
"By pricing our momos at NPR 45, we are 10% cheaper than competitors, which could increase our sales volume."
Decisions are only as good as the data behind them.
Garbage in, garbage out: a fast database full of bad data still gives bad answers.
Accurate, complete, timely, relevant or consistent: which one is missing?
1. A customer's age is stored as 245. → Accurate
2. Half of the sales records have no date. → Complete
3. Last month's stock report is used to reorder today. → Timely
4. Sales says "Bikash", Accounts says "Bikas". → Consistent
5. Favourite colour is used to set a customer's loan limit. → Relevant
Lesson: 1 pound-force second = 4.45 newton-seconds, so every value was off by that factor. A number without its unit is only data; with an agreed unit it becomes information.
Let's apply this to a real-world scenario in Nepal.
150, "Laptop Bag", "Pokhara", "2023-11-10"
On November 10th, 2023, 150 units of "Laptop Bag" were sold to customers in Pokhara.
Sales of laptop bags in Pokhara tripled during the Gandaki IT Fair. For the next fair, we should pre-stock inventory in our Pokhara hub and run targeted ads to capitalize on this trend.
1. "2,40,000" Data
2. "Our New Road shop sold Rs 2,40,000 of goods in Dashain week" Information
3. "Dashain week sales are double a normal week, so hire 2 temporary staff next year" Knowledge
4. "Kathmandu, 31, 14:00" Data
5. "Only 12 units of the blue school bag are left in stock" Information
6. "At this rate we run out by Friday, so reorder today" Knowledge
Teaching content © Arjan KC. Third-party media remain the property of their owners.
Questions?
Read the full notes: An Introduction to Databases · Data Concepts: Characters to Databases
Next deck: Unit 5 Session 2: File Systems vs Models