How to specify charset encoding on liquibase


I am trying to load a data file using liquibase. This file contains data with special characters like ‘ñ’ , ‘ü’, etc.

The loading is done without errors, but when i explore the tables, data is incorrectly stored, the special characters have been modified.

Is there any way to specify the charset encoding on liquibase?

I’ve tried to use the -Dfile.encoding=“ISO-8859-1” , but it doesn’t work.

java -Dfile.encoding=“ISO-8859-1” -cp “%CP%” %JAVA_OPTS% liquibase.integration.commandline.Main %CMD_LINE_ARGS%

My specs:

  • Liquibase 2.0.3

  • Oracle Database 10g Enterprise Edition Release - Prod

  • Character set WE8ISO8859P1

Too bad there is no answer to this question. 

I am having the same problem when trying to load formatted sql files which are encoded in UTF-8. 

I am using Liquibase 2.0.5

Nevermind. Found a way to do it. 

Just add: Then it works.