Solved

Report in SWING

Posted on 2007-03-25
11
325 Views
Last Modified: 2010-03-31
Hello,

I am developing SWING app using jdk 1.4.2 and HSQLDB.

Well, it works fine now. However, in near future, the data in HSQLDB may grow up to 1 million records or even more.  I am afraid that this may slow down or even *crash* the application in the future as I have one report feature where it displays out the data from one table in DB. This table is the table that contains more than 1 million records.

Now, I am thinking to use JFreeReport to display the report.

What would you think or suggestion?

Thanks
David
0
Comment
Question by:suprapto45
  • 6
  • 5
11 Comments
 
LVL 16

Author Comment

by:suprapto45
ID: 18790647
I will have a look at this thread later on.

David
0
 
LVL 30

Expert Comment

by:mayankeagle
ID: 18790726
Yes, I guess you should move on to JFreeChart. I thought you werre already using it
0
 
LVL 16

Author Comment

by:suprapto45
ID: 18790750
>>"Yes, I guess you should move on to JFreeChart. I thought you werre already using it"
Do you mean JFreeReport?

I am about to implement the JFreeReport. However, as far as I know, using JFreeReport, you need to populate the TableModel first then pass it to the report. Has JFreeReport been able to handle huge data as 1 million records? If so, what should I do to minimize the impact of the memory exhaustion of my application?

Or do you have any other alternatives instead of querying the DB for the entire 1 million records?

Thanks
David
0
 
LVL 30

Expert Comment

by:mayankeagle
ID: 18790765
Sorry, yes I meant JFreeReport.

>> Has JFreeReport been able to handle huge data as 1 million records?

Will check and let you know. are you thinking of implementing pagination?
0
 
LVL 16

Author Comment

by:suprapto45
ID: 18790972
>>"Will check and let you know. are you thinking of implementing pagination?"
If in J2EE yes. That's why I am confused in J2SE. What do you people normally do to handle this kind of situation in J2SE? Do you use pagination or any other thing? I may not have known few technologies in J2SE as I always deal with J2EE.

This is my first project in SWING :).

David
0
6 Surprising Benefits of Threat Intelligence

All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

 
LVL 30

Accepted Solution

by:
mayankeagle earned 500 total points
ID: 18793643
I personally use a JTable and add a Next/ Previous button. Upon hitting of the next button, hit the DB again and retrieve the information, update the model. Your UI/ app could crash if you retrieve millions of record in the memory in 1 shot. Though when it comes to UI, I work on the EE side more than J2SE too.
0
 
LVL 30

Assisted Solution

by:mayankeagle
mayankeagle earned 500 total points
ID: 18793661
0
 
LVL 16

Author Comment

by:suprapto45
ID: 18797701
Thanks mayank,

I'll have a look at it later.

David
0
 
LVL 30

Expert Comment

by:mayankeagle
ID: 18802312
You needn't accept before trying....
0
 
LVL 16

Author Comment

by:suprapto45
ID: 18805514
mayankeagle,

Sorry for any delay in replying.

Well, at this point of time, I really have not 100% sure to go ahead with any solution. I am still thinking the best way on this if it happens in the future. So any link / feedback would extremely be useful for me as I am still considering all the factors. Hence your suggestion and feedback are valid to be accepted.

Thanks again.
David
0
 
LVL 30

Expert Comment

by:mayankeagle
ID: 18805725
Ok, thanks.
0

Featured Post

Top 6 Sources for Identifying Threat Actor TTPs

Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

Join & Write a Comment

Suggested Solutions

An old method to applying the Singleton pattern in your Java code is to check if a static instance, defined in the same class that needs to be instantiated once and only once, is null and then create a new instance; otherwise, the pre-existing insta…
For beginner Java programmers or at least those new to the Eclipse IDE, the following tutorial will show some (four) ways in which you can import your Java projects to your Eclipse workbench. Introduction While learning Java can be done with…
This tutorial covers a step-by-step guide to install VisualVM launcher in eclipse.
Viewers will learn how to properly install Eclipse with the necessary JDK, and will take a look at an introductory Java program. Download Eclipse installation zip file: Extract files from zip file: Download and install JDK 8: Open Eclipse and …

708 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now