(my post got lost) bellow:

Luiz-Otavio Zorzella wrote:
Craig R. McClanahan wrote:
Sundar Narasimhan wrote:

I agree that this approach works well for "small" result
sets. However, if there are say 10k rows.. it would be nice to have
such a class work together with a Pager tag set.. any thoughts re. that?

Sounds like a good problem that needs to be solved in a general way.
Best way to get it addressed might be to put in an enhancement request
against BeanUtils to add row index limits on the rows that are returned by
the list.

http://nagoya.apache.org/bugzilla/

I have another idea for dealing with paging, in the lines of ResultSetDynaClass... From an earlier email:

********************

I want, like in the a ResultSetDynaClass, a structure that does not copy the elements, from which I can get an Iterator. Now, once I "getNext()" from the Iterator, I want to get a copy of the object, so that I can later use it, even after exhauting the ResultSet. This is a "kind of" a lazy loading. BTW, the "advance ()" method is what I would use if I want to advance, but not have the copy generated...

Maybe I could create a constructor for ResultSetDynaClass/ResultSetIterator that receives a boolean that specifies if I want copies of elements rather than references...

*********************

Zorzella

1. Closing the RowSet is the traditioanl aproach, even in ODBC, Client-Server or even in C API Client Side DB, very few drivers support streaming rows.

2. Most apps have hundreds of users, not many need thousands of concurent users per CPU; but with above aproach several thosuand per CPU on app. server works fine with sub second response time at least for my clients.

3. If you do go down the road (and best to pick up this thread in Commons as mentioned) than http://gee.cs.oswego.edu/dl/classes/collections/ are nice threaded collections (part of JDK1.5 now). But be very carefull when creating own threads on the app. server.

4. http://www.postgresql.org/docs/view.php?version=7.3&idoc=0&file=sql-select.html
one way is to pass the offset above to the RowSet via getParameter. This works with large resultsets.

5. Consider using RowSetDynaClass instead of ResultSetDynaClass...... acctualy I allways use RowSet* never ResulstSet*. Copying is optional with RowSet.
Here are drivers that do RowSet (click rowset)
http://industry.java.sun.com/products/jdbc/drivers


6. This sounds more of something Hibreanate should do and not Struts.
And everyone knows my fave aproach is:
http://developer.java.sun.com/developer/technicalArticles/javaserverpages/cachedrowset
Simple and fast (combined with offset on Select)

hth

.V



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to