Reputation: 47
I am building a Django app and it has several apps. It is working fine with SQLite database as a backend. When I am trying to migrate the backend to Oracle using "manage.py migrate", I am getting below error
django.db.utils.DatabaseError: ORA-01950: no privileges on tablespace 'XXXXXX'
When I checked my User privileges in the database, it has privileges to create tables, views etc. I tried to execute "manage.py sqlmigrate" and go through the queries that Django is going to execute on the database and found out that they are "create table" and "add constraints queries". Is there a way in Django to find out which query is getting failed or raising that ORA-01950 error?
Upvotes: 1
Views: 675
Reputation: 1047
When I checked my User privileges in the database, it has privileges to create tables, views etc.
Have you checked that app user has permssion related to quota (unlimited or 1GB .. ) ? In oracle, it is not sufficient to have create table permission to create table, you also need quota on table space.
ALTER USER <user> quota unlimited on <tablespace name>;
or
ALTER USER <user> quota 1G on <tablespace name>;
Upvotes: 2