Why do I care what a database is?
description
Transcript of Why do I care what a database is?
![Page 1: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/1.jpg)
A Choose Your Own Adventure Lecture
By Mr. Matzen
![Page 2: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/2.jpg)
Once upon a time, Mr. Matzen Once upon a time, Mr. Matzen had a part time job working at…had a part time job working at…
ABank
AMusicStore
![Page 3: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/3.jpg)
At that music store Mr. Matzen…At that music store Mr. Matzen…
Worked diligently everydayWorked diligently everyday
Had a lot of free time to thinkHad a lot of free time to think
Played FreeCell and listened to musicPlayed FreeCell and listened to music
![Page 4: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/4.jpg)
As the employee of the year As the employee of the year competition approached Mr. Matzen…competition approached Mr. Matzen…
Began looking for a way to winBegan looking for a way to win
Gave up immediately and quitGave up immediately and quit
Starting sabotaging the work of other emplStarting sabotaging the work of other employeesoyees
![Page 5: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/5.jpg)
The first thing Mr. Matzen tried…The first thing Mr. Matzen tried…
Was forgingtimecards tooverstate thehours of other
employees
Was drawingsilly pictures ofthe boss on the
counter andblaming others
![Page 6: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/6.jpg)
Without a job Mr. Matzen was Without a job Mr. Matzen was hired as a bank teller. On his hired as a bank teller. On his
first day of work he wore…first day of work he wore…
Appropriatebusiness attire
A warrior outfit
![Page 7: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/7.jpg)
Mr. Matzen spent his time Mr. Matzen spent his time thinking about…thinking about…
Whether Cheetoswere snacks or
chips
How to make hisjob easier
![Page 8: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/8.jpg)
The customers kept interrupting The customers kept interrupting FreeCell so Mr. Matzen…FreeCell so Mr. Matzen…
Put out theclosed sign
an hour early
Decided to workon making hisjob easier, sohe could play
![Page 9: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/9.jpg)
After several long windedAfter several long windeddebates Mr. Matzen started…debates Mr. Matzen started…
Writing a letterto Frito Lay
Yelling atcustomers to
get theiropinions
![Page 10: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/10.jpg)
Unfortunately the boss showed Unfortunately the boss showed up unexpectedly and Mr. Matzen up unexpectedly and Mr. Matzen
was fired on the spot.was fired on the spot.
Let’s try adifferentcareer.
![Page 11: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/11.jpg)
Mr. Matzen decided that the best Mr. Matzen decided that the best way to win the competition was…way to win the competition was…
Working lotsof overtime
Creating abetter wayto sort the
merchandise
PLAN A PLAN B
![Page 12: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/12.jpg)
The hours of overtime took a toll The hours of overtime took a toll on Mr. Matzen’s grades so he on Mr. Matzen’s grades so he had to reconsider his decision.had to reconsider his decision.
PLAN B
![Page 13: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/13.jpg)
At that time the store did not use At that time the store did not use a computer to monitor inventory. a computer to monitor inventory. The store paid $3 for each CD The store paid $3 for each CD
and $5 for each DVD. The sales and $5 for each DVD. The sales price was decided by the clerk. price was decided by the clerk. All CDs and DVDs were placed All CDs and DVDs were placed
alphabetically in the store.alphabetically in the store.
![Page 14: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/14.jpg)
What were some of the What were some of the problems with this system?problems with this system?
Don’t know what was in inventory.Don’t know what was in inventory.
Don’t know the quantity in inventory.Don’t know the quantity in inventory.
Paid the same for Eminem and Paula AbdulPaid the same for Eminem and Paula Abdul
Inconsistent pricing of identical items.Inconsistent pricing of identical items.
All styles of music are mixed together, All styles of music are mixed together, making it more difficult to sort and more making it more difficult to sort and more difficult to find items.difficult to find items.
![Page 15: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/15.jpg)
What could Mr. MatzenWhat could Mr. Matzendo to fix these problems?do to fix these problems?
1. Create a table with Microsoft Word
2. Create a table with Excel
3. Create a table with Access
![Page 16: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/16.jpg)
There is a better answer.There is a better answer.
![Page 17: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/17.jpg)
A database is correct but why?A database is correct but why?
A table in a database appears similar to a A table in a database appears similar to a table in spreadsheet, but the function is table in spreadsheet, but the function is different.different.
A spreadsheet is used to do mathematic A spreadsheet is used to do mathematic calculations on the data assembled.calculations on the data assembled.
A database is used to do easy searches A database is used to do easy searches (queries) of the data assembled.(queries) of the data assembled.
![Page 18: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/18.jpg)
Knowing he needed to use a Knowing he needed to use a database Mr. Matzen…database Mr. Matzen…
Researcheddatabasescarefully
Dove inhead first to
Access
![Page 19: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/19.jpg)
During the research he read During the research he read about 4 database components.about 4 database components.
TableTable – a collection of related information – a collection of related information organized in columns and rowsorganized in columns and rows
Query – an instruction to do a job, such as Query – an instruction to do a job, such as locating records with certain characteristicslocating records with certain characteristics
Form – a database object you can use to Form – a database object you can use to enter, edit, view, and print database info.enter, edit, view, and print database info.
Report – a database object that presents Report – a database object that presents database information in an accessible waydatabase information in an accessible way
![Page 20: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/20.jpg)
Mr. Matzen opened Access and Mr. Matzen opened Access and became frustrated so he…became frustrated so he…
SangKaraoke to
let off steam
Decided toresearch
databases
![Page 21: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/21.jpg)
Boo himoff stage.
Applaudloudly.
![Page 22: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/22.jpg)
Fine. You don’t like my singing? Fine. You don’t like my singing? Then take some notes over…Then take some notes over…
Databases
![Page 23: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/23.jpg)
The fame quickly went to Mr. The fame quickly went to Mr. Matzen’s head and he…Matzen’s head and he…
Tried acomedyroutine
Tried hishand atacting
![Page 24: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/24.jpg)
Quit yourjob. A star
is born.
Get back todatabases.
![Page 25: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/25.jpg)
Quit yourjob. A star
is born.
Get back todatabases.
![Page 26: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/26.jpg)
After quitting his job Mr. Matzen After quitting his job Mr. Matzen realized he had no talent and…realized he had no talent and…
Looked foranother job
Began thedatabaseresearch
![Page 27: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/27.jpg)
Creating a table was the first step.Creating a table was the first step.The rows are Records (all the data for an The rows are Records (all the data for an individual item)individual item)
The columns are Fields (the different types The columns are Fields (the different types of data we want to know)of data we want to know)
Record
Field
![Page 28: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/28.jpg)
What fields need to be included What fields need to be included in the CD/DVD database?in the CD/DVD database?
ArtistArtist
AlbumAlbum
Price Buy UsedPrice Buy Used
Price Buy NewPrice Buy New
Price Sell UsedPrice Sell Used
Price Sell NewPrice Sell New
Number of CopiesNumber of Copies
Number of Copies Number of Copies DesiredDesired
Trade ValueTrade Value
CD or DVDCD or DVD
StyleStyle
![Page 29: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/29.jpg)
Mr. Matzen entered all of this Mr. Matzen entered all of this information into a database andinformation into a database and
Everythingworked
perfectly
He forgotone little
thing
![Page 30: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/30.jpg)
Mr. Matzen started bragging Mr. Matzen started bragging about this system to everyone.about this system to everyone.
Soon he atehis words.
He even helda press
conference.
![Page 31: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/31.jpg)
At this press conference, a At this press conference, a reporter asked Mr. Matzen…reporter asked Mr. Matzen…
What aboutspecial editions?
Why are youso tall?
![Page 32: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/32.jpg)
Now tell usabout theSpecialEditions.
I’m so confused.Give us morenotes please.
![Page 33: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/33.jpg)
What about Special Editions or What about Special Editions or Remakes? How do you Remakes? How do you
differentiate between two items differentiate between two items with the same name?with the same name?
Give usa hint.
No idea. Giveus the answer.
![Page 34: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/34.jpg)
Should we add a field or change Should we add a field or change a field we already have?a field we already have?
Change Add
![Page 35: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/35.jpg)
Should we add a word or a Should we add a word or a number?number?
Word Number
![Page 36: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/36.jpg)
What number should we add?What number should we add?
Create anumber
Barcode
![Page 37: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/37.jpg)
The barcode is the key. An item The barcode is the key. An item is specifically identified by that is specifically identified by that number. It is unique to each number. It is unique to each version or edition of an item.version or edition of an item.
So why dowe care?
What is abarcode?
![Page 38: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/38.jpg)
Here is a barcode.Here is a barcode.
Please lectureabout Wal-Martand barcodes
Let’s get backto databases
![Page 39: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/39.jpg)
The story of Wal-MartThe story of Wal-Mart
Now on todatabase
![Page 40: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/40.jpg)
Why do you care about barcodes? Why do you care about barcodes? So we can understand… So we can understand…
PrimaryKeys
Wal-Mart’sSuccess
![Page 41: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/41.jpg)
A primary key is the part of a A primary key is the part of a database unique to one item. database unique to one item.
When connecting two databases When connecting two databases the primary key is needed as a the primary key is needed as a
reference to match items.reference to match items.
Enough talk.Let’s get on
the computers.
How aboutanother
example.
![Page 42: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/42.jpg)
At that time the bank tracked At that time the bank tracked accounts by social security accounts by social security
number. Last name, first name, number. Last name, first name, social security number, and social security number, and
address were the only address were the only information stored on the information stored on the
computer.computer.
![Page 43: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/43.jpg)
What were some of the What were some of the problems with this system?problems with this system?
No room for multiple account owners.No room for multiple account owners.
Does not differentiate between account Does not differentiate between account types.types.
Does not specify the account.Does not specify the account.
![Page 44: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/44.jpg)
What could Mr. MatzenWhat could Mr. Matzendo to fix these problems?do to fix these problems?
1. Alter a table with Microsoft Word
2. Alter a table with Excel
3. Alter a table with Access
![Page 45: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/45.jpg)
There is a better answer.There is a better answer.
![Page 46: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/46.jpg)
A database is correct but why?A database is correct but why?
A table in a database appears similar to a A table in a database appears similar to a table in spreadsheet, but the function is table in spreadsheet, but the function is different.different.
A spreadsheet is used to do mathematic A spreadsheet is used to do mathematic calculations on the data assembled.calculations on the data assembled.
A database is used to do easy searches A database is used to do easy searches (queries) of the data assembled.(queries) of the data assembled.
![Page 47: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/47.jpg)
Knowing he needed to use a Knowing he needed to use a database Mr. Matzen…database Mr. Matzen…
Researcheddatabasescarefully
Dove inhead first to
Access
![Page 48: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/48.jpg)
During the research he read During the research he read about 4 database components.about 4 database components.
TableTable – a collection of related information – a collection of related information organized in columns and rowsorganized in columns and rows
Query – an instruction to do a job, such as Query – an instruction to do a job, such as locating records with certain characteristicslocating records with certain characteristics
Form – a database object you can use to Form – a database object you can use to enter, edit, view, and print database info.enter, edit, view, and print database info.
Report – a database object that presents Report – a database object that presents database information in an accessible waydatabase information in an accessible way
![Page 49: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/49.jpg)
Mr. Matzen opened Access and Mr. Matzen opened Access and became frustrated so he…became frustrated so he…
Took a trip toGraceland
Decided toresearch
databases
![Page 50: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/50.jpg)
All ShookUp At The
King’sGrave.
HeartbreakHotel With
JoshuaJackson.
![Page 51: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/51.jpg)
SuspiciousMinds.
Get back todatabases.
![Page 52: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/52.jpg)
Don’t BeCruel.
Get back todatabases.
![Page 53: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/53.jpg)
Creating a table was the first step.Creating a table was the first step.The rows are Records (all the data for an The rows are Records (all the data for an individual item)individual item)
The columns are Fields (the different types The columns are Fields (the different types of data we want to know)of data we want to know)
Record
Field
![Page 54: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/54.jpg)
What fields need to be included What fields need to be included in the bank account database?in the bank account database?
Account numberAccount number
Primary Owner 1Primary Owner 1
Primary Owner 2Primary Owner 2
Secondary Owner 1Secondary Owner 1
Secondary Owner 2Secondary Owner 2
Account typeAccount type
Social Security Social Security NumberNumber
AddressAddress
Phone NumberPhone Number
![Page 55: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/55.jpg)
The account number is used to The account number is used to identify the record instead of the identify the record instead of the
social security number. In social security number. In Access it can be the primary key.Access it can be the primary key.
PrimaryKey?
Access?
![Page 56: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/56.jpg)
Yes Access. You must have Yes Access. You must have known that was what all this run known that was what all this run
around was leading to.around was leading to.
Right, so whatis a primary key.
I thought itwas leadingto a free day.
![Page 57: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/57.jpg)
Listen! Just drop the whole free Listen! Just drop the whole free day thing and get on with it.day thing and get on with it.
PrimaryKey
PrimaryKey
I’m tired of giving you choices.
![Page 58: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/58.jpg)
Why would you wear this to work?Why would you wear this to work?
Just a joke.We can be
serious now.
I see nothingwrong with this
outfit.
![Page 59: Why do I care what a database is?](https://reader036.fdocuments.us/reader036/viewer/2022062518/568147a4550346895db4defa/html5/thumbnails/59.jpg)
Nothing wrong. You just are Nothing wrong. You just are wasting time now.wasting time now.
On to a banking scenario.