Error: Column 'total' in order clause is ambiguous