下面的代码片段
String query = " SELECT * FROM accessdb.user;";
try
{
ResultSet rs = statement.executeQuery(query);
rs.first();
String s = "";
do
{
s = s + rs.getInt(0) + "\t\t" + rs.getString(1) + "\t\t"
+ rs.getString(2) + "\n";
rs.next();
}
while (!rs.isLast());
System.out.println(s);
}
catch (Exception ex)
{
System.out.println("\nError for firing query");
}
产生以下异常
java.sql.SQLException: [Microsoft][ODBC Driver Manager] Invalid descriptor index
这是如何引起的,我该如何解决?