Thanks Mark
Your suggestion worked.
I did not use the
teacherForm.set("teachers", teacherList);?
It looks like this is accomplished without using
DynaAction Form and using JSTL in my jsp page.
Barry
- Original Message -
From: "Mark Lowe" <[EMAIL PROTEC
That's just what RowSetDynaClass and the implementation of the Result interface
in JSTL do (use ResultSetMetaData to grab column names).
Quoting Mark Lowe <[EMAIL PROTECTED]>:
> It works alright but last time i played with these beanutil's toys it
> was understandably slow. A little less slower
It works alright but last time i played with these beanutil's toys it
was understandably slow. A little less slower is getting the
resultsetmetadata and using them as your property names.
IMO its better to make some beans and populate them with the result set
values, until you've time to put a
Per the JavaDoc for RowSetDynaClass:
import org.apache.commons.beanutils.RowSetDynaClass;
...
Connection conn = ...; // Acquire connection from pool
Statement stmt = conn.createStatement();
ResultSet rs = stmt.executeQuery("SELECT ...");
RowSetDynaClass rsdc = new RowSetDynaClass(rs);
rs.close();
while(rs.next()) {
Map teacher = new HashMap();
teacher.put("firstName",rs.getString("firstName"));
teacherList.add(teacher);
}
teacherForm.set("teachers", teacherList);
request.setAttribute ("teachers", teacherList.toArray());
Cheers Mark
On Monday, November 3, 2003, at
PM
To: Struts Users Mailing List
Subject: DynaAction form and ArrayList
Only Last row is available in my ArrayList?
Have the following:
ArrayList teachers = new ArrayList();
DynaActionForm teacherForm = (DynaActionForm)form;
while ( rs.next() ) {
System.out.println("firstname.rs
Only Last row is available in my ArrayList?
Have the following:
ArrayList teachers = new ArrayList();
DynaActionForm teacherForm = (DynaActionForm)form;
while ( rs.next() ) {
System.out.println("firstname.rs: " + rs.getString("firstname"));
System.out.println("lastname.rs: " + rs.getString
Hi all,
I have a java value object (i.e. MyVo) which i add the DynaAction Form
Below. When i display my jsp it works fine using headerVO.firstName but when
i submit the page to save user changes i get the following error:
java.lang.IllegalArgumentException: No bean specified
at
nday, June 24, 2002 6:10 PM
> To: [EMAIL PROTECTED]
> Subject: DynaAction form - can I use a boolean primitive
>
>
> Subject: DynaAction form - can I use a boolean primitive
> From: "Matt Raible" <[EMAIL PROTECTED]>
> ===
> When defini
Subject: DynaAction form - can I use a boolean primitive
From: "Matt Raible" <[EMAIL PROTECTED]>
===
When defining my DynaActionForm in struts-config.xml, is this possible:
--
To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]>
For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
10 matches
Mail list logo