I have an sqlite database that was populated by an external program. Im trying to read the data with python. When I attempt to read the data I get the following error:

**OperationalError: Could not decode to UTF-8**

If I open the database in sqlite manager and look at the data in the offending record(s) using the inbuilt browse and search it looks fine, however if I export the table as csv, I notice the character £ in the offending records has become **Â£**

If I read the csv in python, the £ in the offending records is still read as **Â£** but its not a problem I can parse this manually. However I need to be able to read the data direct from the database, without the intermediate step of converting to csv.

I have looked at some answers online for similar questions, I have so far tried setting "text\_factory = str" and I have also tried changing the datatype of the column from TEXT to BLOB using sqlite manager, but still get the error.

My code below results in the OperationalError: Could not decode to UTF-8

```
conn = sqlite3.connect('test.db')
conn.text_factory = str
curr = conn.cursor()
curr.execute('''SELECT xml_dump FROM hands_1 LIMIT  5000  , 5001''')
row = curr.fetchone()

```

All the records above 5000 in the database have this character problem and hence produce the error.

Any help appreciated.