Image you had a php service that would connect to a mysql database and return query results via soap.
That php service (SOAP server) could look like that:
To make this example work you would need to create a database called userdb with an usertable. This would be the sql to create the table and put in some data:
After everything is created you would like to call the function get_names via a java program:
This java code makes a soap call to the php soap server and puts the returned database result into a List of Hashmaps with the database entries. The example output of the java program looks like that:
(3/0)added id = 1
(3/1)added name = alexander
(3/2)added email = a.balsam@nedeco.de
(3/0)added id = 2
(3/1)added name = alexander
(3/2)added email = alexander@balsam.de
If you have any input on this leave a comment or write some additional code and send it to me.