Hi All,
I am currently working on an automation, based the status of each transaction like Success, Business Exception, System exception I need to update to the database (MS Sql), how to do this in UiPath??
Hi All,
I am currently working on an automation, based the status of each transaction like Success, Business Exception, System exception I need to update to the database (MS Sql), how to do this in UiPath??
I need to update in set transaction status
follow these stpes
Inside SetTransactionStatus.xaml, add an “Execute Non Query” activity under each branch (Success, Business Exception, System Exception).
sql
UPDATE TransactionsTable
SET Status = @Status, UpdatedAt = GETDATE()
WHERE TransactionID = @TransactionID
@Status
→ "Success"
, "Business Exception"
, or "System Exception"
@TransactionID
→ in_TransactionItem.SpecificContent("TransactionID")
"Success"
"Business Exception"
"System Exception"
generated by LLM
cheers!!
After Set Transaction activity in Set Transaction Workflow, use Database activity Run Command
which is for UPDATE
, INSERT
, and DELETE
statements, the return value is the number of rows affected by the command. For all other types of statements, the return value is -1.
Make sure you use Connect
to connect to the database and then after Run Command
use Disconnect from Database
to disconnect the connection.