Re: Data driven struts application

2003-03-14 Thread Robert McIntosh
Using a ResultSet directly is generally seen as bad practice. At a minimum you should probably use the ResultSetDynaClass then next in line would be a RowSetDynaClass, then JavaBeans. As for the JavaBean properties question, it would be easier to return a Collection of JavaBeans where each

Re: Data driven struts application

2003-03-14 Thread David Graham
Both solution 1 and 2 are far better than using a ResultSet in a jsp. I usually use a Collection of JavaBeans. David From: Guido [EMAIL PROTECTED] Reply-To: Struts Users Mailing List [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Subject: Data driven struts application

Re: Data driven struts application

2003-03-14 Thread Pat Quinn
From: Robert McIntosh [EMAIL PROTECTED] Reply-To: Struts Users Mailing List [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Subject: Re: Data driven struts application Date: Fri, 14 Mar 2003 09:38:50 -0600 Using a ResultSet directly is generally seen as bad practice

Re: Data driven struts application

2003-03-14 Thread Robert S. Sfeir
Yep, I agree with David. Your code will invariably be more usable and be more presentation layer friendly if you always return a Collection of some type. The Collection would contain beans of the object type you're working with. Further if you're using for example an ArrayList to populate a

Re: Data driven struts application

2003-03-14 Thread Craig R. McClanahan
On Fri, 14 Mar 2003, Robert McIntosh wrote: Date: Fri, 14 Mar 2003 09:38:50 -0600 From: Robert McIntosh [EMAIL PROTECTED] Reply-To: Struts Users Mailing List [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Subject: Re: Data driven struts application Using a ResultSet

Re: Data driven struts application

2003-03-14 Thread Guido
I agree, but I am in doubt: 1. How to transform a ResultSet into a JavaBean (I think bean accesors don't have to be named as database columns...) without reinvent the wheel? 2. If I don't know how many columns the query returns (i.e. if the query is 'select * from ORACLE_VIEW') I supose I can

Re: Data driven struts application

2003-03-14 Thread Craig R. McClanahan
On Fri, 14 Mar 2003, Pat Quinn wrote: Date: Fri, 14 Mar 2003 16:05:34 + From: Pat Quinn [EMAIL PROTECTED] Reply-To: Struts Users Mailing List [EMAIL PROTECTED] To: [EMAIL PROTECTED] Subject: Re: Data driven struts application I spent some time thinking over this very topic. I finally

Re: Data driven struts application

2003-03-14 Thread Pat Quinn
List [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Subject: Re: Data driven struts application Date: Fri, 14 Mar 2003 08:24:58 -0800 (PST) On Fri, 14 Mar 2003, Pat Quinn wrote: Date: Fri, 14 Mar 2003 16:05:34 + From: Pat Quinn [EMAIL PROTECTED] Reply-To: Struts Users

Re: Data driven struts application

2003-03-14 Thread Phil Steitz
I apologize if this has already been beaten to death, but I am still struggling with the implications of dyna-stuff on traditional OOD in struts applications. See interspersed. Craig R. McClanahan wrote: This is pretty much what RowSetDynaClass does for you, without the need to create

RE: Data driven struts application

2003-03-14 Thread Paul Pattison
:16 To: Struts Users Mailing List Subject: Re: Data driven struts application On Fri, 14 Mar 2003, Robert McIntosh wrote: Date: Fri, 14 Mar 2003 09:38:50 -0600 From: Robert McIntosh [EMAIL PROTECTED] Reply-To: Struts Users Mailing List [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL

Re: Data driven struts application

2003-03-14 Thread Vic Cekvenich
I agree with those that say Dynabeans are not a good practice. It's hard to unit test, or reuse, for example in JSTL or Model 1. It has a CVS hot spot. etc. etc. Best stick with unit tested POJO (and a bean that has a DAO helper, as in my other posts). .V Phil Steitz wrote: I apologize if this

Re: Data driven struts application

2003-03-14 Thread Craig R. McClanahan
On Fri, 14 Mar 2003, Phil Steitz wrote: Date: Fri, 14 Mar 2003 10:17:59 -0700 From: Phil Steitz [EMAIL PROTECTED] Reply-To: Struts Users Mailing List [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Subject: Re: Data driven struts application I apologize if this has

RE: Data driven struts application

2003-03-14 Thread Craig R. McClanahan
On Fri, 14 Mar 2003, Paul Pattison wrote: Date: Fri, 14 Mar 2003 12:28:04 -0500 From: Paul Pattison [EMAIL PROTECTED] Reply-To: Struts Users Mailing List [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Subject: RE: Data driven struts application An approach that I've

Re: Data driven struts application

2003-03-14 Thread Phil Steitz
Thanks, Craig. I understand a lot better now, but I am still struggling a bit. What you seem to be saying is that for read-only access we can safely skip the value/business object encapsulation; but for updates, we should use real BOs. This asymmetry troubles me; though I see the appeal in

Re: Data driven struts application

2003-03-14 Thread Craig R. McClanahan
On Fri, 14 Mar 2003, Phil Steitz wrote: Date: Fri, 14 Mar 2003 14:17:38 -0700 From: Phil Steitz [EMAIL PROTECTED] Reply-To: Struts Users Mailing List [EMAIL PROTECTED] To: Struts Users Mailing List [EMAIL PROTECTED] Subject: Re: Data driven struts application Thanks, Craig. I