fea jabi wrote:
> can anyone help me understand this? 
Don't know.
>> I am creating instances of this Object and making a List which is
>> getting displayed in the JSP.
>>
>> I was told that instead of creating Object and creating instances,
>> one can directly use the result set got from the DB and iterate thru
>> it to fill the tables.
>>
>> Which one is more efficient way to do? Is the second approach better?
>> if so why?
Efficiency-wise? Depends on where you want your efficiency. You can use
a ResultSet directly, but you must keep the statement (and connection?)
open while using it, which might lead to number-of-connection issues.

In general, I have pretty strong feelings against using "raw" ResultSets
despite the overhead of copying data... anything other than raw JDBC
will see the same behavior whether it's a full ORM or something as
simple as a RowSetDynaClass (from Jakarta BeanUtils).

Of course, I have no idea how you're currently interacting with the DB,
so it's hard to say.

Dave



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

Reply via email to