티스토리 뷰

728x90
class Bussinesses(models.Model):
    business_email = models.EmailField()
    password = models.CharField(max_length=20)
    contact_first_name = models.CharField(max_length=30)
    contact_last_name = models.CharField(max_length=30)

    class Meta:
        db_table = "bussinesses"

https://stackoverflow.com/questions/9849666/how-to-remove-the-prefix-of-a-table-for-a-django-model

 

How to remove the prefix of a table for a Django model?

I create a new Django app (not project) called Bussinesses, then add following class to the models.py. class Bussinesses(models.Model): business_email = models.EmailField() password = models.

stackoverflow.com

 

728x90

'공부' 카테고리의 다른 글

드모르간의 법칙 (De Morgan's law)  (8) 2020.07.13
[Java] mail filename encoding UTF-8  (0) 2020.07.10
[PyCharm] PYTHONPATH=  (0) 2020.07.09
[Django] created_at, updated_at  (0) 2020.07.09
[Sh] "" == true ? -> if [ -z "$VAR" ];  (0) 2020.07.09
댓글