Hello,
we are using liquibase generator to generate jooq classes for a small 
project. Actually we are testing on postgres (but this project is db vendor 
agnostic) that is case sensitive.

By default liquibase generator loose cases (convert in UPPERCASE every name 
of table and column).

*How can I configure generator to preserve casing defined in liquibase?*

File attached shows the case. Tks for help.


-- 
*Thread Solutions s.r.l.*
Address: via Roberto da Sanseverino, 95 - 38122 
Trento - Italy

Phone: +39 0461 1903268



Questo messaggio viene inviato 
in osservanza al Reg. UE 2016/679. Le ricordiamo che in qualunque momento 
potrà esercitare tutti diritti previsti dal Reg. UE 2016/679, tra i quali 
il diritto di ottenere e/o accedere ai suoi dati personali per le finalità 
e modalità del trattamento, chiederne la rettifica e l’aggiornamento se 
incompleti o erronei, chiederne la cancellazione qualora la raccolta sia 
avvenuta in violazione di una legge o regolamento, nonché il diritto di 
opporsi al trattamento per motivi legittimi e specifici; esercitare il 
diritto alla cancellazione (ai sensi dell'Art. 17 del Reg. UE 2016/679), la 
trasformazione in forma anonima o il blocco dei dati trattati in violazione 
di legge; al trattamento di dati personali che la riguardano a fini di 
invio di materiale pubblicitario o di vendita diretta o per il compimento 
di ricerche di mercato o di comunicazione commerciale, contattando il 
Titolare del trattamento (Thread Solutions srl), con sede in via 
Sanseverino 95 Trento (Italy) - email *[email protected].* Può 
consultare la nostra informativa Privacy sul nostro sito istituzionale 
oppure presso la nostra sede. Le ricordiamo inoltre che il contenuto di 
questa e-mail è rivolto al destinatario della stessa, a carattere personale 
e riservato; se ha ricevuto questa e-mail per sbaglio chiediamo 
tempestivamente di comunicarcelo e successivamente di cancellare la stessa. 




La informiamo inoltre che in caso di assenza del destinatario, al fine 
di garantire la piena operatività aziendale, i messaggi di posta 
elettronica a questa indirizzo e-mail, verranno gestiti dai colleghi 
aziendali e/o di reparto, nel rispetto delle procedure previste dalle 
istruzioni impartite dal Titolare del Trattamento sull'utilizzo della posta 
elettronica. La preghiamo pertanto di non utilizzare questo indirizzo di 
posta elettronica aziendale per messaggi a carattere privato o che esulano 
dal contesto lavorativo.

-- 
You received this message because you are subscribed to the Google Groups "jOOQ 
User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jooq-user/081e35a6-e3a3-46dc-80b2-b198b582f92dn%40googlegroups.com.
<?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";
    xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-3.4.xsd";>

	<changeSet id="1.0 create-table" author="event-store">
		<comment>Initial schema</comment>
	
		<createTable tableName="events">
			<column name="eventId" type="bigint" autoIncrement="true" incrementBy="1" startWith="1">
				<constraints primaryKey="true" nullable="false" />
			</column>
			<column name="externalId" type="varchar(500)" >
				<constraints nullable="true"/>
			</column>
			<column name="eventType" type="varchar(500)" >
				<constraints nullable="false"/>
			</column>
			<column name="source" type="varchar(500)">
				<constraints nullable="false" />
			</column>
			<column name="content" type="clob">
				<constraints nullable="false" />
			</column>			
			<column name="createdDate" type="datetime">
				<constraints nullable="false" />
			</column>
		</createTable>
		
		<createTable tableName="status">
			<column name="id" type="int">
				<constraints primaryKey="true" nullable="false" />
			</column>
			<column name="code" type="varchar(500)">
				<constraints nullable="false" />
			</column>
			<column name="description" type="varchar(4000)">
				<constraints nullable="false" />
			</column>
		</createTable>
		
		<createTable tableName="consumerEvents">
			<column name="consumerEventId" type="bigint" autoIncrement="true" incrementBy="1" startWith="1">
				<constraints primaryKey="true" nullable="false" />
			</column>
			<column name="eventId" type="bigint">
				<constraints nullable="false" />
			</column>
			<column name="consumer" type="varchar(500)" >
				<constraints nullable="true"/>
			</column>
			<column name="status" type="int" >
				<constraints nullable="false" />
			</column>
			<column name="lastErrorCode" type="varchar(4000)">
				<constraints nullable="true" />
			</column>
			<column name="message" type="clob">
				<constraints nullable="true" />
			</column>		
			<column name="totalAttempts" type="int">
				<constraints nullable="false" />
			</column>		
			<column name="createdDate" type="datetime">
				<constraints nullable="false" />
			</column>
			<column name="lastModifiedDate" type="datetime">
				<constraints nullable="false" />
			</column>
		</createTable>
		
		<createTable tableName="consumerEventsHistory">
			<column name="id" type="bigint" autoIncrement="true" incrementBy="1" startWith="1">
				<constraints primaryKey="true" nullable="false" />
			</column>
			<column name="consumerEventId" type="bigint">
				<constraints nullable="false" />
			</column>
			<column name="status" type="int" >
				<constraints nullable="false"/>
			</column>
			<column name="errorCode" type="varchar(4000)">
				<constraints nullable="true" />
			</column>
			<column name="message" type="clob">
				<constraints nullable="true" />
			</column>				
			<column name="createdDate" type="datetime">
				<constraints nullable="false" />
			</column>
		</createTable>
		
		<createTable tableName="eventType">
			<column name="id" type="bigint" autoIncrement="true" incrementBy="1" startWith="1">
				<constraints primaryKey="true" nullable="false" />
			</column>
			<column name="eventType" type="varchar(500)">
				<constraints nullable="false" />
			</column>
			<column name="createdDate" type="datetime">
				<constraints nullable="false" />
			</column>
			<column name="lastModifiedDate" type="datetime">
				<constraints nullable="false" />
			</column>
		</createTable>
		
		<createTable tableName="sourceConsumer">
			<column name="id" type="bigint" autoIncrement="true" incrementBy="1" startWith="1">
				<constraints primaryKey="true" nullable="false" />
			</column>
			<column name="source" type="varchar(500)">
				<constraints nullable="false" />
			</column>
			<column name="consumer" type="varchar(500)">
				<constraints nullable="false" />
			</column>
			<column name="createdDate" type="datetime">
				<constraints nullable="false" />
			</column>
			<column name="lastModifiedDate" type="datetime">
				<constraints nullable="false" />
			</column>
		</createTable>
		
		<createTable tableName="retention">
			<column name="id" type="bigint" autoIncrement="true" incrementBy="1" startWith="1">
				<constraints primaryKey="true" nullable="false" />
			</column>
			<column name="eventType" type="varchar(500)">
				<constraints nullable="false" />
			</column>
			<column name="status" type="int">
				<constraints nullable="false" />
			</column>
			<column name="retentionDays" type="int">
				<constraints nullable="false" />
			</column>
			<column name="deleteType" type="varchar(50)">
				<constraints nullable="false" />
			</column>
		</createTable>
		
		<addForeignKeyConstraint baseColumnNames="eventId"
	                             baseTableName="consumerEvents"
	                             constraintName="fk_events_consumerevents"
	                             referencedColumnNames="eventId"
	                             referencedTableName="events"/>
	                             
	    <addForeignKeyConstraint baseColumnNames="consumerEventId"
	                             baseTableName="consumerEventsHistory"
	                             constraintName="fk_consumerevents_consumereventshisotry"
	                             referencedColumnNames="consumerEventId"
	                             referencedTableName="consumerEvents"/>
	                            
	    <addForeignKeyConstraint baseColumnNames="status"
	                             baseTableName="consumerEvents"
	                             constraintName="fk_consumerevents_status"
	                             referencedColumnNames="id"
	                             referencedTableName="status"/>
	                             
	    <addForeignKeyConstraint baseColumnNames="status"
	                             baseTableName="retention"
	                             constraintName="fk_retention_status"
	                             referencedColumnNames="id"
	                             referencedTableName="status"/>

	</changeSet>
  
</databaseChangeLog>
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"; xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd";>
	<modelVersion>4.0.0</modelVersion>

	<groupId>f217cf1c-2de4-4d5c-918e-47ffdcb6f684</groupId>
	<artifactId>ths-event-store</artifactId>
	<version>1.0.0</version>
	<packaging>mule-application</packaging>

	<name>ths-event-store</name>

	<properties>
		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
		<project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
		<app.runtime>4.2.0</app.runtime>
		<mule.maven.plugin.version>3.5.1</mule.maven.plugin.version>
		<mule.runtime>api</mule.runtime>
		<jooq.version>3.14.13</jooq.version>
	</properties>

	<build>
		<plugins>
			<plugin>
				<groupId>org.mule.tools.maven</groupId>
				<artifactId>mule-maven-plugin</artifactId>
				<version>${mule.maven.plugin.version}</version>
				<extensions>true</extensions>
				<configuration>
					<sharedLibraries>
						<sharedLibrary>
							<groupId>com.microsoft.sqlserver</groupId>
							<artifactId>mssql-jdbc</artifactId>
						</sharedLibrary>
					</sharedLibraries>
					<sharedLibraries>
						<sharedLibrary>
							<groupId>org.postgresql</groupId>
							<artifactId>postgresql</artifactId>
						</sharedLibrary>
						<sharedLibrary>
							<groupId>org.springframework</groupId>
							<artifactId>spring-beans</artifactId>
						</sharedLibrary>
						<sharedLibrary>
							<groupId>org.springframework</groupId>
							<artifactId>spring-core</artifactId>
						</sharedLibrary>
						<sharedLibrary>
							<groupId>org.springframework.security</groupId>
							<artifactId>spring-security-core</artifactId>
						</sharedLibrary>
						<sharedLibrary>
							<groupId>org.springframework</groupId>
							<artifactId>spring-context</artifactId>
						</sharedLibrary>
						<sharedLibrary>
							<groupId>org.springframework.security</groupId>
							<artifactId>spring-security-config</artifactId>
						</sharedLibrary>
					</sharedLibraries>
					<classifier>mule-application</classifier>
				</configuration>
			</plugin>
			<plugin>
				<groupId>org.jooq.pro-java-8</groupId>
				<artifactId>jooq-codegen-maven</artifactId>
				<version>${jooq.version}</version>
				<executions>
					<execution>
						<id>jooq-generate</id>
						<phase/>
						<!-- per generare le classi jooq eseguite comando: mvn jooq-codegen:generate@jooq-generate -->
						<goals>
							<goal>generate</goal>
						</goals>
					</execution>
				</executions>
				<configuration>
					<generator>
						<database>
							<name>org.jooq.meta.extensions.liquibase.LiquibaseDatabase</name>
							<properties>

								<property>
									<key>scripts</key>
									<value>src/main/resources/liquibase/changelog-master.xml</value>
								</property>
								<property>
									<key>includeLiquibaseTables</key>
									<value>false</value>
								</property>
								<property>
									<key>database.liquibaseSchemaName</key>
									<value>public</value>
								</property>
								<property>
									<key>changeLogParameters.contexts</key>
									<value>!test</value>
								</property>
							</properties>
<!-- 							<includeForeignKeys>false</includeForeignKeys> -->
						</database>
						<generate>
							<deprecated>false</deprecated>
							<instanceFields>true</instanceFields>
							<pojos>false</pojos>
							<validationAnnotations>true</validationAnnotations>
							<fluentSetters>true</fluentSetters>
							<javaTimeTypes>true</javaTimeTypes>
<!-- 							<records>false</records> -->
<!-- 							<globalSchemaReferences>false</globalSchemaReferences> -->
<!-- 							<globalCatalogReferences>false</globalCatalogReferences> -->
						</generate>
						<target>
							<packageName>com.ths.eventstore.utils.jooq.generated</packageName>
							<directory>src/main/generated</directory>
						</target>
	<strategy>					
<matchers>
        <schemas>
          <schema>
            <schemaClass>

              <transform>AS_IS</transform>
            
              <!-- The mandatory expression element lets you specify a replacement expression to be used when
                   replacing the matcher's regular expression. You can use indexed variables $0, $1, $2. -->
              <expression>$0</expression>
            </schemaClass>
          </schema>
        </schemas>
      </matchers>
</strategy>
					</generator>
				</configuration>
				<dependencies>
					<dependency>
						<groupId>org.jooq.pro-java-8</groupId>
						<artifactId>jooq-meta-extensions-liquibase</artifactId>
						<version>${jooq.version}</version>
					</dependency>
				</dependencies>
			</plugin>
			<!--compile generated files-->
			<plugin>
				<groupId>org.codehaus.mojo</groupId>
				<artifactId>build-helper-maven-plugin</artifactId>
				<version>3.0.0</version>
				<executions>
					<execution>
						<id>add-source</id>
						<phase>generate-sources</phase>
						<goals>
							<goal>add-source</goal>
						</goals>
						<configuration>
							<sources>
								<source>src/main/generated</source>
							</sources>
						</configuration>
					</execution>
				</executions>
			</plugin>
		</plugins>
	</build>

	<dependencies>
		<dependency>
			<groupId>org.mule.modules</groupId>
			<artifactId>mule-apikit-module</artifactId>
			<version>1.5.3</version>
			<classifier>mule-plugin</classifier>
		</dependency>
		<dependency>
			<groupId>org.mule.connectors</groupId>
			<artifactId>mule-http-connector</artifactId>
			<version>1.5.25</version>
			<classifier>mule-plugin</classifier>
		</dependency>
		<dependency>
			<groupId>org.mule.modules</groupId>
			<artifactId>mule-validation-module</artifactId>
			<version>1.4.5</version>
			<classifier>mule-plugin</classifier>
		</dependency>
		<dependency>
			<groupId>com.mulesoft.modules</groupId>
			<artifactId>mule-secure-configuration-property-module</artifactId>
			<version>1.2.3</version>
			<classifier>mule-plugin</classifier>
		</dependency>
		<dependency>
			<groupId>f217cf1c-2de4-4d5c-918e-47ffdcb6f684</groupId>
			<artifactId>event-store-api</artifactId>
			<version>1.0.1</version>
			<classifier>raml</classifier>
			<type>zip</type>
		</dependency>
		<dependency>
			<groupId>org.liquibase</groupId>
			<artifactId>liquibase-core</artifactId>
			<version>4.2.2</version>
		</dependency>
		<dependency>
			<groupId>org.postgresql</groupId>
			<artifactId>postgresql</artifactId>
			<version>42.2.23</version>
		</dependency>
		<dependency>
			<groupId>com.oracle.database.jdbc</groupId>
			<artifactId>ojdbc10</artifactId>
			<version>19.9.0.0</version>
		</dependency>
		<dependency>
			<groupId>com.oracle.database.jdbc</groupId>
			<artifactId>ojdbc6</artifactId>
			<version>11.2.0.4</version>
		</dependency>
		<dependency>
			<groupId>com.oracle.database.jdbc</groupId>
			<artifactId>ojdbc8</artifactId>
			<version>19.9.0.0</version>
		</dependency>
		<dependency>
			<groupId>mysql</groupId>
			<artifactId>mysql-connector-java</artifactId>
			<version>8.0.22</version>
		</dependency>
		<dependency>
			<groupId>com.microsoft.sqlserver</groupId>
			<artifactId>mssql-jdbc</artifactId>
			<version>9.1.1.jre8-preview</version>
		</dependency>
		<dependency>
			<groupId>org.jooq.pro-java-8</groupId>
			<artifactId>jooq-meta-extensions</artifactId>
			<version>${jooq.version}</version>
		</dependency>
		<dependency>
			<groupId>javax.validation</groupId>
			<artifactId>validation-api</artifactId>
			<version>2.0.1.Final</version>
		</dependency>
		<dependency>
			<groupId>javax.annotation</groupId>
			<artifactId>javax.annotation-api</artifactId>
			<version>1.3.2</version>
		</dependency>
		<dependency>
			<groupId>org.mule.connectors</groupId>
			<artifactId>mule-db-connector</artifactId>
			<version>1.10.0</version>
			<classifier>mule-plugin</classifier>
		</dependency>
		<dependency>
			<groupId>org.mule.modules</groupId>
			<artifactId>mule-spring-module</artifactId>
			<version>1.3.6</version>
			<classifier>mule-plugin</classifier>
		</dependency>
		<dependency>
			<groupId>org.springframework</groupId>
			<artifactId>spring-beans</artifactId>
			<version>5.3.2</version>
		</dependency>
		<dependency>
			<groupId>org.springframework</groupId>
			<artifactId>spring-core</artifactId>
			<version>5.3.2</version>
		</dependency>
		<dependency>
			<groupId>org.springframework.security</groupId>
			<artifactId>spring-security-core</artifactId>
			<version>5.4.2</version>
		</dependency>
		<dependency>
			<groupId>org.springframework</groupId>
			<artifactId>spring-context</artifactId>
			<version>5.3.2</version>
		</dependency>
		<dependency>
			<groupId>org.springframework.security</groupId>
			<artifactId>spring-security-config</artifactId>
			<version>5.4.2</version>
		</dependency>
		
	</dependencies>

	<repositories>
		<repository>
			<id>anypoint-exchange-v2</id>
			<name>Anypoint Exchange V2</name>
			<url>https://maven.anypoint.mulesoft.com/api/v2/maven</url>
			<layout>default</layout>
		</repository>
		<repository>
			<id>anypoint-exchange</id>
			<name>Anypoint Exchange</name>
			<url>https://maven.anypoint.mulesoft.com/api/v1/maven</url>
			<layout>default</layout>
		</repository>
		<repository>
			<id>mulesoft-releases</id>
			<name>MuleSoft Releases Repository</name>
			<url>https://repository.mulesoft.org/releases/</url>
			<layout>default</layout>
		</repository>
	</repositories>
	<pluginRepositories>
		<pluginRepository>
			<id>mulesoft-releases</id>
			<name>mulesoft release repository</name>
			<layout>default</layout>
			<url>https://repository.mulesoft.org/releases/</url>
			<snapshots>
				<enabled>false</enabled>
			</snapshots>
		</pluginRepository>
	</pluginRepositories>

</project>
/*
 * This file is generated by jOOQ.
 */
package com.ths.eventstore.utils.jooq.generated.tables;


import com.ths.eventstore.utils.jooq.generated.DefaultSchema;
import com.ths.eventstore.utils.jooq.generated.Keys;
import com.ths.eventstore.utils.jooq.generated.tables.records.EventsRecord;

import java.time.LocalDateTime;
import java.util.Arrays;
import java.util.List;

import org.jooq.Field;
import org.jooq.ForeignKey;
import org.jooq.Identity;
import org.jooq.Name;
import org.jooq.Record;
import org.jooq.Row6;
import org.jooq.Schema;
import org.jooq.Table;
import org.jooq.TableField;
import org.jooq.TableOptions;
import org.jooq.UniqueKey;
import org.jooq.impl.DSL;
import org.jooq.impl.SQLDataType;
import org.jooq.impl.TableImpl;


/**
 * This class is generated by jOOQ.
 */
@SuppressWarnings({ "all", "unchecked", "rawtypes" })
public class Events extends TableImpl<EventsRecord> {

    private static final long serialVersionUID = 1L;

    /**
     * The reference instance of <code>EVENTS</code>
     */
    public static final Events EVENTS = new Events();

    /**
     * The class holding records for this type
     */
    @Override
    public Class<EventsRecord> getRecordType() {
        return EventsRecord.class;
    }

    /**
     * The column <code>EVENTS.EVENTID</code>.
     */
    public final TableField<EventsRecord, Long> EVENTID = createField(DSL.name("EVENTID"), SQLDataType.BIGINT.nullable(false).identity(true), this, "");

    /**
     * The column <code>EVENTS.EXTERNALID</code>.
     */
    public final TableField<EventsRecord, String> EXTERNALID = createField(DSL.name("EXTERNALID"), SQLDataType.VARCHAR(500), this, "");

    /**
     * The column <code>EVENTS.EVENTTYPE</code>.
     */
    public final TableField<EventsRecord, String> EVENTTYPE = createField(DSL.name("EVENTTYPE"), SQLDataType.VARCHAR(500).nullable(false), this, "");

    /**
     * The column <code>EVENTS.SOURCE</code>.
     */
    public final TableField<EventsRecord, String> SOURCE = createField(DSL.name("SOURCE"), SQLDataType.VARCHAR(500).nullable(false), this, "");

    /**
     * The column <code>EVENTS.CONTENT</code>.
     */
    public final TableField<EventsRecord, String> CONTENT = createField(DSL.name("CONTENT"), SQLDataType.CLOB.nullable(false), this, "");

    /**
     * The column <code>EVENTS.CREATEDDATE</code>.
     */
    public final TableField<EventsRecord, LocalDateTime> CREATEDDATE = createField(DSL.name("CREATEDDATE"), SQLDataType.LOCALDATETIME(6).nullable(false), this, "");

    private Events(Name alias, Table<EventsRecord> aliased) {
        this(alias, aliased, null);
    }

    private Events(Name alias, Table<EventsRecord> aliased, Field<?>[] parameters) {
        super(alias, null, aliased, parameters, DSL.comment(""), TableOptions.table());
    }

    /**
     * Create an aliased <code>EVENTS</code> table reference
     */
    public Events(String alias) {
        this(DSL.name(alias), EVENTS);
    }

    /**
     * Create an aliased <code>EVENTS</code> table reference
     */
    public Events(Name alias) {
        this(alias, EVENTS);
    }

    /**
     * Create a <code>EVENTS</code> table reference
     */
    public Events() {
        this(DSL.name("EVENTS"), null);
    }

    public <O extends Record> Events(Table<O> child, ForeignKey<O, EventsRecord> key) {
        super(child, key, EVENTS);
    }

    @Override
    public Schema getSchema() {
        return DefaultSchema.DEFAULT_SCHEMA;
    }

    @Override
    public Identity<EventsRecord, Long> getIdentity() {
        return (Identity<EventsRecord, Long>) super.getIdentity();
    }

    @Override
    public UniqueKey<EventsRecord> getPrimaryKey() {
        return Keys.PK_EVENTS;
    }

    @Override
    public List<UniqueKey<EventsRecord>> getKeys() {
        return Arrays.<UniqueKey<EventsRecord>>asList(Keys.PK_EVENTS);
    }

    @Override
    public Events as(String alias) {
        return new Events(DSL.name(alias), this);
    }

    @Override
    public Events as(Name alias) {
        return new Events(alias, this);
    }

    /**
     * Rename this table
     */
    @Override
    public Events rename(String name) {
        return new Events(DSL.name(name), null);
    }

    /**
     * Rename this table
     */
    @Override
    public Events rename(Name name) {
        return new Events(name, null);
    }

    // -------------------------------------------------------------------------
    // Row6 type methods
    // -------------------------------------------------------------------------

    @Override
    public Row6<Long, String, String, String, String, LocalDateTime> fieldsRow() {
        return (Row6) super.fieldsRow();
    }
}

Reply via email to