fixes order by exploit

fixes possible exploit, adds ordercolumns