if the Excel table has a, B, c three columns of data, you want to import into the Database Users table, the corresponding fields are Name,sex,age, add a column in your Excel table, and use Excel's formula to automatically generate SQL statements, the method is as follows:
1. Add a column to your Excel table
2, in the first row of column D, is D1 input formula: =concatenate ("INSERT into Persons_serial_number (Persons_no, Persons_name,id_number) VALUES (' & B1 & ', ' ' & C1 & ' ', ' ' & E1 & '); ')
3. At this point, D1 has generated the following SQL statement: INSERT into Persons_serial_number (Persons_no, Persons_name,id_number) VALUES (' xxxxx ', ' xxxx , ' xxxxxxxxxx ');
4. Copy the formula of D1 to column D of all rows by placing the data in the bottom right corner of the cell, and when the mouse becomes a 10 glyph, drag down to the last line to release it and automatically copy and change the parameters in values dynamically .
5. At this point, the D column has generated all the SQL statements
6. Copy the D column to a plain text file,It is recommended to use UltraEdit for processing.
Convert data in Excel to SQL statements