WONDERFUL Lukas, Your are the greatest !!
I have been using settings and that works well for my case. In case this helps someone else I am documenting what I did.
I have many identical database schemas created using settings in the below helper method
public static Settings getSettings( String specificDatabase ) {
String schemaInput = "dashboard2";
Settings settings = new Settings()
.withRenderMapping(new RenderMapping()
.withSchemata(
new MappedSchema().withInput(schemaInput)
.withOutput(specificDatabase)
)
);
return settings;
}
Based on your help the following retrieves the specific database being used
public static String getDatabaseNameFromDsl(DSLContext dsl) {
Settings settings = dsl.settings();
return settings.getRenderMapping().getSchemata().get(0).getOutput();
}
Thanks again,
Jim