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?
Answers were Sorted based on User's Feedback
Answer / vijay singh
LOAD DATA INFILE 'data.txt' INTO TABLE table2
FIELDS TERMINATED BY ',';
| Is This Answer Correct ? | 3 Yes | 0 No |
Answer / vipul dalwala
LOAD DATA INFILE 'data.txt' INTO TABLE table_name
(city,code);
| Is This Answer Correct ? | 0 Yes | 0 No |
How do I find mysql database?
How do I run mysql from command line?
how fastest access of data can be done from database ?
How many tables we can create in mysql database?
What is mysql enterprise edition?
What are the differences between char and varchar data types?
List data types in mysql? Explain
What are the technical specifications of mysql?
What are the differences between drop a table and truncate a table?
How can you take the backup and restore a mysql database using php?
Explain the difference between mysql and mysqli interfaces in PHP?
What is the difference between is null & is not null?
Oracle (3259)
SQL Server (4518)
MS Access (429)
MySQL (1402)
Postgre (483)
Sybase (267)
DB Architecture (141)
DB Administration (291)
DB Development (113)
SQL PLSQL (3330)
MongoDB (502)
IBM Informix (50)
Neo4j (82)
InfluxDB (0)
Apache CouchDB (44)
Firebird (5)
Database Management (1411)
Databases AllOther (288)