insert data from one table to other table for selected rows

I have a requirement where i want to display the table using IS service and insert into other table for the selected rows using insert IS service.
I am able to display the table in the portlet using updatable table content provider and added one standard column with select row check box.
I am able to see the rows which are selected in “list of selected rows objects”.

Can anyone help me in binding these values into insert service IS.

thanks in advance

Please have a look at the document titled “Updatable_Table_in_Task.doc” on this thread:

That document describes updating rows on tabular data associated with a task, so you’ll need to adapt it to your scenario.

Your scenario is actually pretty similar, but instead of updating the task data, you’ll set the results to the input of the webservice that sends data back to IS. (Presumably you have an IS service that writes back to the database)

Hopefully this helps,

hi mark,
In the sample you are storing the data in task data. But in my case, the output i.e selected rows objects which should be mapped to insert IS service input. When i tried binding the selected rows object to input of IS service its throwing illegal state exception and Unable to convert data type. Can you please help me in solving this.

thanks in advance,

Hi Rajesh,
If you want to use the output of the “read” IS service into the input of the “write” IS service, you should put both services in the same Web Service Descriptor in IS (supposing you are using v8.x). When both services are in the same WSD, the generated java classes will be the same (i suppose you used the same IS doctypes in your services) and you’ll be able to do what you need without any effort.
If you are using v7.x, then you’ll have to map yourself those classes using, for example, Dozer. This requires a few additional lines of code, but it’s not difficult (samples for this usage can be found in dozer’s web site).
Hope this helps,

thanks javier,
Your post was helpful,

I got the values of the selected rows and stored each value into String List , then mapped the same to insert service input.
Is this a better practise?