Repository for the project of the Databases course, at FEUP.
The goal of this project was to design, create and populate a database, from an adequate theme. This means creating the conceptual model (first delivery), converting it to a relational model and an SQL schema and populating the database with adequate data.
The theme that we chose was a database for a live video streaming service (inspired and heavily based on Twitch).
- Clone the repository
- Follow Twitch's API tutorial to get a client ID and an app access token
- Open
final-delivery/parser
- Place your client ID and your token where marked in
request.py
- Run the first script:
python request.py ALL
- (Optional) Fill a file
population_files/json/chat_messages.json
with possible chat messages (it should be a standard JavaScript object, whose keys are the streamer's names and the values are the lists with the respective chat messages) - Run the second script:
python parse.py
- When choosing a theme, if you want to fill the database with real information, find an API that works with the theme (if you don't find later, you're kind of screwed)
- Using an API to populate the database is kind of easy. You just need the
request
module of Python to handle the requests for you - If you don't care about veracity, we strongly advise using the Faker module of Python, which generates random data, like names, emails and dates (the documentation is a little obscure, but, for most things, it works really well)
- First delivery (40%): 19.3/20
- Final delivery (60%): 19.4/20
Grade: 19.4/20