Upgraded similarity
Upgraded SQL queries