Solved

mysqlimport error

Posted on 2010-11-16
2
425 Views
Last Modified: 2012-05-10
Hi

I was wondering why i am getting the following error:

C:\>mysqlimport -u root -pxxx test_import C:\employee.txt
mysqlimport: Error: Data truncated for column 'empno' at row 1, when using table
: employee

but everything works ok if i add the --local flag. I don't remember ever having to use this flag before
C:\>mysqlimport -u root -paxxx test_import --local C:\employee.txt
test_import.employee: Records: 3  Deleted: 0  Skipped: 0  Warnings: 9


thanks
0
Comment
Question by:andieje
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 3

Accepted Solution

by:
xeonol earned 500 total points
ID: 34153156
The --local flag specifies that the tool reads the data file locally and then send it to server instead of letting server read the file directly.

I guess if your mysqlimport tool and mysql server are mismatched, so that the tool can recongize the format while the server side cannot.
0
 

Author Closing Comment

by:andieje
ID: 34154623
ok, that makes sense, thanks
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

I have been using r1soft Continuous Data Protection (http://www.r1soft.com/linux-cdp/) for many years now with the mySQL Addon and wanted to share a trick I have used several times. For those of us that don't have the luxury of using all transact…
Load balancing is the method of dividing the total amount of work performed by one computer between two or more computers. Its aim is to get more work done in the same amount of time, ensuring that all the users get served faster.
Come and listen to Percona CEO Peter Zaitsev discuss what’s new in Percona open source software, including Percona Server for MySQL (https://www.percona.com/software/mysql-database/percona-server) and MongoDB (https://www.percona.com/software/mongo-…
In this video, viewers are given an introduction to using the Windows 10 Snipping Tool, how to quickly locate it when it's needed and also how make it always available with a single click of a mouse button, by pinning it to the Desktop Task Bar. Int…

726 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question