Many other websites use databases to store data. For example, X (formerly known as Twitter), might store the following information everytime somebody tweets:
| id | username | twitterHandle | tweetContent | Date | |
|---|---|---|---|---|---|
| 1 | JamesBrolin | @james01 | Yo Yo Yo! Bro! | 12/1/2024 | |
| 2 | MaceyT | @maceyyy | Feeling gorgeous | 12/1/2024 | |
| 3 | LowBro | @thelowbro | Anyone in town for Hula? | 12/5/2024 | |
| 4 | LowBro | @thelowbro | Anyone at all???? | 12/6/2024 | |
| 5 | JamesBrolin | @james01 | Bro Bro Bro! Yo! | 12/1/2024 | |
| 6 | MaxStorm | @lilmista | Coffeeeeeeeee!! | 12/1/2024 | |
| 7 | JamesBrolin | @james01 | Dog ate ma homework! | 12/1/2018 | |
| 8 | MollyAnne | @mollyanne21 | Hello! | 12/1/2018 | |
| 9 | MollyAnne | @mollyanne21 | Hello! | 12/1/2018 |
This is a database table.
| It has 9 records of data. How many records store tweet info from @james01? | |
| Each record has 5 fields. What is the name of the last field in each record? | |
| One of the fields has alphanumeric datatype. Which one? | |
| One of the fields has numeric datatype. Which one? | |
| One of the fields has date datatype. Which one? | |
| Each record has one piece of information that is unique to it. Which field stores this information? |
In order to simulate the above scenario, we need a web server which has a database.
We could buy our own domain eg www.mybestdomain.co.jp - most domains come with a database.
But we have to pay for it!
So, let's use a cool tool which will help us to simulate a webserver with a database.
install the software and take a look at the following tutorial for an explanation how to get started.
Watch the video and let's get an overview of XAMPP's working environment.
Answer the questions on this worksheet.
As in the video, let's use a text editor / IDE to create a .php file.
This short course is going to give you an appreciation of databases! Probably without realising it, you interact with databases everyday. If you're a Facebook user, or a Gmail user, or an Instagram user, or a.... web user - you deal with databases!
database import evidence table integer screenshot record text field double data type