Cóż, w końcu znalazłem odpowiedź. instrukcja LOAD DATA FILE wymaga, aby nazwa pliku była wartością ciągu, nie można jej sparametryzować. Niestety, klasa MySQLCommand nie lubi znaku \ w ścieżce pliku C# obiektu ciągu, więc nie może znaleźć pliku. Udało mi się to zrobić, uciekając w ten sposób:
//build the LOAD DATA File command
string working = String.Format("LOAD DATA LOCAL INFILE '{0}' IGNORE ", files.FirstOrDefault().ToString()) +
String.Format("INTO TABLE {0} COLUMNS TERMINATED BY ',' LINES TERMINATED BY '\n'", "by_switch")+
String.Format(" IGNORE 1 LINES (`Switch`,`Port`,`WWPN`,@the_slot,`Port Index`,@the_time,`Interval`,`Port Send Packet Rate`,")+
String.Format("`Port Receive Packet Rate`,`Total Port Packet Rate`,`Port Send Data Rate`,")+
String.Format("`Port Receive Data Rate`,`Total Port Data Rate`,`Port Peak Send Data Rate`,`Port Peak Receive Data Rate`,")+
String.Format("`Port Send Packet Size`,`Port Receive Packet Size`,`Overall Port Packet Size`,`Error Frame Rate`,")+
String.Format("`Dumped Frame Rate`,`Link Failure Rate`,`Loss of Sync Rate`,`Loss of Signal Rate`,`CRC Error Rate`,")+
String.Format(" `Short Frame Rate`,`Long Frame Rate`,`Encoding Disparity Error Rate`,")+
String.Format("`Discarded Class3 Frame Rate`,`F-BSY Frame Rate`,`F-RJT Frame Rate`, `Port Send Bandwidth Percentage`,")+
String.Format("`Port Receive Bandwidth Percentage`, `Overall Port Bandwidth Percentage`,`Primitive Sequence Protocol Error Rate`,")+
String.Format("`Invalid Transmission Word Rate`,`Link Reset Transmitted Rate`,`Link Reset Received Rate`)")+
String.Format("SET Slot = nullif(@the_slot,''),")+
String.Format(@"Time= str_to_date(@the_time,'%m/%d/%y %h:%i %p')");
// now escape the escape character
commandreplaced = commandreplaced.Replace(@"\", @"\\");
// now execute the command
MySqlCommand cmd = new MySqlCommand(commandreplaced,sqlconnect);