1) Ensure that the Owner should not be disabled while creating the procedure. Fixes #7064

2) Fixed an issue where Explain Analyze shows negative exclusive time. Fixes #7003
pull/63/head
Nikhil Mohite 2021-12-09 16:59:43 +05:30 committed by Akshay Joshi
parent 4ee9a95360
commit 9ec8d05a64
5 changed files with 18 additions and 6 deletions

View File

@ -207,7 +207,7 @@ the *Data Output* tab.
* Table
*Table* tab shows the plan details in table format, it generates table format
similar to *explain.depsez.com*. Each row of the table represent the data for a
similar to *explain.depesz.com*. Each row of the table represent the data for a
*Explain Plan Node*. It may contain the node information, exclusive timing,
inclusive timing, actual vs planned rows differences, actual rows, planned
rows, loops.

View File

@ -31,6 +31,7 @@ Bug fixes
| `Issue #6978 <https://redmine.postgresql.org/issues/6978>`_ - Increase the width of the scrollbars.
| `Issue #6986 <https://redmine.postgresql.org/issues/6986>`_ - Fixed an issue where the user can't debug function with timestamp parameter.
| `Issue #6989 <https://redmine.postgresql.org/issues/6989>`_ - Fixed an issue where the Change Password menu option is missing for internal authentication source when more than one authentication source is defined.
| `Issue #7003 <https://redmine.postgresql.org/issues/7003>`_ - Fixed an issue where Explain Analyze shows negative exclusive time.
| `Issue #7005 <https://redmine.postgresql.org/issues/7005>`_ - Fixed an issue where On-demand rows throw an error when any row cell is edited and saved it then scroll to get more rows.
| `Issue #7006 <https://redmine.postgresql.org/issues/7006>`_ - Ensure that Python 3.10 and the latest eventlet dependency should not break the application.
| `Issue #7013 <https://redmine.postgresql.org/issues/7013>`_ - Fix an RPM build issue that could lead to a conflict with python3 at installation.
@ -42,3 +43,4 @@ Bug fixes
| `Issue #7044 <https://redmine.postgresql.org/issues/7044>`_ - Update the dropzone version to 5.9.3 and Flask-SQLAlchemy to 2.5.*.
| `Issue #7046 <https://redmine.postgresql.org/issues/7046>`_ - Fixed some accessibility issues.
| `Issue #7048 <https://redmine.postgresql.org/issues/7048>`_ - Fixed unhashable type issue while opening the about dialog.
| `Issue #7064 <https://redmine.postgresql.org/issues/7064>`_ - Ensure that the Owner should not be disabled while creating the procedure.

View File

@ -209,7 +209,13 @@ export default class FunctionSchema extends BaseUISchema {
},{
id: 'funcowner', label: gettext('Owner'), cell: 'string',
options: this.fieldOptions.role, type: 'select',
disabled: (!(this.type === 'procedure')) ? obj.inCatalog() : obj.isGreaterThan95,
disabled: (state) => {
if (!(this.type === 'procedure')) {
obj.inCatalog(state);
} else {
obj.isGreaterThan95(state);
}
},
noEmpty: true,
},{
id: 'pronamespace', label: gettext('Schema'), cell: 'string',

View File

@ -121,7 +121,7 @@ define('pgadmin.node.procedure', [
{
funcowner: pgBrowser.serverInfo[treeNodeInfo.server._id].user.name,
pronamespace: treeNodeInfo.schema ? treeNodeInfo.schema._id : null,
lanname: 'edbspl',
lanname: treeNodeInfo.server.server_type != 'ppas' ? 'sql' : 'edbspl',
}
);
},

View File

@ -660,7 +660,7 @@ define('pgadmin.misc.explain', [
if ('Actual Total Time' in data && 'Actual Loops' in data) {
data['inclusive'] = Math.ceil10(
data['Actual Total Time'] * data['Actual Loops'], -3
data['Actual Total Time'], -3
);
data['exclusive'] = data['inclusive'];
data['inclusive_factor'] = data['inclusive'] / (
@ -687,7 +687,7 @@ define('pgadmin.misc.explain', [
data['rowsx_flag'] = data['rowsx'] <= 10 ? '1' : (
data['rowsx'] <= 100 ? '2' : (data['rowsx'] <= 1000 ? '3' : '4')
);
data['rowsx'] = Math.ceil10(data['rowsx'], -2);
data['rowsx'] = Math.ceil10(data['rowsx'] / data['loops'], -2);
}
// Start calculating xpos, ypos, width and height for child plans if any
@ -709,6 +709,7 @@ define('pgadmin.misc.explain', [
ypos: ypos,
total_time: data['total_time'] || data['Actual Total Time'],
parent_node: lvl.join('_'),
loops: data['Actual Loops']
}), _opt));
if (maxChildWidth < plan.get('width')) {
@ -717,7 +718,7 @@ define('pgadmin.misc.explain', [
if ('exclusive' in data) {
inclusive = plan.get('inclusive');
if (inclusive) {
if (inclusive && inclusive < data['exclusive']) {
data['exclusive'] -= inclusive;
}
}
@ -734,6 +735,9 @@ define('pgadmin.misc.explain', [
plans.push(plan);
idx++;
});
} else{
data['inclusive'] = Math.ceil10(data['Actual Total Time'] / data['loops'], -3)
data['exclusive'] = data['inclusive'];
}
if ('exclusive' in data) {