How can I get rid of these null columns? I'm importing my csv file to create a table on phpMyAdmin. The sql query looks appropriate but at the end, I get...
`Category 1` VARCHAR( 97 ) ,
`Category 2` VARCHAR( 113 ) ,
`NULL` VARCHAR( 71 ) ,
`NULL` VARCHAR( 56 ) ,
`NULL` VARCHAR( 73 ) ,
`NULL` VARCHAR( 97 )
) ENGINE = MYISAM DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci;
MySQL said:
#1060 - Duplicate column name 'NULL'
Category 2 should be the last column. I can't figure out where the null columns are coming from, or how to get rid of them. The original file is given to me in .xls format. I make some changes and save as csv. I used to upload an xls file (never had problems) but I think our cPanel was upgraded so it's all changed.
So far I've tried deleting 4+ columns at the end while in OpenOffice. I've tried opening the csv in notepad and making sure there was no extra commas or spaces, adding in / to escape. I've tried fiddling with the import options in phpMyAdmin but I'm far from an expert so no luck there.