Dec-19-2022, 07:19 PM
Wrap code in python tags to save formatting
Python csv.writer will write null as a blank string. Actually, it writes None as a blank string. Database nulls are converted to Python Nones.
Knowing that you cannot write a None (or a null) to a csv file, what do you want to write? Maybe replace all occurrences of None in myresult to the string "null"?
Python csv.writer will write null as a blank string. Actually, it writes None as a blank string. Database nulls are converted to Python Nones.
Knowing that you cannot write a None (or a null) to a csv file, what do you want to write? Maybe replace all occurrences of None in myresult to the string "null"?