• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Error while parsing and storing xml data in database using jsp jstl tags

 
Shailesh Kumar Saxena
Greenhorn
Posts: 25
Hibernate Java Spring
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have to read an xml file, display its content in the form of a table and need to store the data in database table.
Firstly I tried to only display the data using jstl1.2 tags in my jsp. It is working fine. But when I tried to implement
some code to insert the records I am getting this error..



My Jsp code is as:


Please provide your suggestion which tag shall I use to set the values to insert query parameters? How to get the xml elements data to set in query parameters?
Thanks & Regards
 
Shailesh Kumar Saxena
Greenhorn
Posts: 25
Hibernate Java Spring
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I tried hard to get the solution of my problem but unfortunately couldn't get any help.
While googling I got some basic idea to cope with this. I tried this



But I got this error:



As in my table balance(last column) is integer type. When I googled I got that jstl tags automatically take care of casting.
But it is showing error as by default <c:set > tag places value for variable as string.
Any idea? Any help? Any suggestion? Please let me know.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic