diff options
-rw-r--r-- | lib/arel/visitors/join_sql.rb | 2 | ||||
-rw-r--r-- | spec/arel/select_manager_spec.rb | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/arel/visitors/join_sql.rb b/lib/arel/visitors/join_sql.rb index c1e00ea8f0..ab3d10f99c 100644 --- a/lib/arel/visitors/join_sql.rb +++ b/lib/arel/visitors/join_sql.rb @@ -21,7 +21,7 @@ module Arel end def visit_Arel_Nodes_OuterJoin o - "OUTER JOIN #{visit o.right} #{visit o.constraint}" + "LEFT OUTER JOIN #{visit o.right} #{visit o.constraint}" end def visit_Arel_Nodes_InnerJoin o diff --git a/spec/arel/select_manager_spec.rb b/spec/arel/select_manager_spec.rb index 02586f3a65..df8d236bc3 100644 --- a/spec/arel/select_manager_spec.rb +++ b/spec/arel/select_manager_spec.rb @@ -252,7 +252,7 @@ module Arel manager = Arel::SelectManager.new Table.engine manager.from Nodes::OuterJoin.new(table, aliaz, table[:id].eq(aliaz[:id])) manager.join_sql.should be_like %{ - OUTER JOIN "users" "users_2" "users"."id" = "users_2"."id" + LEFT OUTER JOIN "users" "users_2" "users"."id" = "users_2"."id" } check manager.joins(manager).should == manager.join_sql end |