Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'lib/gitlab/sql/union.rb')
-rw-r--r--lib/gitlab/sql/union.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/gitlab/sql/union.rb b/lib/gitlab/sql/union.rb
index 1a62eff0b31..1cd89b3a9c4 100644
--- a/lib/gitlab/sql/union.rb
+++ b/lib/gitlab/sql/union.rb
@@ -23,11 +23,11 @@ module Gitlab
# (thus fixing this problem), at a slight performance cost.
fragments = ActiveRecord::Base.connection.unprepared_statement do
@relations.map do |rel|
- "(#{rel.reorder(nil).to_sql})"
+ rel.reorder(nil).to_sql
end
end
- fragments.join(' UNION ')
+ fragments.join("\nUNION\n")
end
end
end