2

In ruby on rails when joining the two arel tables throws error "wrong number of arguments (given 1, expected 0). Below is the sample

tab_a = TableA.arel_table, tab_b = TableB.arel_table

query = tab_a[:column1].eq(tab_b[:column2]).and(tab_b[:column3].eq('test'))

TableA.all.where(tab_a.join(tab_b).on(query)).order(tab_b [:column4].send('asc'))

this throws error "wrong number of arguments (given 1, expected 0)". Any help would be appreciated. Thanks

Vishal Taj PM
  • 1,339
  • 11
  • 23

0 Answers0