title: Improve Django queryset performance when using annotate Exists
body: <p>I have a queryset that returns a lot of data, it can be filtered by year which will return around 100k lines, or show all which will bring around 1 million lines.</p>
  
  <p>The objective of this annotate is to generate a xlsx spreadsheet.</p>
  
  <p>Models representation, <code>RelatedModel</code> is manytomany between <code>Model</code> and <code>AnotherModel</code></p>
  
  <pre><code>Model:
      id
      field1
      field2
      field3
  
  RelatedModel:
      foreign_key_model (Model)
      foreign_key_another (AnotherModel)
  </code></pre>
  
  <p>Queryset, if the relation exists it will annotate, this annotate is very slow and can take several minutes.</p>
  
  <pre><code>Model.objects.all().annotate(
      related_exists=Exists(RelatedModel.objects.filter(foreign_key_model=OuterRef('id'))),
      related_column=Case(
          When(related_exists=True, then=Value('The relation exists!')),
          When(related_exists=False, then=Value('The relation doesn't exist!')),
          default=Value('This is the default value!'),
          output_field=CharField(),
      )
  ).values_list(
      'related_column',
      'field1',
      'field2',
      'field3'
  )
  </code></pre>