możesz zrobić coś takiego
select (case when surname = 'jack' then 1 else 0 end +
case when school ='st' then 1 else 0 end +
case when college='mit' then 1 else 0 end +
case when city='austin' then 1 else 0 end) as score,
*
from
user
WHERE surname='jack' or
school='st' or
college='mit' or
city='austin')
order by score desc;