optimize query for question show page