title: Is it possible to hint at EntityFramework Core to use an inner join instead of an EXISTS sub-query for navigation property collection conditions?
body: <p>I have four tables: Users, Songs, Genres, and FavoriteGenres.</p>
  <p>Users are allowed to favorite genres and when they navigate to their dashboard, they are presented with a list of songs that are within any of their favorite genres.</p>
  <p>I have the following EF core code which accomplishes this:</p>
  <pre><code>dbContext
      .Songs
      .Include(song =&gt; song.Genre)
      .Where(song =&gt; song.Genre.FavoriteGenres.Any(favoriteGenre =&gt; favoriteGenre.UserId == userId))
      .OrderBy(song =&gt; song.CreatedDateTimeOffset)
      .ToListAsync(cancellationToken);
  </code></pre>
  <p>The query that is output (which works fine) is:</p>
  <pre><code>SELECT [s].[Id], [s].[Title], [s].[CreatedDateTimeOffset], [g].[Id], [g].[Name]
  FROM [Songs] AS [s]
  INNER JOIN [Genres] AS [g] ON [s].[GenreId] = [g].[Id]
  WHERE EXISTS (
    SELECT 1
    FROM [FavoriteGenres] AS [f]
    WHERE ([g].[Id] = [f].[GenreId]) AND ([f].[UserId] = @__userId_0))
  ORDER BY [s].[CreatedDateTimeOffset] DESC
  </code></pre>
  <p>I was just wondering if it is possible to hint at EF core to generate the following query, which I believe may be more optimal (though I would love to be told I am wrong!):</p>
  <pre><code>SELECT [s].[Id], [s].[Title], [s].[CreatedDateTimeOffset], [g].[Id], [g].[Name]
  FROM [Songs] AS [s]
  INNER JOIN [Genres] AS [g] ON [s].[GenreId] = [g].[Id]
  INNER JOIN [FavoriteGenres] AS [f] ON [f].[GenreId] = [g].[Id]
  WHERE [f].[UserId] = @__userId_0
  ORDER BY [s].[CreatedDateTimeOffset] DESC
  </code></pre>
  <p>The execution plans look very similar, but quite honestly I am not an expert at reading them. Any sort of help would be very appreciated :)</p>