assertj-db
assertj-db copied to clipboard
Unable to detect changes not default schema
I am using Oracle DB for testing. Also, the application user and the schema management user are different.
Watching at changes.changesList in the code below, it's null.
OracleDataSource ods = new OracleDataSource();
ods.setURL(...);
ods.setUser(...);
ods.setPassword(...);
Changes changes = new Changes(ods);
changes.setStartPointNow();
makeChangesInTheData();
changes.setEndPointNow();
Changes targets the default schema for change detection, can it target another schema?
Hi @jitsuishi Indeed assertj-db know have currently the capability to select schema and the Oracle JDBC driver either. I think you can use Hikari as workaround.
You can try this :
HikariDataSource hikariDs = new HikariDataSource(); hikariDs.setDataSource(ods); hikariDs.setConnectionInitSql("ALTER SESSION SET CURRENT_SCHEMA = SOME_SCHEMA");
Julien.