Skip to content

Commit

Permalink
Remove unneeded ORDER BY
Browse files Browse the repository at this point in the history
This has no effect on the final output. The URLs are sorted before they're
written.
  • Loading branch information
mwiencek committed Oct 8, 2015
1 parent b7d19d1 commit 0325630
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions lib/MusicBrainz/Server/Sitemap/Overall.pm
Expand Up @@ -333,9 +333,7 @@ sub build_one_batch {
}
my $columns = join(', ', "$entity_id AS main_id", @{ $extra_sql{columns} });
my $tables = $entity_type . $extra_sql{join};
my $query = "SELECT $columns FROM $tables " .
"WHERE ceil(${entity_type}.id / ?::float) = any(?) " .
"ORDER BY ${entity_type}.id ASC";
my $query = "SELECT $columns FROM $tables WHERE ceil($entity_type.id / ?::float) = any(?)";
my $ids = $c->sql->select_list_of_hashes($query, $MAX_SITEMAP_SIZE, $batch_info->{batches});

for my $suffix (sort keys %{$entity_suffix_info}) {
Expand Down

0 comments on commit 0325630

Please sign in to comment.