SQL script editor bug when delete
#### System information: 
- Win 10
- 21.2.2.202110030714
- Additional extensions -

#### Connection specification:
- Postgresql 13
- org.postgresql.Driver (42.2.20)

#### Describe the problem you're observing:
1. E.g. "SELECT id, c1, c2, c3 FROM table;" from SQL script window.
2. select a row and mark it for delete.
3. browse over the row limit (e.g. 200)
4. press "save"
5. the row doesn't deleted
diff --git a/plugins/org.jkiss.dbeaver.ui.editors.data/src/org/jkiss/dbeaver/ui/controls/resultset/ResultSetViewer.java b/plugins/org.jkiss.dbeaver.ui.editors.data/src/org/jkiss/dbeaver/ui/controls/resultset/ResultSetViewer.java
index bf66efb8b4..115d734f38 100644
--- a/plugins/org.jkiss.dbeaver.ui.editors.data/src/org/jkiss/dbeaver/ui/controls/resultset/ResultSetViewer.java
+++ b/plugins/org.jkiss.dbeaver.ui.editors.data/src/org/jkiss/dbeaver/ui/controls/resultset/ResultSetViewer.java
@@ -221,7 +221,15 @@ public class ResultSetViewer extends Viewer
     // Theme listener
     private IPropertyChangeListener themeChangeListener;
     private long lastThemeUpdateTime;
+    private boolean isCancelled = false;
 
+    public boolean isCancelled() {
+        return isCancelled;
+    }
+
+    public void setCancelled(boolean cancelled) {
+        isCancelled = cancelled;
+    }
 
     public ResultSetViewer(@NotNull Composite parent, @NotNull IWorkbenchPartSite site, @NotNull IResultSetContainer container)
     {
@@ -2256,9 +2264,6 @@ public class ResultSetViewer extends Viewer
     }
 
     void appendData(List<Object[]> rows, boolean resetOldRows) {
-        if (!checkForChanges()) {
-            return;
-        }
         model.appendData(rows, resetOldRows);
 
         UIUtils.asyncExec(() -> {
@@ -3540,6 +3545,9 @@ public class ResultSetViewer extends Viewer
     public boolean checkForChanges() {
         // Check if we are dirty
         if (isDirty()) {
+            if (isCancelled){
+                return false;
+            }
             int checkResult = new UITask<Integer>() {
                 @Override
                 protected Integer runTask() {
@@ -3548,6 +3556,7 @@ public class ResultSetViewer extends Viewer
             }.execute();
             switch (checkResult) {
                 case ISaveablePart2.CANCEL:
+                    isCancelled = true;
                     return false;
                 case ISaveablePart2.YES:
                     // Apply changes
@@ -4809,6 +4818,10 @@ public class ResultSetViewer extends Viewer
                 return Status.CANCEL_STATUS;
             }
             beforeDataRead();
+            if (!checkForChanges()){
+                return Status.CANCEL_STATUS;
+            }
+            isCancelled = false;
             try {
                 IStatus status = super.run(monitor);
                 afterDataRead();
['plugins/org.jkiss.dbeaver.ui.editors.data/src/org/jkiss/dbeaver/ui/controls/resultset/ResultSetViewer.java']