提交 243fb69d 编写于 作者: S Serge Rider

Value update: error handle

上级 67e2f7b2
......@@ -31,6 +31,7 @@ import org.jkiss.dbeaver.model.exec.DBCAttributeMetaData;
import org.jkiss.dbeaver.model.exec.DBCExecutionContext;
import org.jkiss.dbeaver.model.struct.DBSAttributeBase;
import org.jkiss.dbeaver.model.struct.DBSTypedObject;
import org.jkiss.dbeaver.runtime.DBWorkbench;
import org.jkiss.dbeaver.ui.UIUtils;
import org.jkiss.dbeaver.ui.data.IAttributeController;
import org.jkiss.dbeaver.ui.data.IDataController;
......@@ -137,7 +138,15 @@ public class ResultSetValueController implements IAttributeController, IRowContr
@Override
public void updateValue(@Nullable Object value, boolean updatePresentation)
{
boolean updated = controller.getModel().updateCellValue(binding, curRow, value);
boolean updated;
try {
updated = controller.getModel().updateCellValue(binding, curRow, value);
} catch (Exception e) {
UIUtils.asyncExec(() -> {
DBWorkbench.getPlatformUI().showError("Value update", "Error updating value: " + e.getMessage(), e);
});
return;
}
if (updated && updatePresentation) {
// Update controls
UIUtils.syncExec(new Runnable() {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册