mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2025-02-25 18:55:31 -06:00
Catch errors when trying to EXPLAIN an invalid query. Fixes #3257
This commit is contained in:
parent
79edf40141
commit
c08adb5567
@ -9,6 +9,7 @@ for it.
|
||||
|
||||
.. toctree::
|
||||
|
||||
release_notes_3_1
|
||||
release_notes_3_0
|
||||
release_notes_2_1
|
||||
release_notes_2_0
|
||||
|
17
docs/en_US/release_notes_3_1.rst
Normal file
17
docs/en_US/release_notes_3_1.rst
Normal file
@ -0,0 +1,17 @@
|
||||
***********
|
||||
Version 3.1
|
||||
***********
|
||||
|
||||
Release date: 2018-??-??
|
||||
|
||||
This release contains a number of features and fixes reported since the release of pgAdmin4 3.0
|
||||
|
||||
|
||||
Features
|
||||
********
|
||||
|
||||
|
||||
Bug fixes
|
||||
*********
|
||||
|
||||
| `Bug #3257 <https://redmine.postgresql.org/issues/3257>`_ - Catch errors when trying to EXPLAIN an invalid query
|
@ -1,23 +1,15 @@
|
||||
EXPLAIN (
|
||||
{% if format %}
|
||||
EXPLAIN ({% if format -%}
|
||||
FORMAT {{ format.upper() }},
|
||||
{% endif %}
|
||||
{% if analyze is defined %}
|
||||
{%- endif %}{% if analyze is defined -%}
|
||||
ANALYZE {{ analyze }},
|
||||
{% endif %}
|
||||
{% if verbose is defined %}
|
||||
{%- endif %}{% if verbose is defined -%}
|
||||
VERBOSE {{ verbose }},
|
||||
{% endif %}
|
||||
{% if costs is defined %}
|
||||
{%- endif %}{% if costs is defined -%}
|
||||
COSTS {{ costs }},
|
||||
{% endif %}
|
||||
{% if timing is defined %}
|
||||
{%- endif %}{% if timing is defined -%}
|
||||
TIMING {{ timing }},
|
||||
{% endif %}
|
||||
{% if summary is defined %}
|
||||
{%- endif %}{% if summary is defined -%}
|
||||
SUMMARY {{ summary }},
|
||||
{% endif %}
|
||||
{% if buffers is defined %}
|
||||
{%- endif %}{% if buffers is defined -%}
|
||||
BUFFERS {{ buffers }}
|
||||
{% endif %}
|
||||
) {{ sql }}
|
||||
{%- endif %}) {{ sql }}
|
||||
|
@ -1,20 +1,13 @@
|
||||
EXPLAIN (
|
||||
{% if format %}
|
||||
EXPLAIN ({% if format -%}
|
||||
FORMAT {{ format.upper() }},
|
||||
{% endif %}
|
||||
{% if analyze is defined %}
|
||||
{%- endif %}{% if analyze is defined -%}
|
||||
ANALYZE {{ analyze }},
|
||||
{% endif %}
|
||||
{% if verbose is defined %}
|
||||
{%- endif %}{% if verbose is defined -%}
|
||||
VERBOSE {{ verbose }},
|
||||
{% endif %}
|
||||
{% if costs is defined %}
|
||||
{%- endif %}{% if costs is defined -%}
|
||||
COSTS {{ costs }},
|
||||
{% endif %}
|
||||
{% if timing is defined %}
|
||||
{%- endif %}{% if timing is defined -%}
|
||||
TIMING {{ timing }},
|
||||
{% endif %}
|
||||
{% if buffers is defined %}
|
||||
{%- endif %}{% if buffers is defined -%}
|
||||
BUFFERS {{ buffers }}
|
||||
{% endif %}
|
||||
) {{ sql }}
|
||||
{%- endif %}) {{ sql }}
|
||||
|
@ -1,17 +1,10 @@
|
||||
EXPLAIN (
|
||||
{% if format %}
|
||||
EXPLAIN ({% if format -%}
|
||||
FORMAT {{ format.upper() }},
|
||||
{% endif %}
|
||||
{% if analyze is defined %}
|
||||
ANALYZE {{ analyze }},
|
||||
{% endif %}
|
||||
{% if verbose is defined %}
|
||||
{%- endif %}{% if analyze is defined -%}
|
||||
ANALYZE {{ analyze }},{%- endif %}{% if verbose is defined -%}
|
||||
VERBOSE {{ verbose }},
|
||||
{% endif %}
|
||||
{% if costs is defined %}
|
||||
{%- endif %}{% if costs is defined -%}
|
||||
COSTS {{ costs }},
|
||||
{% endif %}
|
||||
{% if buffers is defined %}
|
||||
{%- endif %}{% if buffers is defined -%}
|
||||
BUFFERS {{ buffers }}
|
||||
{% endif %}
|
||||
) {{ sql }}
|
||||
{%- endif %}) {{ sql }}
|
||||
|
@ -1,5 +1 @@
|
||||
EXPLAIN
|
||||
{% if analyze %}
|
||||
ANALYZE
|
||||
{% endif %}
|
||||
{{ sql }}
|
||||
EXPLAIN {% if analyze %}ANALYZE {% endif %}{{ sql }}
|
||||
|
@ -35,8 +35,8 @@ class TestExplainPlanTemplates(BaseTestGenerator):
|
||||
),
|
||||
sql_statement='SELECT * FROM places',
|
||||
expected_return_value='EXPLAIN '
|
||||
'( FORMAT XML, ANALYZE True, '
|
||||
'VERBOSE True, COSTS False, '
|
||||
'(FORMAT XML,ANALYZE True,'
|
||||
'VERBOSE True,COSTS False,'
|
||||
'BUFFERS True) SELECT * FROM places'
|
||||
)
|
||||
),
|
||||
@ -54,7 +54,7 @@ class TestExplainPlanTemplates(BaseTestGenerator):
|
||||
),
|
||||
sql_statement='SELECT * FROM places',
|
||||
expected_return_value='EXPLAIN '
|
||||
'( FORMAT JSON, BUFFERS True) '
|
||||
'(FORMAT JSON,BUFFERS True) '
|
||||
'SELECT * FROM places'
|
||||
)
|
||||
),
|
||||
@ -73,7 +73,7 @@ class TestExplainPlanTemplates(BaseTestGenerator):
|
||||
),
|
||||
sql_statement='SELECT * FROM places',
|
||||
expected_return_value='EXPLAIN '
|
||||
'( FORMAT JSON, TIMING False, '
|
||||
'(FORMAT JSON,TIMING False,'
|
||||
'BUFFERS True) SELECT * FROM places'
|
||||
)
|
||||
),
|
||||
@ -93,8 +93,8 @@ class TestExplainPlanTemplates(BaseTestGenerator):
|
||||
),
|
||||
sql_statement='SELECT * FROM places',
|
||||
expected_return_value='EXPLAIN '
|
||||
'( FORMAT YAML, TIMING False, '
|
||||
'SUMMARY True, BUFFERS True) '
|
||||
'(FORMAT YAML,TIMING False,'
|
||||
'SUMMARY True,BUFFERS True) '
|
||||
'SELECT * FROM places'
|
||||
)
|
||||
),
|
||||
|
Loading…
Reference in New Issue
Block a user