Ivan Krizsan wrote:Hi!
You should really try to avoid that kind of multidimensional arrays. It makes your code much more difficult to understand and maintain.
Instead, implement a Java-bean class that represents one row of data from, in this case, the database.
Then, for each row in the database query result, create an instance and populate its data.
Finally, insert each instance of the Java-bean in an array and return that array.
Best wishes!
Arun Kumar wrote:Try this in your code
@SOAPBinding
(
style = SOAPBinding.Style.DOCUMENT,
use = SOAPBinding.Use.LITERAL,
parameterStyle = SOAPBinding.ParameterStyle.WRAPPED
)
Ivan Krizsan wrote:Hi!
I think that the reason for the element in question being named <item> may be related to the fact that you use RPC binding.
Have you tried using DOCUMENT style binding?
Best wishes!
Thanks Ivan Krizsan, for your reply. I will try your solution.Ivan Krizsan wrote:Hi!
You should really try to avoid that kind of multidimensional arrays. It makes your code much more difficult to understand and maintain.
Instead, implement a Java-bean class that represents one row of data from, in this case, the database.
Then, for each row in the database query result, create an instance and populate its data.
Finally, insert each instance of the Java-bean in an array and return that array.
Best wishes!
Arun Kumar wrote:you can use jdbc/hibernate to get the data from database and pass it as POJO/String response via apache-cxf