How to loop through a column in SAP table to check if a specific value exists and update the value in SAP.
Please advise
How to loop through a column in SAP table to check if a specific value exists and update the value in SAP.
Please advise
Did you try using sap table scope activity?in that you have option to give a column and row …you can use counter to get eachrow as you need
Cheerd
Hi, Thank you for responding, yes, I was trying with it, but I am not able to get it right, any reference material you got ?
Hi, @monisharpa2020 in that case, you can alternatively use **Extract Structured Data** activity. When you get a datatable from that activity, you can use **Lookup Datatable** activity to get the index of the row that the value you look for exists.
After getting the index, in SAP, do **Type Into** on any row of your target column. Then modify the selector of **Type Into** with the index you got earlier.
I hope this could solve your problem. Please let me know in case you need further help.
Hi Anil, I saw this solution , but this wont work as they are looping using a datatable, my requirement is I have to loop SAP column and loop rows and see if a specific value exists in each row.
you can se a while loop or for loop same way and use index attribute in field of sap
please check this activity
cheers
Thank you for your inputs, with regards to the SAP table cell scope activity could you clarify where the above mentioned attribute can be defined or configured so that same can be accessed in the loop during each iteration.


Already you gave the column and the row index as counter now you can loop this inside a loop and for eqch iteration you wold get each row value for the given column…
Cheers