[Fixed]-How to change Django's default Postgres database search directory

1👍

You can set the db_table Meta option for you model.

class MyTable(models.Model):
    ...

    class Meta:
        db_table = 'mytable'

Unless you are dealing with a legacy database, I recommend that you define your models, create migrations, then let Django create the tables, instead of creating the tables manually as you are doing.

Leave a comment