1.将帆软开源工程finekit打成finekit.jar包,然后引入finekit.jar到自己的工程中,(开源工程finekit参考:https://wiki.fanruan.com/pages/viewpage.action?pageId=30212104)
2.使用ConnectionKit即可
Connection connection = ConnectionKit.getConnection(连接名称);
AbstractDBDataModel dataModel = DBTableData.createCacheableDBResultSet(connection, SQL语句, -1);
for (int row = 0; row < dataModel.getRowCount(); row++){
// 数据值
dataModel.getValueAt(row, 列号);
}