请问下这个错误是指什么原因
代码
<%@ page language="java" import="java.util.*" pageEncoding="gb2312"%>
<%new com.mypack.XlsToOra("d:/test/test2.xls", "T203770000000_ch_tswtAUTO").toOracle(); %>
package com.mypack;
import java.io.File;
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
import java.sql.ResultSetMetaData;
import java.util.List;
import javax.naming.Context;
import javax.naming.InitialContext;
import
javax.naming.NamingException;
import javax.sql.DataSource;
import jxl.Sheet;
import jxl.Workbook;
import org.apache.commons.dbutils.QueryRunner;
public class XlsToOra {
private String xls;
private String table;
private DataSource ds;
public XlsToOra() {
}
public XlsToOra(String xls, String table) {
this.xls = xls;
this.table = table;
}
public String getTable() {
return table;
}
public void setTable(String table) {
this.table = table;
}
public String getXls() {
return xls;
}
public void setXls(String xls) {
this.xls = xls;
}
public void init() {
Context initContext;
try {
initContext = new InitialContext();
ds = (DataSource) initContext.lookup("java:/comp/env/oracleds");
System.out.println(ds);
} catch (NamingException e) {
e.printStackTrace();
}
}
public boolean toOracle() throws Exception {
Workbook book = Workbook.getWorkbook(new File(xls));
Sheet sheet = book.getSheet(0);
int rows = sheet.getRows();
int cols = sheet.getColumns();
String sql = "INSERT INTO " + table + " VALUES (";
for (int i = 0; i < cols - 1; i++) {
sql += "?,";
}
sql += "?)";
init();
QueryRunner queryRun = new QueryRunner(ds);
for (int i = 1; i < rows; i++) {
String param[] = new String[cols];
for (int j = 0; j < cols; j++) {
param[j] = sheet.getCell(j, i).getContents();
}
queryRun.update(sql, param);
}
return false;
}
public List getAttribute() throws Exception {
List list = null;
String sql = "SELECT * FROM " +&nbs