Fixed an issue where reverse engineering SQL is wrong for Aggregate. Fixes #7024

pull/63/head
Akshay Joshi 2021-11-29 12:00:38 +05:30
parent abe5303448
commit fbd10ef4b6
4 changed files with 7 additions and 6 deletions

View File

@ -29,3 +29,4 @@ Bug fixes
| `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.
| `Issue #7015 <https://redmine.postgresql.org/issues/7015>`_ - Fixed an issue where the error is thrown while creating a new server using Add New Server from the dashboard while tree item is not selected.
| `Issue #7024 <https://redmine.postgresql.org/issues/7024>`_ - Fixed an issue where reverse engineering SQL is wrong for Aggregate.

View File

@ -9,7 +9,7 @@ CREATE AGGREGATE {{conn|qtIdent(data.schema, data.name)}}({% if data.input_types
COMBINEFUNC = {{data.combine_func}}{% endif %}{% if data.serialization_func %},
SERIALFUNC = {{data.serialization_func}}{% endif %}{% if data.deserialization_func %},
DESERIALFUNC = {{data.deserialization_func}}{% endif %}{% if data.initial_val %},
INITCOND = '{{data.initial_val}}'::text{% endif %}{% if data.moving_state_func %},
INITCOND = '{{data.initial_val}}'{% endif %}{% if data.moving_state_func %},
MSFUNC = {{data.moving_state_func}}{% endif %}{% if data.moving_inverse_func %},
MINVFUNC = {{data.moving_inverse_func}}{% endif %}{% if data.moving_state_type %},
MSTYPE = {{data.moving_state_type}}{% endif %}{% if data.moving_state_data_size %},
@ -17,7 +17,7 @@ CREATE AGGREGATE {{conn|qtIdent(data.schema, data.name)}}({% if data.input_types
MFINALFUNC = {{data.moving_final_func}}{% endif %}{% if data.moving_final_extra_param %},
MFINALFUNC_EXTRA{% endif %}{% if data.moving_final_func_modify %},
MFINALFUNC_MODIFY = {{data.moving_final_func_modify}}{% endif %}{% if data.moving_initial_val %},
MINITCOND = '{{data.moving_initial_val}}'::text{% endif %}{% if data.sort_oper %},
MINITCOND = '{{data.moving_initial_val}}'{% endif %}{% if data.sort_oper %},
SORTOP = {{data.sort_oper}}{% endif %}
);

View File

@ -9,7 +9,7 @@ CREATE OR REPLACE AGGREGATE {{conn|qtIdent(data.schema, data.name)}}({% if data.
COMBINEFUNC = {{data.combine_func}}{% endif %}{% if data.serialization_func %},
SERIALFUNC = {{data.serialization_func}}{% endif %}{% if data.deserialization_func %},
DESERIALFUNC = {{data.deserialization_func}}{% endif %}{% if data.initial_val %},
INITCOND = '{{data.initial_val}}'::text{% endif %}{% if data.moving_state_func %},
INITCOND = '{{data.initial_val}}'{% endif %}{% if data.moving_state_func %},
MSFUNC = {{data.moving_state_func}}{% endif %}{% if data.moving_inverse_func %},
MINVFUNC = {{data.moving_inverse_func}}{% endif %}{% if data.moving_state_type %},
MSTYPE = {{data.moving_state_type}}{% endif %}{% if data.moving_state_data_size %},
@ -17,7 +17,7 @@ CREATE OR REPLACE AGGREGATE {{conn|qtIdent(data.schema, data.name)}}({% if data.
MFINALFUNC = {{data.moving_final_func}}{% endif %}{% if data.moving_final_extra_param %},
MFINALFUNC_EXTRA{% endif %}{% if data.moving_final_func_modify %},
MFINALFUNC_MODIFY = {{data.moving_final_func_modify}}{% endif %}{% if data.moving_initial_val %},
MINITCOND = '{{data.moving_initial_val}}'::text{% endif %}{% if data.sort_oper %},
MINITCOND = '{{data.moving_initial_val}}'{% endif %}{% if data.sort_oper %},
SORTOP = {{data.sort_oper}}{% endif %}
);

View File

@ -8,14 +8,14 @@ CREATE AGGREGATE {{conn|qtIdent(data.schema, data.name)}}({% if data.input_types
COMBINEFUNC = {{data.combine_func}}{% endif %}{% if data.serialization_func %},
SERIALFUNC = {{data.serialization_func}}{% endif %}{% if data.deserialization_func %},
DESERIALFUNC = {{data.deserialization_func}}{% endif %}{% if data.initial_val %},
INITCOND = '{{data.initial_val}}'::text{% endif %}{% if data.moving_state_func %},
INITCOND = '{{data.initial_val}}'{% endif %}{% if data.moving_state_func %},
MSFUNC = {{data.moving_state_func}}{% endif %}{% if data.moving_inverse_func %},
MINVFUNC = {{data.moving_inverse_func}}{% endif %}{% if data.moving_state_type %},
MSTYPE = {{data.moving_state_type}}{% endif %}{% if data.moving_state_data_size %},
MSSPACE = {{data.moving_state_data_size}}{% endif %}{% if data.moving_final_func %},
MFINALFUNC = {{data.moving_final_func}}{% endif %}{% if data.moving_final_extra_param %},
MFINALFUNC_EXTRA{% endif %}{% if data.moving_initial_val %},
MINITCOND = '{{data.moving_initial_val}}'::text{% endif %}{% if data.sort_oper %},
MINITCOND = '{{data.moving_initial_val}}'{% endif %}{% if data.sort_oper %},
SORTOP = {{data.sort_oper}}{% endif %}
);