How can I solve the problem that mysql fails to import csv data using SQLyog?

Source: Internet
Author: User
The software used to import data to mysql today is SQLyog. I believe that you can directly import data to mysql. Select a table and select import-import to use local csv data, if you do not know what the import is unsuccessful, you can use commands to record it and use it for future reference: (my windows system) LOADDATALOCALINFILEC: \ User

The software used to import data to mysql today is SQLyog. I believe that you can directly import data to mysql. Select a table and select import-import to use local csv data, if you do not know the problem, you can use the command to record the import failure. It will be used for future convenience: (my windows system) load data local infile 'C: \ User

The software used to import data to mysql today is SQLyog. I believe that you can directly import data to mysql. Select a table and select import-import to use local csv data, if you do not know what the import is unsuccessful, you can use the command to record it and use it for future reference:

(My windows OS)

Load data local infile 'C: \ Users \ zl \ Desktop \ zhishu.csv 'into table library name. table name character set gbk fields terminated by ', 'optionally enclosed by' "'elasticed BY '" 'Lines terminated by' \ r \ n' (id, 'name ', 'description', parent_id)

Note:

Files in 1.csv are generally encoded in gbk. Therefore, the encoding is set to gbk.
2. The field name is enclosed in brackets.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.