- 多表联查:利用多个表联合查找某一项信息或者多项信息
- 1:1 OneToOne
- 建立关系:在模型任意一边即可,使用OneToOneField
- 1:N OneToMany
- N:N ManyToMany
django-admin startproject tlxy_db
python manage.py startapp rlt
python manage.py makemigrations
python manage.py migrate
python manage.py shell
-query:
- 有子表查母表: