Best way to get a Web Service to return a database result as XML?

Posted by John on Stack Overflow See other posts from Stack Overflow or by John
Published on 2010-06-07T16:27:18Z Indexed on 2010/06/07 18:12 UTC
Read the original article Hit count: 252

I am building a webservice using jax-rs and querying a DB2 z/OS database with SQLJ and getting the result set as an arraylist. I would like to return this list as XML, but not sure how to do it.

Does anyone have an example of returning a result set as XML and is using an Arraylist the best way to do this?

Should I use JAXB? if so how?

© Stack Overflow or respective owner

Related posts about java

Related posts about Xml