This week's book giveaway is in the OCAJP forum. We're giving away four copies of OCA Java SE 8 Programmer I Study Guide 1Z0-808 and have Jeanne Boyarsky & Scott Selikoff on-line! See this thread for details.
Why are you doing this:
Shouldn't be Iterator<Data> it = b.iterator?
What's b? Is not defined anywhere.
Why do you use the iterator for a list? why not to use just a for(Data myData: request.getAttribute("b"))?
And the most important question... why to use Java code in a JSP where you can use JSTL and EL and forget about iterators, casting, etc...?
hey guys thanks a lot for your suggestions..it seems that i need to learn a lot still..and i dont know JSTL...
I have changed my code a bit...this is my servlet called Simple.java
and in JSP i have made changes ....i am getting the values of the table but all 4 rows are having same value of the last row.....
How will I get all the values of all the rows..
my jsp Reading.jsp is as follows..it just displays the last row of my database table..I want all 4 rows ..it is displaying same values of the last row in all four rows of my table........