I try to import data from a database encodet in "latin1", change to "unicode" and import them into my app. Normaly this is no problem. But now I have some new data with a field with a strange character = "\x17"
How do I deal with this in Python?
What I made now is a function for replacing this data. But I think there are much better ways then this:
def replace_problem_characters(self, text):
replace_store = {u"\x17" : ""}
for key, value in replace_store.items():
if key in text:
text = text.replace(key, value)
return text