Jump to content
Changes to the Jaspersoft community edition download ×

how to assign one datasource for many tables


Recommended Posts

By: dandotkar shashikanth - dshashikanth

how to assign one datasource for many tables

2003-10-19 09:33

i have a prob in assigning one datasource object with many tables...

 

i have smth to build like this:

 

------------------------------

.............report

------------------------------

-------------

......tab-1

-------------

........|.....................pie chart

........|.........

-------------

....................

....................

------------- .....--------------

.....tab-2..................tab-3

------------- ..... --------------

......|..........................|

......|..........................|

-------------...... --------------

--------------------------------

i thought of doing this without subreport concept.

but i thnk its not possible. and my data for these tables comes frm memory as inputstream.

i have only datasource object which shud get data

from memory and shud assign to all these tables.

and if possible to piechart also...

but for timebeing iam assigning the data for

pie chart in scriptlet object in beforeReportInit() mthod.

if u have some idea to solve this problem..

please share with me.

 

 

 

 

 

 

By: Jaya - jayajoseph

RE: how to assign one datasource for many tables

2003-10-21 03:02

Hi,

I have a query regarding multiple tables and piecharts in a report.

I have to create a report such that it contains mutiple tables and each table containing a summary containing a chart.

I created 2 subreports each containg a table and a chart in the summary but when i try using the subreport from the masterreport. I am able to view only the first subreport. Also since I am sure of the number of rows in the table how do i specify the height in the masterreport XML.

It would be great if you can help me in some way.

 

Regards

Jaya

 

 

 

 

 

By: dandotkar shashikanth - dshashikanth

RE: how to assign one datasource for many tables

2003-10-23 16:24

hi jaya!

let me know ..r u successfull in retrieving the data from the datasource?

if it is just design problem..then iam sure u can manage...

see just try to manage the height value of two subreports ...the sum of all hieghts in master report, and two subreport shud not exceed the total height of page in main report.

and same for width too...

be carefull in giveing the values of x and y.

if u give the same values in both the reoirts they override..each other..

 

in report:

 

------x value----- pixel position

.

.

.

y value ...pixel position

.

.

 

height is the scalar value...just magnitude ..

so carefull in giving these values...

if smth is wrong in giving proper values u cannot view the report..even its created...

 

but check whether ur able to retrieve the data from the DataSource

sorry for late reply..

if u have further queries please email to this id:

dshashikanth@rediffmail.com

cheers

shashi

 

 

 

 

 

By: Jaya - jayajoseph

RE: how to assign one datasource for many tables

2003-10-28 02:47

Hi Shashikanth

I have to generate a report that looks something like this:

 

Page Header......

PieChart1......

Table1....

PieChart2....

Table2....

Table3....

 

The number of tables and PieChart is dynamic, I don't know how many I need to create, also the data for table1 and Piechart1 comes from the same table in the database, however that for table2 n piechart2 comes from another table in the database.

I cannot pass the connection object to the XML as I need to do some calculations before sending the parameters.

How can I generate the XML such that it generates this report with as many number of tables and piecharts as required dynamically?Secondly, how can i access the data in the XML after doing some manipulation on the data obtained from the database? Thirdly, how can the data for all the tables be accessed as I have a number of different tables!!

It would help if u can give an example and explain the same.

 

Regards

Jaya

Link to comment
Share on other sites

  • Replies 0
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

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...