For a while not I have been trying to import a tab separated text file into my mysql database. I keep getting this error.
A few forums advised that I should change the mode of the file and folder to 777. Which I did, but still the same error.
Error: 29, File '/tmp/vehicleMake.txt' not found (Errcode: 13), when using table: vehicleMake
The first error you might experience when using mysqlimport from the command line is shown below. In this example we have entered either the username or password incorrectly. The error text shows us we did enter the password (it would say "Using password: NO" if we had not) but does not tell us whether it was the username or password.
The Standard MySQLImport command seamlessly imports data from the files you mention to your tables. By naming the files exactly the same as the Table name, you can avoid any errors and effortlessly import data to your tables. MySQLImport command also provides a list of options to enter columns list, compression settings, passwords, etc.
Database Import File Does Not Exist This error means the file you are trying to import into MySQL does not exist. Check you have the path correct and the file actually exists. It can also mean that the MySQL server does not have sufficient permissions to access the file in the directory it is in.
Your MySQL connection id is 257 Server version: 5.5.29-0ubuntu0.12.04.1-log (Ubuntu) Copyright (c) 2000, 2012, Oracle and/or its affiliates. All rights reserved.
Sorry for trouble, I used --local option and it worked.. Magic!!!
The LOCAL option is no longer supported in most versions of MYSQL. In Ubuntu 14.04 and MYSQL 5.5 I moved the file to the /tmp directory and changed ownership of the file to mysql using the following in the shell:
sudo chown mysql.mysql <filename>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With