Use JDBC ODBC bridge to read from Excel : Excel « Database « Java Tutorial






import java.sql.Connection;
import java.sql.DriverManager;

public class Main {
  public static void main(String[] argv) throws Exception {
    Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
    String myDB = "jdbc:odbc:Driver={Microsoft Excel Driver (*.xls)};DBQ=c:/data.xls;"
        + "DriverID=22;READONLY=false";
    Connection con = DriverManager.getConnection(myDB, "", "");
  }
}








20.36.Excel
20.36.1.A JDBC Program to Access/Read Microsoft Excel
20.36.2.Write Data to a Microsoft Excel Spreadsheet File
20.36.3.Read data from Excel worksheet
20.36.4.Read data from Excel
20.36.5.Use JDBC ODBC bridge to read from Excel