Close databases after comparing them.