Make Applications Real•Reading lesson•Free
Overview
No account is required. Learn the material, try the examples, and mark it complete when you are ready to move on. Sign in with email only if you want to save progress across devices.
Project 1 - Give Your Application a Database
This project makes database persistence explicit.
Run
bash
python -m pip install -r requirements.txt
python manage.py migrate
python manage.py runserverOpen the local URL shown by Django.
What to inspect
inventory/models.py- Django modelinventory/admin.py- admin registrationinventory/management/commands/seed_products.py- sample datadb.sqlite3- local database created by Django
The application demonstrates the relationship:
text
Django Model
↓
Database Table
↓
Stored RowsThe next project will use SQL to inspect this database directly.
Lesson resources
Supporting code and files from this part of the curriculum.
Finished this lesson?
Keep your place here, or save it across devices with an email link.
Saved in this browser. Save progress with email →