How to load data from a text file into a table?

Answer Posted / palanisamy

we have the mysql query which will load csv file into db
syntax:

load data infile 'pathtothefile' into table name
line termineted by '\n',
field teminated by ',';

Is This Answer Correct ?    9 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is database migration in mysql?

526


What is database engine in mysql?

495


Which command is used to view the content of the table in mysql?

500


How do you rename a table in mysql?

511


How can we convert between Unix & MySQL timestamps?

471






What is the datatype of image in mysql?

495


How do I connect to a mysql database?

493


Explain the different types of constraints?

523


Is mysql port 3306 tcp or udp?

520


How do I optimize a selected query in mysql?

516


What is pdo :: fetch_assoc?

497


What is ntext?

619


What ascii 31?

524


What is truncate command?

462


What is the usage of "i-am-a-dummy" flag in mysql?

677