Skip to content

Latest commit

 

History

2 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

목차

  1. DDL (Data Definition Language)
  2. insert (C)
  3. select (R)
  4. update (U)
  5. delete (D)
  6. join (select)

  • 가상환경 생성/ 활성화
  • 장고 설치
pip install django faker
  • startproject, startapp
    • 앱 등록
  • modeling
    • actor >-< movie
    • movie >-< category
    • user -< score
    • movie -< score
  • migration
python manage.py sqlmigrate movies 0001
  • settings.py
# DATABASES = {
#     'default': {
#         'ENGINE': 'django.db.backends.sqlite3',
#         'NAME': BASE_DIR / 'db.sqlite3',
#     }
# }

# 장고에서 MySQL 쓰기
DATABASES = {
    'default': {
        'ENGINE': 'django.db.bavkends.mysql',
        'NAME': 'mydb',
        'HOST': 'localhost',
        'PORT': '3306',
        'USER': 'root',
        'PASSWORD': 'password',
    }
}
  • migrate
pip install mysqlclient
python manage.py migrate
  • movies/managemant/commands/generate.py
python manage.py generate
  • 라이브러리 설치
pip install django-extensions
pip install ipython
  • 앱 등록
python manges.py shell_plus
  • .git 삭제
rm -rf .git

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Used by

Contributors

Languages