diff --git a/mysqldump_to_csv.py b/mysqldump_to_csv.py index 491cb36..32cb712 100644 --- a/mysqldump_to_csv.py +++ b/mysqldump_to_csv.py @@ -50,8 +50,8 @@ def parse_values(values, outfile): for reader_row in reader: for column in reader_row: # If our current string is empty... - if len(column) == 0: - latest_row.append('""') + if len(column) == 0 or column == 'NULL': + latest_row.append(chr(0)) continue # If our string starts with an open paren if column[0] == "(":