-
Notifications
You must be signed in to change notification settings - Fork 74
v0.2.47..v0.2.48 changeset 027 AddUserPrivileges.xml
Garret Voltz edited this page Sep 27, 2019
·
1 revision
diff --git a/hoot-services/src/main/resources/db/changelogs/027-AddUserPrivileges.xml b/hoot-services/src/main/resources/db/changelogs/027-AddUserPrivileges.xml
new file mode 100644
index 0000000..3079d7d
--- /dev/null
+++ b/hoot-services/src/main/resources/db/changelogs/027-AddUserPrivileges.xml
@@ -0,0 +1,22 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<databaseChangeLog xmlns="http://www.liquibase.org/xml/ns/dbchangelog"
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:ext="http://www.liquibase.org/xml/ns/dbchangelog-ext"
+ xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-2.0.xsd
+ http://www.liquibase.org/xml/ns/dbchangelog-ext http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-ext.xsd">
+ <changeSet author="bobby.simic" id="27" context="default">
+ <comment>
+ This change adds a hstore privileges column to the users table
+ </comment>
+
+ <addColumn tableName="users">
+ <column name="privileges" type="hstore" />
+ </addColumn>
+
+ <!-- sets a default value for future rows inserted into the column -->
+ <addDefaultValue tableName="users" columnName="privileges" defaultValue="" />
+
+ <!-- change the value of already existing rows to '' -->
+ <addNotNullConstraint tableName="users" columnName="privileges" defaultNullValue="" />
+
+ </changeSet>
+</databaseChangeLog>