forked from github/dataease
refactor(数据集): 详细展示Calcite执行SQL时的报错提示
This commit is contained in:
parent
4a5f3219cf
commit
0c4616eb67
@ -174,7 +174,13 @@ public class CalciteProvider {
|
||||
}
|
||||
list = getDataResult(resultSet);
|
||||
} catch (Exception | AssertionError e) {
|
||||
DEException.throwException(Translator.get("i18n_fetch_error") + e.getMessage());
|
||||
String msg;
|
||||
if (e.getCause() != null && e.getCause().getCause() != null) {
|
||||
msg = e.getMessage() + " [" + e.getCause().getCause().getMessage() + "]";
|
||||
} else {
|
||||
msg = e.getMessage();
|
||||
}
|
||||
DEException.throwException(Translator.get("i18n_fetch_error") + msg);
|
||||
} finally {
|
||||
try {
|
||||
if (resultSet != null) resultSet.close();
|
||||
|
Loading…
Reference in New Issue
Block a user