I want to read from my numbers-sheet some data. The first row is a "title" row, containing names of each column, and every other row contains data. I wrote a simple program in python to read this, however every time when I run this code I get:
File "dataReader.py", line 11, in <module>
for row in fileReader:
_csv.Error: line contains NULL byte
I was trying to encode each line, but it doesn't helped. Below I past my code (in this one I am not calling the utf_8_encoder function, but even if I try to use it - I still have errors). I want to read row by row from my file, and read it as a string. How can I do that?
import csv
import codecs
def utf_8_encoder(unicode_csv_data):
for line in unicode_csv_data:
yield line.encode('utf-8')
if __name__ == "__main__":
dataFile = open("file.numbers", 'rU')
fileReader = csv.reader(dataFile)
for row in fileReader:
print row
Here is also a sample of my file:

fileReader = csv.reader(x.replace('\0', '') for x in dataFile)