Q:

my django can't generate models from oracle database

I am building django project upon oracle database, after I set my database in django settings, I use command python manage.py inspectdb to generate oracle tables, but there is an error: 
> Unicode DecodeError: 'utf-8 codec can't decode bytes in position
> 82-83:invalid continuation byte

What can I do ?  The oracle is not install in my local pc.
I tried to set local env path:NLS_LANG=SIMPLIFIED CHINESE_CHINA.ZHS16GBK, it didn't work.

A:

From the Django Database documentation:

Encoding
Django assumes that all databases use UTF-8 encoding. Using other
  encodings may result in unexpected behavior such as “value too long”
  errors from your database for data that is valid in Django. See the
  database specific notes below for information on how to set up your
  database correctly.

You first need to convert your database to use UTF-8 encoding before you can use it with Django. I don't think any other encoding is supported.
If our Oracle database is UTF-8 encoded, check that you meet all the requirements:

Django supports Oracle Database Server versions 11.2 and higher.
  Version 5.2 or higher of the cx_Oracle Python driver is required.

