1 <?xml version="1.1" encoding="UTF-8" standalone="no"?>
2 <databaseChangeLog xmlns="http://www.liquibase.org/xml/ns/dbchangelog" xmlns:ext="http://www.liquibase.org/xml/ns/dbchangelog-ext" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog-ext http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-ext.xsd http://www.liquibase.org/xml/ns/dbchangelog http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-3.5.xsd">
3 <changeSet author="gustavo (generated)" id="1469119656864-1" objectQuotingStrategy="QUOTE_ALL_OBJECTS">
4 <createTable tableName="AD">
5 <column autoIncrement="true" name="ID" type="BIGINT">
6 <constraints primaryKey="true"/>
8 <column name="COMPANY_ID" type="BIGINT"/>
9 <column name="COMPANY_CATEG_ID" type="BIGINT"/>
10 <column name="AD_GPS" type="BLOB"/>
11 <column name="AD_MOBILE_IMAGE" type="VARCHAR(255)"/>
12 <column defaultValueComputed="CURRENT_TIMESTAMP" name="CREATED_AT" type="TIMESTAMP">
13 <constraints nullable="false"/>
15 <column defaultValue="0000-00-00 00:00:00" name="UPDATED_AT" type="TIMESTAMP">
16 <constraints nullable="false"/>
19 <modifySql dbms="mysql">
20 <append value="ENGINE=InnoDB CHARSET=utf8 COLLATE utf8_unicode_ci"/>
23 <changeSet author="gustavo (generated)" id="1469119656864-2" objectQuotingStrategy="QUOTE_ALL_OBJECTS">
24 <createTable tableName="AD_AUDITED">
25 <column name="ID" type="BIGINT">
26 <constraints nullable="false"/>
28 <column name="REVISION" type="BIGINT">
29 <constraints nullable="false"/>
31 <column name="REVISION_TYPE" type="TINYINT(3)"/>
32 <column name="REVISION_END" type="BIGINT"/>
33 <column name="REVISION_END_TIMESTAMP" type="datetime"/>
34 <column name="AD_MOBILE_IMAGE" type="VARCHAR(255)"/>
35 <column name="adMobileImage_MODIFIED" type="BIT(1)"/>
36 <column name="COMPANY_CATEG_ID" type="BIGINT"/>
37 <column name="companyCategId_MODIFIED" type="BIT(1)"/>
38 <column name="COMPANY_ID" type="BIGINT"/>
39 <column name="companyId_MODIFIED" type="BIT(1)"/>
40 <column name="CREATED_AT" type="datetime"/>
41 <column name="createdAt_MODIFIED" type="BIT(1)"/>
42 <column name="UPDATED_AT" type="datetime"/>
43 <column name="updatedAt_MODIFIED" type="BIT(1)"/>
44 <column name="adDescriptions_MODIFIED" type="BIT(1)"/>
46 <modifySql dbms="mysql">
47 <append value="ENGINE=InnoDB CHARSET=utf8 COLLATE utf8_unicode_ci"/>
50 <changeSet author="gustavo (generated)" id="1469119656864-3" objectQuotingStrategy="QUOTE_ALL_OBJECTS">
51 <createTable tableName="AD_DESCRIPTION">
52 <column autoIncrement="true" name="ID" type="BIGINT">
53 <constraints primaryKey="true"/>
55 <column name="LANGUAGE_ID" type="BIGINT">
56 <constraints nullable="false"/>
58 <column name="AD_ID" type="BIGINT"/>
59 <column name="AD_NAME" type="VARCHAR(255)">
60 <constraints nullable="false"/>
62 <column name="AD_DESCRIPTION" type="LONGTEXT"/>
63 <column name="AD_MOBILE_TEXT" type="VARCHAR(500)">
64 <constraints nullable="false"/>
66 <column name="AD_LINK" type="VARCHAR(3000)">
67 <constraints nullable="false"/>
70 <modifySql dbms="mysql">
71 <append value="ENGINE=InnoDB CHARSET=utf8 COLLATE utf8_unicode_ci"/>
74 <changeSet author="gustavo (generated)" id="1469119656864-4" objectQuotingStrategy="QUOTE_ALL_OBJECTS">
75 <createTable tableName="AD_DESCRIPTION_AUDITED">
76 <column name="ID" type="BIGINT">
77 <constraints nullable="false"/>
79 <column name="REVISION" type="BIGINT">
80 <constraints nullable="false"/>
82 <column name="REVISION_TYPE" type="TINYINT(3)"/>
83 <column name="REVISION_END" type="BIGINT"/>
84 <column name="REVISION_END_TIMESTAMP" type="datetime"/>
85 <column name="AD_DESCRIPTION" type="VARCHAR(255)"/>
86 <column name="AD_LINK" type="VARCHAR(255)"/>
87 <column name="AD_MOBILE_TEXT" type="VARCHAR(255)"/>
88 <column name="AD_NAME" type="VARCHAR(255)"/>
89 <column name="LANGUAGE_ID" type="BIGINT"/>
90 <column name="AD_ID" type="BIGINT"/>
92 <modifySql dbms="mysql">
93 <append value="ENGINE=InnoDB CHARSET=utf8 COLLATE utf8_unicode_ci"/>
96 <changeSet author="gustavo (generated)" id="1469119656864-5" objectQuotingStrategy="QUOTE_ALL_OBJECTS">
97 <createTable tableName="CUSTOM_REVISION">
98 <column name="ID" type="BIGINT">
99 <constraints nullable="false"/>
101 <column name="REVISION_DATE" type="BIGINT">
102 <constraints nullable="false"/>
104 <column name="USERNAME" type="VARCHAR(255)"/>
106 <modifySql dbms="mysql">
107 <append value="ENGINE=InnoDB CHARSET=utf8 COLLATE utf8_unicode_ci"/>
110 <changeSet author="gustavo (generated)" id="1469119656864-6" objectQuotingStrategy="QUOTE_ALL_OBJECTS">
111 <createTable tableName="con_test">
112 <column name="a" type="CHAR(1)"/>
115 <changeSet author="gustavo (generated)" id="1469119656864-7" objectQuotingStrategy="QUOTE_ALL_OBJECTS">
116 <addPrimaryKey columnNames="ID, REVISION" constraintName="PRIMARY" tableName="AD_AUDITED"/>
118 <changeSet author="gustavo (generated)" id="1469119656864-8" objectQuotingStrategy="QUOTE_ALL_OBJECTS">
119 <addPrimaryKey columnNames="ID, REVISION" constraintName="PRIMARY" tableName="AD_DESCRIPTION_AUDITED"/>
121 <changeSet author="gustavo (generated)" id="1469119656864-9" objectQuotingStrategy="QUOTE_ALL_OBJECTS">
122 <addPrimaryKey columnNames="ID" constraintName="PRIMARY" tableName="CUSTOM_REVISION"/>
124 <changeSet author="gustavo (generated)" id="1469119656864-10" objectQuotingStrategy="QUOTE_ALL_OBJECTS">
125 <createIndex indexName="FK5kfkyp713lqaiybgbyjpjibgh" tableName="AD_DESCRIPTION">
126 <column name="AD_ID"/>
129 <changeSet author="gustavo (generated)" id="1469119656864-11" objectQuotingStrategy="QUOTE_ALL_OBJECTS">
130 <createIndex indexName="FK96c2brah4r0lo3uevpptryfgc" tableName="AD_DESCRIPTION_AUDITED">
131 <column name="REVISION"/>
134 <changeSet author="gustavo (generated)" id="1469119656864-12" objectQuotingStrategy="QUOTE_ALL_OBJECTS">
135 <createIndex indexName="FKdii961w5phmscfhw04iv3ur76" tableName="AD_AUDITED">
136 <column name="REVISION"/>
139 <changeSet author="gustavo (generated)" id="1469119656864-13" objectQuotingStrategy="QUOTE_ALL_OBJECTS">
140 <createIndex indexName="FKgw7fxrsc46dchjriobk8ivqwx" tableName="AD_AUDITED">
141 <column name="REVISION_END"/>
144 <changeSet author="gustavo (generated)" id="1469119656864-14" objectQuotingStrategy="QUOTE_ALL_OBJECTS">
145 <createIndex indexName="FKjox6d8yc1qj061bfidmu3gl4d" tableName="AD_DESCRIPTION_AUDITED">
146 <column name="REVISION_END"/>
149 <changeSet author="gustavo (generated)" id="1469119656864-15" objectQuotingStrategy="QUOTE_ALL_OBJECTS">
150 <addForeignKeyConstraint baseColumnNames="AD_ID" baseTableName="AD_DESCRIPTION" constraintName="FK5kfkyp713lqaiybgbyjpjibgh" deferrable="false" initiallyDeferred="false" onDelete="NO ACTION" onUpdate="NO ACTION" referencedColumnNames="ID" referencedTableName="AD"/>
152 <changeSet author="gustavo (generated)" id="1469119656864-16" objectQuotingStrategy="QUOTE_ALL_OBJECTS">
153 <addForeignKeyConstraint baseColumnNames="REVISION" baseTableName="AD_DESCRIPTION_AUDITED" constraintName="FK96c2brah4r0lo3uevpptryfgc" deferrable="false" initiallyDeferred="false" onDelete="NO ACTION" onUpdate="NO ACTION" referencedColumnNames="ID" referencedTableName="CUSTOM_REVISION"/>
155 <changeSet author="gustavo (generated)" id="1469119656864-17" objectQuotingStrategy="QUOTE_ALL_OBJECTS">
156 <addForeignKeyConstraint baseColumnNames="REVISION" baseTableName="AD_AUDITED" constraintName="FKdii961w5phmscfhw04iv3ur76" deferrable="false" initiallyDeferred="false" onDelete="NO ACTION" onUpdate="NO ACTION" referencedColumnNames="ID" referencedTableName="CUSTOM_REVISION"/>
158 <changeSet author="gustavo (generated)" id="1469119656864-18" objectQuotingStrategy="QUOTE_ALL_OBJECTS">
159 <addForeignKeyConstraint baseColumnNames="REVISION_END" baseTableName="AD_AUDITED" constraintName="FKgw7fxrsc46dchjriobk8ivqwx" deferrable="false" initiallyDeferred="false" onDelete="NO ACTION" onUpdate="NO ACTION" referencedColumnNames="ID" referencedTableName="CUSTOM_REVISION"/>
161 <changeSet author="gustavo (generated)" id="1469119656864-19" objectQuotingStrategy="QUOTE_ALL_OBJECTS">
162 <addForeignKeyConstraint baseColumnNames="REVISION_END" baseTableName="AD_DESCRIPTION_AUDITED" constraintName="FKjox6d8yc1qj061bfidmu3gl4d" deferrable="false" initiallyDeferred="false" onDelete="NO ACTION" onUpdate="NO ACTION" referencedColumnNames="ID" referencedTableName="CUSTOM_REVISION"/>