Encoding for schools and cities database