Jump to content
Changes to the Jaspersoft community edition download ×

Pass database url as parameter at run time


didier.lebon

Recommended Posts

I have 2  similar oracle databases in 2 different pdbs using the same reports.

Is it possible to pass the database url as parameter to jasperserver at runtime?

The idea is to use one instance of jasperserver to run the reports from 2 database sources.

Example URL sent to jasperserver :   MyOracleServer.com:8080/jasperserver/flow.html?_flowId=viewReportFlow&database_url=jdbc:oracle:thin:@MyOracleServer.com:1521/pdb1.MyServiceName.com&report=MyReport...

                                                             MyOracleServer.com:8080/jasperserver/flow.html?_flowId=viewReportFlow&database_url=jdbc:oracle:thin:@MyOracleServer.com:1521/pdb2.MyServiceName.com&report=MyReport...

Link to comment
Share on other sites

  • Replies 1
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

If you have Pro version then most probably you can do following trick:
create 2 datasources, then combine them in 1 with Virtual Datasource,define different aliases, build your report with parametrized schema name, when running report - switch schema.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...