Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » BIRT » [HELP] Two data sources.(How to select data sources.)
icon3.gif  [HELP] Two data sources. [message #891673] Mon, 25 June 2012 13:16 Go to next message
Emiliano Gonzalez is currently offline Emiliano GonzalezFriend
Messages: 3
Registered: May 2012
Junior Member
For example, I created two data sources in the report, as I can select which data source to use based on a parameter received?.

I have two identical database with different information and different location, and I want to use the same report to both database where the report chooses where to get the data.

Thanks!
Re: [HELP] Two data sources. [message #891768 is a reply to message #891673] Mon, 25 June 2012 20:18 Go to previous message
Jason Weathersby is currently offline Jason WeathersbyFriend
Messages: 9167
Registered: July 2009
Senior Member

You have a bunch of different options here. You could use connection
porfiles, script to change the db url at runtime or swap datasourece or
datasets using scirpt. I am attaching two examples that swap the
datasource or dataset based on a parameter. If you want an example of
change the db url, you can do this in the beforeOpen of a data source like:

extensionProperties.odaURL = "jdbc:mysql://localhost/"+params["mydb"].value;

Jason


On 6/25/2012 9:16 AM, Emiliano Gonzalez wrote:
> For example, I created two data sources in the report, as I can select
> which data source to use based on a parameter received?.
>
> I have two identical database with different information and different
> location, and I want to use the same report to both database where the
> report chooses where to get the data.
>
> Thanks!
Previous Topic:Security access
Next Topic:Suppress Message "The resource of this report item is not reachable"
Goto Forum:
  


Current Time: Thu Apr 18 23:29:22 GMT 2024

Powered by FUDForum. Page generated in 0.01891 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top