I need to move a row from one table to another

Hi, I need to move a row from one table to another. I tried with a “for each” loop and “add row” but it gives the error that the row already exists in another table. So I searched the forum and found the invoke method “ImportRow”. Both tables have the same structure(Name, EMail, Exception, Timestamp). Unfortunately, the only thing it does is to copy the eMail address to the “Name” row.
Any idea what I am doing wrong?

1 Like

you can use the add data row activity.

Give the below array values to add a data row -

  • ArrayRow - An array of objects to be added to the DataTable. The type of each object should map to the type of its corresponding column in the DataTable.

{Name,Email,Exception,Timestamp}

Regards,
Karthik Byggari

1 Like

Buddy @Jizh
Kindly refer to this xaml and i hope it got resolved
Adddatarow.zip (13.3 KB)

Kindly revert for any queries

Cheers

1 Like

Thank you guys for the reply
@KarthikByggari I will try that solution with {row("Name"),row("Email"),row("Exception"),row("Timestamp")}
@Palaniyappan I can’t use clear datatable. The logic behind it is the following.
I have table1 that contains some exceptions of the current execution. Table2 is the exception of the previous execution minus the ones that worked in the current (no longer required to retry).

@Jizh Buddy i used clear datatable to delete the empty row which is there in builddatatable…its not necessary to have it…you can remove and even try for it…it worked.

Cheers

1 Like

@Palaniyappan @KarthikByggari
There must be a type mismatch in my case then, thanks for the help.

1 Like

NO worries buddy keep going

Cheers

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.