version 1.36, 2004/10/19 11:12:19
|
version 1.37, 2004/10/29 10:28:10
|
Line 378 public class DBBean
|
Line 378 public class DBBean
|
* Returns the result for select * from table |
* Returns the result for select * from table |
* with maxHits = 500 default value |
* with maxHits = 500 default value |
*/ |
*/ |
public Vector[] getQueryData(String table) throws SQLException, ParseException |
public Vector[] getQueryData(String table) throws SQLException, ParseException,Exception |
{ |
{ |
|
|
return getQueryData("SELECT * from " + quoteChar + table + quoteChar, maxHits); |
return getQueryData("SELECT * from " + quoteChar + table + quoteChar, maxHits); |
Line 389 public class DBBean
|
Line 389 public class DBBean
|
* Returns the result of the query |
* Returns the result of the query |
* or an Vector array of Vectors containing error messages |
* or an Vector array of Vectors containing error messages |
*/ |
*/ |
public Vector[] getQueryData(String query, FM2SQL.ProgressDialog dialog, int maxHits) throws SQLException |
public Vector[] getQueryData(String query, FM2SQL.ProgressDialog dialog, int maxHits) throws SQLException,Exception |
{ |
{ |
long timeStart = System.currentTimeMillis(); |
long timeStart = System.currentTimeMillis(); |
ResultSet resultSet = null; |
ResultSet resultSet = null; |
Line 458 public class DBBean
|
Line 458 public class DBBean
|
* Returns the result of the query |
* Returns the result of the query |
* or an Vector array of Vectors containing error messages |
* or an Vector array of Vectors containing error messages |
*/ |
*/ |
public Vector[] getQueryData(String query, int maxHits) throws SQLException, ParseException |
public Vector[] getQueryData(String query, int maxHits) throws SQLException, ParseException,Exception |
{ |
{ |
long timeStart = System.currentTimeMillis(); |
long timeStart = System.currentTimeMillis(); |
ResultSet resultSet = null; |
ResultSet resultSet = null; |
Line 719 public class DBBean
|
Line 719 public class DBBean
|
* with the numberOfHits as maximum |
* with the numberOfHits as maximum |
* @return the result as an ResultSet object |
* @return the result as an ResultSet object |
*/ |
*/ |
public ResultSet makeQuery(String query, int numberOfHits) throws SQLException |
public ResultSet makeQuery(String query, int numberOfHits) throws SQLException,Exception |
{ |
{ |
result = null; |
result = null; |
Statement stm = null; |
Statement stm = null; |
Line 757 public class DBBean
|
Line 757 public class DBBean
|
} catch (Exception e) |
} catch (Exception e) |
{ |
{ |
// TODO remove |
// TODO remove |
if (FM2SQL.fmInstance != null&&Convert.debug) |
if (Convert.isGUI&&Convert.debug) |
FM2SQL.showErrorDialog("Error caught!! \n Query was " + query + " \n", "Debug Info"); |
FM2SQL.showErrorDialog("Error caught!! \n Query was " + query + " \n", "Debug Info"); |
e.printStackTrace(); |
e.printStackTrace(); |
|
throw e; |
} |
} |
|
|
return result; |
return result; |