Umm... why can't you just do the division right before you create the SQL statement?