Will all inserts performed when using LOAD DATA INFILE be rolled back if it fails?
问题 I use LOAD DATA INFILE from C# using the MySQLBulkLoader object of the MySQL Connector for .NET, to load 24 GB of data into a MySQL 5.5 table. I am wondering whether in case of failure (for any reason, even warnings), the bulk insertion would be properly rolled back as if it had been done within a transaction, or if I should expect to see the first successful records already commited. The relevant page on the MySQL manual is not very informative in this regard. 回答1: MySQL in auto-commit mode