title: Django Haystack - Indexing single field
body: <p>I am using Django <a href="http://haystacksearch.org" rel="nofollow">Haystack</a> for search.</p>
  
  <p>I <strong>only</strong> want to target the <code>title</code> field of my model when searching for results.</p>
  
  <p>At present however, it returns results if the search term is in any of the fields in my model. </p>
  
  <p>For example: searching <em>xyz</em> gives results where <em>xyz</em> is in the <code>bio</code> field.</p>
  
  <p>This should not happen, I only want to return results where <em>xyz</em> is in the <code>title</code> field. Totally ignoring all other fields other than <code>Artist.title</code> for searching on.</p>
  
  <p><code>artists/models.py</code> :</p>
  
  <pre><code>class Artist(models.Model):
      title = models.CharField(max_length=255)
      slug = models.SlugField(max_length=100)
      strapline = models.CharField(max_length=255)
      image = models.ImageField(upload_to=get_file_path, storage=s3, max_length=500)
      bio = models.TextField()
  </code></pre>
  
  <p><code>artists/search_indexes.py</code></p>
  
  <pre><code>from haystack import indexes
  from app.artists.models import Artist
  
  class ArtistIndex(indexes.SearchIndex, indexes.Indexable):
      text = indexes.CharField(document=True, use_template=True, model_attr='title')
  
      def get_model(self):
          return Artist
  </code></pre>
  
  <p>I guess thinking of it like a SQL query:</p>
  
  <pre><code>SELECT * FROM artists WHERE title LIKE '%{search_term}%'
  </code></pre>
  
  <p><strong>UPDATE</strong></p>
  
  <p>Following suggestion to remove use_template=True, my search_indexes.py now looks like:</p>
  
  <pre><code>from haystack import indexes
  from app.artists.models import Artist
  
  
  class ArtistIndex(indexes.SearchIndex, indexes.Indexable):
      text = indexes.CharField(document=True, model_attr='title')
      title = indexes.CharField(model_attr='title')
  
      def get_model(self):
          return Artist
  </code></pre>
  
  <p>But I am having the same problem. (Have tried python manage.py rebuild_index)</p>
  
  <p>This is my Haystack settings if that makes any difference:</p>
  
  <pre><code>HAYSTACK_CONNECTIONS = {
      'default': {
          'ENGINE': 'haystack.backends.simple_backend.SimpleEngine',
      },
  }
  </code></pre>