From the course: Advanced Python: Practical Database Examples
Unlock the full course today
Join today to access over 24,500 courses taught by industry experts.
Create a MySQL database - Python Tutorial
From the course: Advanced Python: Practical Database Examples
Create a MySQL database
- [Instructor] Let's install and configure the tools to create a MySQL database. If you don't already have MySQL installed you can download it from this website. I already have it installed, so I won't be installing it but this would be the place to go to install it. Once it's installed, the path needs to be updated so we can use the MySQL Shell in the command line. This will be different if you're on a Windows computer but on a Mac you can use what type of shell you're running to determine where to update the path. We'll use echo SHELL to find out which shell we're running. In this case, ours is bin/zsh. This means we'll need to update our .zshrc file in our home directory. We can navigate to our home with cd tilde. Then we'll open up the file with nano dot zshrc. Inside of here, we have two entries that tell our shell where MySQL is located. We have the MySQL bin and MySQL support files. We add these to our path so we…
Contents
-
-
-
What is an API?2m 45s
-
(Locked)
API frameworks in Python1m 29s
-
(Locked)
Set up FastAPI in a Python application4m 6s
-
(Locked)
Define a database schema2m 56s
-
(Locked)
Create a MySQL database3m 45s
-
(Locked)
Create an API contract2m 22s
-
(Locked)
Build a POST endpoint with FastAPI2m 27s
-
(Locked)
Call a new API using Postman3m 35s
-
(Locked)
Add data to a database in Python using SQLAlchemy4m 45s
-
(Locked)
Integrate a database with a FastAPI application3m 33s
-
(Locked)
Challenge: Develop a GET endpoint with FastAPI and a DB1m 35s
-
(Locked)
Solution: Develop a GET endpoint with FastAPI and a Database7m 22s
-
-
-
-