rails/rails — pull request #11880 by senny (2013-08-14 07:38:37+00:00)
Title: Backport arel fix

Closes #11870

This is a backport of d345ed40b5783ec2cb43f4434872ea5b2d57d203 and 77ba336080b4de15233f669bdeea5c9ac44a3941