3 ms·
I submitted the following file (note the blanks): $ cat testblanks.csv 1997, Ford, E350 The following was returned: CREATE TABLE testblanks (Column_1 NUMERIC(
by itazula 12y ago
I submitted the following file (note the blanks):
$ cat testblanks.csv
1997, Ford, E350
The following was returned:
CREATE TABLE testblanks (Column_1 NUMERIC(32, 16),Column_2 VARCHAR(5) CHARACTER SET utf8,Column_3 VARCHAR(5) CHARACTER SET utf8);
INSERT INTO testblanks VALUES (1997,' Ford',' E350');
That was in accordance with http://tools.ietf.org/html/rfc4180 http://tools.ietf.org/html/rfc4180
Cool!
But the CSV format has a lot of "gotchas." See, for example, http://discuss.fogcreek.com/joelonsoftware3/default.asp?cmd=show&ixPost=99824&ixReplies=25 http://discuss.fogcreek.com/joelonsoftware3/default.asp?cmd=.... Especially the rant about the Microsoft version of CSV.
- masklinn 12y ago> But the CSV format has a lot of "gotchas." In the wild, CSV is less a format and more a meta-format (and a subset of the *SV family) with plenty of variability between dialects.