Queues - Bot run stats

Hi,
While using data table, I log into a text file named stats how many rows were successful or threw Business exception etc. How to capture stats using Orchestrator queues? Can you provide an example please? Thanks

HI @A_Learner

Please check the below thread:

Regards

Hi @A_Learner

Could you be more specific, give me the more information then only we are able to give a solution for this query.

Using queues, how do I capture transaction status for example how many are succesful, how many got into Business Exception, how many system exceptions, what is the bot run time etc.

Thank you,

Hi @A_Learner

You can use Get Queue Items acitivity. The output is IEnumerable(System.String). Use the output of Get Queue Items in For Each and you can currentItem.Status which will give status of current transaction item. In the body of For each give the Else If condition and then give the counter so that the count of Succesful, Business,System can be occured.

In the coditions you can give as

currentItem.Status.ToString.Contains("Succesful")

For getting Bot run time,
In the starting of the flow i.e at Init State assign StartTime= Now and and End process assign EndTime= Now.
Use the below syntax in assign:
timeDiff= EndTime-StartTime
timeDiff is of DataType System.TimeSpan
you can print the timeDiff variable in Log message by below way:

"Total time taken by the process: "+timeDiff.ToString("hh\:mm\:ss")

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