title: Django Model.objects.all() returns unexpected empty QuerySet
body: <p>I have some problem while trying to use a MySQL database with Django. The database contains a table named <code>items</code>. This database is imported from a development system to a production system. This database is the second database in addition to an existing SQLite databased used by other teams. There had been an error message about <code>no such table</code>, but I was able to solve it with <a href="https://stackoverflow.com/questions/12784835/django-no-such-table">this question</a>. I then assume that there are no migration errors.</p>
  
  <p>The MySQL database works fine in the development system (tested using <code>python manage.py shell</code>), but it doesn't work in the production system (tested the same way.) </p>
  
  <p>I tested the import with:</p>
  
  <pre><code>$ python manage.py shell    
  
  &gt;&gt; from project.models import Item
  
  &gt;&gt; Item.objects.all()
  &lt;QuerySet []&gt;
  </code></pre>
  
  <p>I created the <code>models.py</code> file with:</p>
  
  <pre><code>$ python manage.py inspectdb &gt; models.py
  </code></pre>
  
  <p>I verified that the database and the table <code>items</code> actually contains records. (Although some fields are stored as unicode text, if that makes any difference to the situation.)</p>
  
  <p>Here is part of the <code>project/settings.py</code> file:</p>
  
  <pre><code>...
  DATABASES = {
      'default': {
          'ENGINE': 'django.db.backends.sqlite3',
          'NAME': os.path.join(BASE_DIR, 'db.sqlite3'),
      },
      'new_project': {
          'NAME': 'new_project',
          'ENGINE': 'django.db.backends.mysql',
          'USER': 'xxxxxxxx',
          'PASSWORD': 'xxxxxxxx',
      }
  }
  ...
  </code></pre>
  
  <p>Here is part of the generated <code>app/models.py</code>:</p>
  
  <pre><code>...
  class Item(models.Model):
      itemid = models.AutoField(db_column='ItemID', primary_key=True)  # Field name made lowercase.
      name = models.TextField(blank=True, null=True)
      category = models.TextField(blank=True, null=True)
      kind = models.TextField(blank=True, null=True)
  
      class Meta:
          managed = True
          db_table = 'items'
  ...
  </code></pre>
  
  <p>I am using <code>Django 2.0.2</code> with <code>Python 3.6.3</code>.</p>