diff --git a/web/pgadmin/browser/server_groups/servers/databases/templates/databases/sql/9.2_plus/alter_online.sql b/web/pgadmin/browser/server_groups/servers/databases/templates/databases/sql/9.2_plus/alter_online.sql index c713bf597..2f8f400d9 100644 --- a/web/pgadmin/browser/server_groups/servers/databases/templates/databases/sql/9.2_plus/alter_online.sql +++ b/web/pgadmin/browser/server_groups/servers/databases/templates/databases/sql/9.2_plus/alter_online.sql @@ -1,4 +1,4 @@ -{% import 'macros/security.macros' as SECLABLE %} +{% import 'macros/security.macros' as SECLABEL %} {% import 'macros/variable.macros' as VARIABLE %} {% import 'macros/privilege.macros' as PRIVILEGE %} {% import 'macros/default_privilege.macros' as DEFAULT_PRIVILEGE %} @@ -21,17 +21,17 @@ ALTER DATABASE {{ conn|qtIdent(data.name) }} WITH CONNECTION LIMIT = {{ data.dat {% set seclabels = data.seclabels %} {% if 'deleted' in seclabels and seclabels.deleted|length > 0 %} {% for r in seclabels.deleted %} -{{ SECLABLE.DROP(conn, 'DATABASE', data.name, r.provider) }} +{{ SECLABEL.DROP(conn, 'DATABASE', data.name, r.provider) }} {% endfor %} {% endif %} {% if 'added' in seclabels and seclabels.added|length > 0 %} {% for r in seclabels.added %} -{{ SECLABLE.APPLY(conn, 'DATABASE', data.name, r.provider, r.security_label) }} +{{ SECLABEL.APPLY(conn, 'DATABASE', data.name, r.provider, r.security_label) }} {% endfor %} {% endif %} {% if 'changed' in seclabels and seclabels.changed|length > 0 %} {% for r in seclabels.changed %} -{{ SECLABLE.APPLY(conn, 'DATABASE', data.name, r.provider, r.security_label) }} +{{ SECLABEL.APPLY(conn, 'DATABASE', data.name, r.provider, r.security_label) }} {% endfor %} {% endif %} {% endif %} @@ -167,4 +167,4 @@ ALTER DATABASE {{ conn|qtIdent(data.name) }} WITH CONNECTION LIMIT = {{ data.dat {% endif %} {% endif %} -{% endif %} \ No newline at end of file +{% endif %} diff --git a/web/pgadmin/browser/server_groups/servers/databases/templates/databases/sql/9.2_plus/grant.sql b/web/pgadmin/browser/server_groups/servers/databases/templates/databases/sql/9.2_plus/grant.sql index 2c07f2977..f2c8c3362 100644 --- a/web/pgadmin/browser/server_groups/servers/databases/templates/databases/sql/9.2_plus/grant.sql +++ b/web/pgadmin/browser/server_groups/servers/databases/templates/databases/sql/9.2_plus/grant.sql @@ -3,7 +3,7 @@ # other sql statments along with it, so we wrote # seprate sql for rest alter sql statments here #} -{% import 'macros/security.macros' as SECLABLE %} +{% import 'macros/security.macros' as SECLABEL %} {% import 'macros/variable.macros' as VARIABLE %} {% import 'macros/privilege.macros' as PRIVILEGE %} {% import 'macros/default_privilege.macros' as DEFAULT_PRIVILEGE %} @@ -15,7 +15,7 @@ COMMENT ON DATABASE {{ conn|qtIdent(data.name) }} {# To generate Security Label SQL using macro #} {% if data.securities %} {% for r in data.securities %} -{{ SECLABLE.APPLY(conn, 'DATABASE', data.name, r.provider, r.securitylabel) }} +{{ SECLABEL.APPLY(conn, 'DATABASE', data.name, r.provider, r.securitylabel) }} {% endfor %} {% endif %} {# To generate Variable SQL using macro #} diff --git a/web/pgadmin/browser/server_groups/servers/databases/templates/databases/sql/9.3_plus/alter_online.sql b/web/pgadmin/browser/server_groups/servers/databases/templates/databases/sql/9.3_plus/alter_online.sql index 6923f9333..ee048002f 100644 --- a/web/pgadmin/browser/server_groups/servers/databases/templates/databases/sql/9.3_plus/alter_online.sql +++ b/web/pgadmin/browser/server_groups/servers/databases/templates/databases/sql/9.3_plus/alter_online.sql @@ -1,4 +1,4 @@ -{% import 'macros/security.macros' as SECLABLE %} +{% import 'macros/security.macros' as SECLABEL %} {% import 'macros/variable.macros' as VARIABLE %} {% import 'macros/privilege.macros' as PRIVILEGE %} {% import 'macros/default_privilege.macros' as DEFAULT_PRIVILEGE %} @@ -21,17 +21,17 @@ ALTER DATABASE {{ conn|qtIdent(data.name) }} WITH CONNECTION LIMIT = {{ data.dat {% set seclabels = data.seclabels %} {% if 'deleted' in seclabels and seclabels.deleted|length > 0 %} {% for r in seclabels.deleted %} -{{ SECLABLE.DROP(conn, 'DATABASE', data.name, r.provider) }} +{{ SECLABEL.DROP(conn, 'DATABASE', data.name, r.provider) }} {% endfor %} {% endif %} {% if 'added' in seclabels and seclabels.added|length > 0 %} {% for r in seclabels.added %} -{{ SECLABLE.APPLY(conn, 'DATABASE', data.name, r.provider, r.security_label) }} +{{ SECLABEL.APPLY(conn, 'DATABASE', data.name, r.provider, r.security_label) }} {% endfor %} {% endif %} {% if 'changed' in seclabels and seclabels.changed|length > 0 %} {% for r in seclabels.changed %} -{{ SECLABLE.APPLY(conn, 'DATABASE', data.name, r.provider, r.security_label) }} +{{ SECLABEL.APPLY(conn, 'DATABASE', data.name, r.provider, r.security_label) }} {% endfor %} {% endif %} {% endif %} @@ -163,4 +163,4 @@ ALTER DATABASE {{ conn|qtIdent(data.name) }} WITH CONNECTION LIMIT = {{ data.dat {% endif %} {% endif %} -{% endif %} \ No newline at end of file +{% endif %} diff --git a/web/pgadmin/browser/server_groups/servers/databases/templates/databases/sql/9.3_plus/grant.sql b/web/pgadmin/browser/server_groups/servers/databases/templates/databases/sql/9.3_plus/grant.sql index 6056bd7eb..4905e2b80 100644 --- a/web/pgadmin/browser/server_groups/servers/databases/templates/databases/sql/9.3_plus/grant.sql +++ b/web/pgadmin/browser/server_groups/servers/databases/templates/databases/sql/9.3_plus/grant.sql @@ -3,7 +3,7 @@ # other sql statments along with it, so we wrote # seprate sql for rest alter sql statments here #} -{% import 'macros/security.macros' as SECLABLE %} +{% import 'macros/security.macros' as SECLABEL %} {% import 'macros/variable.macros' as VARIABLE %} {% import 'macros/privilege.macros' as PRIVILEGE %} {% import 'macros/default_privilege.macros' as DEFAULT_PRIVILEGE %} @@ -15,7 +15,7 @@ COMMENT ON DATABASE {{ conn|qtIdent(data.name) }} {# We will generate Security Label SQL's using macro #} {% if data.securities %} {% for r in data.securities %} -{{ SECLABLE.APPLY(conn, 'DATABASE', data.name, r.provider, r.securitylabel) }} +{{ SECLABEL.APPLY(conn, 'DATABASE', data.name, r.provider, r.securitylabel) }} {% endfor %} {% endif %} {# We will generate Variable SQL's using macro #} diff --git a/web/pgadmin/browser/server_groups/servers/roles/templates/role/sql/post8_4/create.sql b/web/pgadmin/browser/server_groups/servers/roles/templates/role/sql/post8_4/create.sql index 8ed6e1736..b975a5465 100644 --- a/web/pgadmin/browser/server_groups/servers/roles/templates/role/sql/post8_4/create.sql +++ b/web/pgadmin/browser/server_groups/servers/roles/templates/role/sql/post8_4/create.sql @@ -1,4 +1,4 @@ -{% import 'macros/security.macros' as SECLABLE %} +{% import 'macros/security.macros' as SECLABEL %} {% import 'macros/variable.macros' as VARIABLE %} CREATE {% if data.rolcanlogin %}USER{% else %}ROLE{% endif %} {{ conn|qtIdent(data.rolname) }} WITH{% if data.rolcanlogin and data.rolcanlogin is sameas True %} diff --git a/web/pgadmin/browser/server_groups/servers/roles/templates/role/sql/post9_0/create.sql b/web/pgadmin/browser/server_groups/servers/roles/templates/role/sql/post9_0/create.sql index 0feb5d0ba..cb870d430 100644 --- a/web/pgadmin/browser/server_groups/servers/roles/templates/role/sql/post9_0/create.sql +++ b/web/pgadmin/browser/server_groups/servers/roles/templates/role/sql/post9_0/create.sql @@ -1,4 +1,4 @@ -{% import 'macros/security.macros' as SECLABLE %} +{% import 'macros/security.macros' as SECLABEL %} {% import 'macros/variable.macros' as VARIABLE %} CREATE {% if data.rolcanlogin %}USER{% else %}ROLE{% endif %} {{ conn|qtIdent(data.rolname) }} WITH{% if data.rolcanlogin and data.rolcanlogin is sameas True %} diff --git a/web/pgadmin/browser/server_groups/servers/roles/templates/role/sql/post9_1/create.sql b/web/pgadmin/browser/server_groups/servers/roles/templates/role/sql/post9_1/create.sql index 3dc80fb4d..07869859f 100644 --- a/web/pgadmin/browser/server_groups/servers/roles/templates/role/sql/post9_1/create.sql +++ b/web/pgadmin/browser/server_groups/servers/roles/templates/role/sql/post9_1/create.sql @@ -1,4 +1,4 @@ -{% import 'macros/security.macros' as SECLABLE %} +{% import 'macros/security.macros' as SECLABEL %} {% import 'macros/variable.macros' as VARIABLE %} CREATE {% if data.rolcanlogin %}USER{% else %}ROLE{% endif %} {{ conn|qtIdent(data.rolname) }} WITH{% if data.rolcanlogin and data.rolcanlogin is sameas True %} @@ -42,7 +42,7 @@ GRANT {{ conn|qtIdent(data.admins)|join(', ') }} TO {{ conn|qtIdent(data.rolname {% for r in data.seclabels %} -{{ SECLABLE.APPLY(conn, 'ROLE', data.rolname, r.provider, r.label) }} +{{ SECLABEL.APPLY(conn, 'ROLE', data.rolname, r.provider, r.label) }} {% endfor %}{% endif %}{% if data.variables %} {% for var in data.variables %} diff --git a/web/pgadmin/browser/server_groups/servers/roles/templates/role/sql/post9_1/update.sql b/web/pgadmin/browser/server_groups/servers/roles/templates/role/sql/post9_1/update.sql index 8ee9bdddf..dd79100b1 100644 --- a/web/pgadmin/browser/server_groups/servers/roles/templates/role/sql/post9_1/update.sql +++ b/web/pgadmin/browser/server_groups/servers/roles/templates/role/sql/post9_1/update.sql @@ -1,4 +1,4 @@ -{% import 'macros/security.macros' as SECLABLE %} +{% import 'macros/security.macros' as SECLABEL %} {% import 'macros/variable.macros' as VARIABLE %} {% if 'rolname' in data %} {% set rolname=data.rolname %} @@ -90,19 +90,19 @@ GRANT {{ conn|qtIdent(data.members)|join(', ') }} TO {{ conn|qtIdent(rolname) }} {% if 'deleted' in seclabels and seclabels.deleted|length > 0 %} {% for r in seclabels.deleted %} -{{ SECLABLE.DROP(conn, 'ROLE', data.rolname, r.provider) }} +{{ SECLABEL.DROP(conn, 'ROLE', data.rolname, r.provider) }} {% endfor %} {% endif %} {% if 'added' in seclabels and seclabels.added|length > 0 %} {% for r in seclabels.added %} -{{ SECLABLE.APPLY(conn, 'ROLE', data.rolname, r.provider, r.label) }} +{{ SECLABEL.APPLY(conn, 'ROLE', data.rolname, r.provider, r.label) }} {% endfor %} {% endif %} {% if 'changed' in seclabels and seclabels.changed|length > 0 %} {% for r in seclabels.changed %} -{{ SECLABLE.APPLY(conn, 'ROLE', data.rolname, r.provider, r.label) }} +{{ SECLABEL.APPLY(conn, 'ROLE', data.rolname, r.provider, r.label) }} {% endfor %} {% endif %} {% endif %} diff --git a/web/pgadmin/browser/server_groups/servers/roles/templates/role/sql/post9_4/create.sql b/web/pgadmin/browser/server_groups/servers/roles/templates/role/sql/post9_4/create.sql index ebfe6cec7..f5ab674cf 100644 --- a/web/pgadmin/browser/server_groups/servers/roles/templates/role/sql/post9_4/create.sql +++ b/web/pgadmin/browser/server_groups/servers/roles/templates/role/sql/post9_4/create.sql @@ -1,4 +1,4 @@ -{% import 'macros/security.macros' as SECLABLE %} +{% import 'macros/security.macros' as SECLABEL %} {% import 'macros/variable.macros' as VARIABLE %} CREATE {% if data.rolcanlogin %}USER{% else %}ROLE{% endif %} {{ conn|qtIdent(data.rolname) }} WITH{% if data.rolcanlogin and data.rolcanlogin is sameas True %} @@ -39,7 +39,7 @@ GRANT {{ conn|qtIdent(data.admins)|join(', ') }} TO {{ conn|qtIdent(data.rolname {% for r in data.seclabels %} -{{ SECLABLE.APPLY(conn, 'ROLE', data.rolname, r.provider, r.label) }} +{{ SECLABEL.APPLY(conn, 'ROLE', data.rolname, r.provider, r.label) }} {% endfor %}{% endif %}{% if data.variables %} {% for var in data.variables %} diff --git a/web/pgadmin/browser/server_groups/servers/roles/templates/role/sql/post9_4/update.sql b/web/pgadmin/browser/server_groups/servers/roles/templates/role/sql/post9_4/update.sql index 7ad498fa0..2f7574f6a 100644 --- a/web/pgadmin/browser/server_groups/servers/roles/templates/role/sql/post9_4/update.sql +++ b/web/pgadmin/browser/server_groups/servers/roles/templates/role/sql/post9_4/update.sql @@ -1,4 +1,4 @@ -{% import 'macros/security.macros' as SECLABLE %} +{% import 'macros/security.macros' as SECLABEL %} {% import 'macros/variable.macros' as VARIABLE %} {% if 'rolname' in data %} {% set rolname=data.rolname %} @@ -65,19 +65,19 @@ GRANT {{ conn|qtIdent(data.members)|join(', ') }} TO {{ conn|qtIdent(rolname) }} {% if 'deleted' in seclabels and seclabels.deleted|length > 0 %} {% for r in seclabels.deleted %} -{{ SECLABLE.DROP(conn, 'ROLE', data.rolname, r.provider) }} +{{ SECLABEL.DROP(conn, 'ROLE', data.rolname, r.provider) }} {% endfor %} {% endif %} {% if 'added' in seclabels and seclabels.added|length > 0 %} {% for r in seclabels.added %} -{{ SECLABLE.APPLY(conn, 'ROLE', data.rolname, r.provider, r.label) }} +{{ SECLABEL.APPLY(conn, 'ROLE', data.rolname, r.provider, r.label) }} {% endfor %} {% endif %} {% if 'changed' in seclabels and seclabels.changed|length > 0 %} {% for r in seclabels.changed %} -{{ SECLABLE.APPLY(conn, 'ROLE', data.rolname, r.provider, r.label) }} +{{ SECLABEL.APPLY(conn, 'ROLE', data.rolname, r.provider, r.label) }} {% endfor %} {% endif %} {% endif %} diff --git a/web/pgadmin/browser/server_groups/servers/tablespaces/templates/tablespaces/sql/9.1_plus/alter.sql b/web/pgadmin/browser/server_groups/servers/tablespaces/templates/tablespaces/sql/9.1_plus/alter.sql index bc4a7c75b..690cc0144 100755 --- a/web/pgadmin/browser/server_groups/servers/tablespaces/templates/tablespaces/sql/9.1_plus/alter.sql +++ b/web/pgadmin/browser/server_groups/servers/tablespaces/templates/tablespaces/sql/9.1_plus/alter.sql @@ -1,5 +1,5 @@ {### SQL to alter tablespace ###} -{% import 'macros/security.macros' as SECLABLE %} +{% import 'macros/security.macros' as SECLABEL %} {% import 'macros/variable.macros' as VARIABLE %} {% import 'macros/privilege.macros' as PRIVILEGE %} {% if data %} @@ -18,7 +18,7 @@ COMMENT ON TABLESPACE {{ conn|qtIdent(data.name) }} {### Security Labels on tablespace ###} {% if data.seclabels and data.seclabels|length > 0 %} {% for r in data.seclabels %} -{{ SECLABLE.APPLY(conn, 'TABLESPACE', data.name, r.provider, r.security_label) }} +{{ SECLABEL.APPLY(conn, 'TABLESPACE', data.name, r.provider, r.security_label) }} {% endfor %} {% endif %} diff --git a/web/pgadmin/browser/server_groups/servers/tablespaces/templates/tablespaces/sql/9.2_plus/alter.sql b/web/pgadmin/browser/server_groups/servers/tablespaces/templates/tablespaces/sql/9.2_plus/alter.sql index bc4a7c75b..690cc0144 100755 --- a/web/pgadmin/browser/server_groups/servers/tablespaces/templates/tablespaces/sql/9.2_plus/alter.sql +++ b/web/pgadmin/browser/server_groups/servers/tablespaces/templates/tablespaces/sql/9.2_plus/alter.sql @@ -1,5 +1,5 @@ {### SQL to alter tablespace ###} -{% import 'macros/security.macros' as SECLABLE %} +{% import 'macros/security.macros' as SECLABEL %} {% import 'macros/variable.macros' as VARIABLE %} {% import 'macros/privilege.macros' as PRIVILEGE %} {% if data %} @@ -18,7 +18,7 @@ COMMENT ON TABLESPACE {{ conn|qtIdent(data.name) }} {### Security Labels on tablespace ###} {% if data.seclabels and data.seclabels|length > 0 %} {% for r in data.seclabels %} -{{ SECLABLE.APPLY(conn, 'TABLESPACE', data.name, r.provider, r.security_label) }} +{{ SECLABEL.APPLY(conn, 'TABLESPACE', data.name, r.provider, r.security_label) }} {% endfor %} {% endif %} diff --git a/web/pgadmin/browser/server_groups/servers/tablespaces/templates/tablespaces/sql/9.2_plus/update.sql b/web/pgadmin/browser/server_groups/servers/tablespaces/templates/tablespaces/sql/9.2_plus/update.sql index d85a837c1..7b4bd2c9a 100644 --- a/web/pgadmin/browser/server_groups/servers/tablespaces/templates/tablespaces/sql/9.2_plus/update.sql +++ b/web/pgadmin/browser/server_groups/servers/tablespaces/templates/tablespaces/sql/9.2_plus/update.sql @@ -1,5 +1,5 @@ {### SQL to update tablespace object ###} -{% import 'macros/security.macros' as SECLABLE %} +{% import 'macros/security.macros' as SECLABEL %} {% import 'macros/variable.macros' as VARIABLE %} {% import 'macros/privilege.macros' as PRIVILEGE %} {% if data %} @@ -41,17 +41,17 @@ COMMENT ON TABLESPACE {{ conn|qtIdent(data.name) }} {% set seclabels = data.seclabels %} {% if 'deleted' in seclabels and seclabels.deleted|length > 0 %} {% for r in seclabels.deleted %} -{{ SECLABLE.DROP(conn, 'TABLESPACE', data.name, r.provider) }} +{{ SECLABEL.DROP(conn, 'TABLESPACE', data.name, r.provider) }} {% endfor %} {% endif %} {% if 'added' in seclabels and seclabels.added|length > 0 %} {% for r in seclabels.added %} -{{ SECLABLE.APPLY(conn, 'TABLESPACE', data.name, r.provider, r.security_label) }} +{{ SECLABEL.APPLY(conn, 'TABLESPACE', data.name, r.provider, r.security_label) }} {% endfor %} {% endif %} {% if 'changed' in seclabels and seclabels.changed|length > 0 %} {% for r in seclabels.changed %} -{{ SECLABLE.APPLY(conn, 'TABLESPACE', data.name, r.provider, r.security_label) }} +{{ SECLABEL.APPLY(conn, 'TABLESPACE', data.name, r.provider, r.security_label) }} {% endfor %} {% endif %} @@ -77,4 +77,4 @@ COMMENT ON TABLESPACE {{ conn|qtIdent(data.name) }} {% endif %} {% endif %} -{% endif %} \ No newline at end of file +{% endif %} diff --git a/web/pgadmin/browser/server_groups/servers/tablespaces/templates/tablespaces/sql/pre_9.1/alter.sql b/web/pgadmin/browser/server_groups/servers/tablespaces/templates/tablespaces/sql/pre_9.1/alter.sql index bc4a7c75b..690cc0144 100755 --- a/web/pgadmin/browser/server_groups/servers/tablespaces/templates/tablespaces/sql/pre_9.1/alter.sql +++ b/web/pgadmin/browser/server_groups/servers/tablespaces/templates/tablespaces/sql/pre_9.1/alter.sql @@ -1,5 +1,5 @@ {### SQL to alter tablespace ###} -{% import 'macros/security.macros' as SECLABLE %} +{% import 'macros/security.macros' as SECLABEL %} {% import 'macros/variable.macros' as VARIABLE %} {% import 'macros/privilege.macros' as PRIVILEGE %} {% if data %} @@ -18,7 +18,7 @@ COMMENT ON TABLESPACE {{ conn|qtIdent(data.name) }} {### Security Labels on tablespace ###} {% if data.seclabels and data.seclabels|length > 0 %} {% for r in data.seclabels %} -{{ SECLABLE.APPLY(conn, 'TABLESPACE', data.name, r.provider, r.security_label) }} +{{ SECLABEL.APPLY(conn, 'TABLESPACE', data.name, r.provider, r.security_label) }} {% endfor %} {% endif %}