Fixes #1118 - Handle null, or empty string for the comments in Jinja2

template for Sequence Node.
This commit is contained in:
Murtuza Zabuawala
2016-05-25 17:37:06 +05:30
committed by Ashesh Vashi
parent cf0f692d00
commit b1aa956af8
@@ -48,7 +48,7 @@ ALTER SEQUENCE {{ conn|qtIdent(o_data.schema, data.name) }}
{% set seqname = conn|qtIdent(o_data.schema, data.name) %} {% set seqname = conn|qtIdent(o_data.schema, data.name) %}
{% set schema = o_data.schema %} {% set schema = o_data.schema %}
{% endif %} {% endif %}
{% if data.comment and data.comment != o_data.comment %} {% if data.comment is defined and data.comment != o_data.comment %}
COMMENT ON SEQUENCE {{ seqname }} COMMENT ON SEQUENCE {{ seqname }}
IS {{ data.comment|qtLiteral }}; IS {{ data.comment|qtLiteral }};