You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
SELECT`tracks`.`id`FROM`tracks`INNER JOIN`videos`ON`videos`.`track_id`=`tracks`.`id`WHERE`videos`.`fan_id`= ? AND`videos`.`workflow_state`IN ('submitted', 'pending', 'approved') ORDER BY row_order
When you join tables the ranked model doesn't include table alias in the order by so you get error:
Column 'row_order' in order clause is ambiguous
You only get this bug when attempting to access columns from result using pluck or select etc...
Cause sql gen'd for:
Was able to override by doing this on include:
The above change generates sql correctly:
Gem should probably always alias order by clauses just to be safe of possible ambiguous column errors.
The text was updated successfully, but these errors were encountered: