Hi,

1. When we try to delete the table row with the column definition having
NOT NULL TRUE and HAS NO DEFAULT VALUE then it fails.
    Please find the attached patch for the same. (delete_row.patch)

2. The debugger can not be opened from the View trigger.
    Please find the attached patch for the same. (view_debugger.patch)

Thanks,
Khushboo
diff --git a/web/pgadmin/tools/sqleditor/command.py b/web/pgadmin/tools/sqleditor/command.py
index 3b7efd0..94aec09 100644
--- a/web/pgadmin/tools/sqleditor/command.py
+++ b/web/pgadmin/tools/sqleditor/command.py
@@ -464,6 +464,7 @@ class TableCommand(GridCommand):
                     continue
 
                 column_type = {}
+                column_data = {}
                 for each_col in columns_info:
                     if (
                         columns_info[each_col]['not_null'] and
diff --git a/web/pgadmin/tools/debugger/templates/debugger/js/debugger.js b/web/pgadmin/tools/debugger/templates/debugger/js/debugger.js
index 624ca80..e26076a 100644
--- a/web/pgadmin/tools/debugger/templates/debugger/js/debugger.js
+++ b/web/pgadmin/tools/debugger/templates/debugger/js/debugger.js
@@ -234,11 +234,16 @@ define([
           var baseUrl = "{{ url_for('debugger.index') }}" + "initialize_target/" + "indirect/" + treeInfo.server._id +
                                 "/" + treeInfo.database._id + "/" + treeInfo.schema._id + "/" + treeInfo.trigger_function._id;
         }
-        else if (d._type == "trigger") {
+        else if (d._type == "trigger" && "table" in treeInfo) {
           var baseUrl = "{{ url_for('debugger.index') }}" + "initialize_target/" + "indirect/" + treeInfo.server._id +
                                 "/" + treeInfo.database._id + "/" + treeInfo.schema._id + "/" + treeInfo.table._id +
                                 "/" + treeInfo.trigger._id;
         }
+        else if (d._type == "trigger" && "view" in treeInfo) {
+          var baseUrl = "{{ url_for('debugger.index') }}" + "initialize_target/" + "indirect/" + treeInfo.server._id +
+                                "/" + treeInfo.database._id + "/" + treeInfo.schema._id + "/" + treeInfo.view._id +
+                                "/" + treeInfo.trigger._id;
+        }
 
         $.ajax({
           url: baseUrl,

Reply via email to