title: Django Limit subquery
body: <p>I wrote the following code:</p>
  <pre><code>away_fixtures = Fixture.objects.filter(Q(away=home) | Q(home=away)).order_by('-date')[:3]
  tips = tips.filter(prediction__fixture__in=away_fixtures)
  </code></pre>
  <p>When executing the following error occurs (I use MariaDB 10.4, which does not support LIMIT in subqueries):</p>
  <pre><code>django.db.utils.NotSupportedError: (1235, &quot;This version of MariaDB doesn't yet support 'LIMIT &amp; IN/ALL/ANY/SOME subquery'&quot;)
  </code></pre>
  <p>When executing the following code:</p>
  <pre><code>away_fixtures = Fixture.objects.filter(Q(away=home) | Q(home=away)).order_by('-date')
  tips = tips.filter(prediction__fixture__in=away_fixtures)
  </code></pre>
  <p>But this returns the 'tips' for all the 'away_fixtures' and I only want the for the last 3 fixtures (so limiting it to 3 fixtures). How can I achieve this without switching database engines?</p>