if we want to load data from a text file into a mysql table,
but the columns in table are 1st: code(int) and 2nd:
city(varchar), but in text file the format is 1st cityname
and then code separeted by delimeters. how to load?
Answer Posted / vipul dalwala
LOAD DATA INFILE 'data.txt' INTO TABLE table_name
(city,code);
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
How many rows can a mysql table hold?
What are the non-standard sql commands supported by 'mysql'?
Is mysql a server or database?
How to Creating a new user. Login as root. Switch to the MySQL db. Make the user. Update privs.
What is a procedure example?
What is pdo connection?
What is a simple query?
How can I compare two mysql databases?
Can you tell a way to know the number of days between the two given dates in php?
Where is mysql installed on linux?
How to calculate the difference between two dates?
What is pragma exception?
How do you determine the location of mysql data directory?
What you can use regular expression for in mysql? Support your answer with an example?
Where is the mysql data directory?