Skip to content

Commit

Permalink
create new user roles
Browse files Browse the repository at this point in the history
  • Loading branch information
Boonyarit Rousamran authored and hokkung committed Apr 5, 2024
1 parent 4a99bc1 commit 0d56c89
Showing 1 changed file with 22 additions and 0 deletions.
22 changes: 22 additions & 0 deletions src/main/resources/db/changelog/changelog-v1.4.0.xml
Original file line number Diff line number Diff line change
Expand Up @@ -36,4 +36,26 @@ http://www.liquibase.org/xml/ns/pro http://www.liquibase.org/xml/ns/pro/liquibas
<changeSet id="1.4.4-add-unique-constraint-email" author="Leo">
<addUniqueConstraint tableName="users" columnNames="email" />
</changeSet>
<changeSet id="1.4.5-drop_user_roles_table" author="Leo">
<dropTable tableName="user_roles" />
</changeSet>
<changeSet id="1.4.6-create_role_table" author="Leo">
<createTable tableName="roles">
<column name="id" type="BIGINT">
<constraints primaryKey="true" />
</column>
<column name="name" type="VARCHAR(100)" defaultValue="unspecified">
<constraints nullable="false" />
</column>
</createTable>
</changeSet>
<changeSet id="1.4.6-create_user_roles_table" author="Leo">
<createTable tableName="user_roles">
<column name="user_id" type="BIGINT"/>
<column name="role_id" type="BIGINT"/>
</createTable>
</changeSet>
<changeSet id="1.4.7-create-constraint-into-user_roles" author="Leo">
<addPrimaryKey tableName="user_roles" columnNames="user_id,role_id" />
</changeSet>
</databaseChangeLog>

0 comments on commit 0d56c89

Please sign in to comment.