One way around that is to drop all cases below a certain occurrence threshold, ie. if there aren't at least 1000 people in the same town with the same condition, they aren't getting into the dataset.
(The downside is that rare diseases might fall through the cracks.)
The common example is the one-legged child with cancer from a remote town. You can remove a the PII columns and it's pretty easy to find that person.