Skip to main content


 

Symptoms


We have a SmartObject created from a data table of a SQL database. Now we need to add an additional datafield to the data table and use the Update method to change the values of it. How can I add an additional input to a default Update method of the SmartObject, the additional input is mapped to the additional datafield of the data table. We do not want to recreate the Smart Object, because we have some customized methods are linked to the Smart Object.

 

Diagnoses


Use K2 designer to edit the method required.

 

Resolution

Here are the steps to complete:

1. Add column to table
2. Open SmartObject Service Tester
3. Refresh the SQL service instance
4. Open K2 Designer
5. Edit the SmartObject
6. Add a new Property for the new column
7. Select the Methods Tab
8. Edit the Update Method
9. Edit the Update method binding
10. Assign the new property to the new column
11. Press ok, finish and finish

The Update method should now be able to update the new column.
If you want to test in SmartObject Service Tester, refresh the SmartObject first.

I would suggest using this method to also update the Create, Read and List methods (unless you have customized them and it is not necessary).




 
Be the first to reply!

Reply