Tools

Learn how to use different tools to test things outside of process execution

Last published at: December 27th, 2023

FlowWright provides a couple of different tools to test things outside of process execution. 

Navigate to Administration - Tools - Actions menu option. Select “Expression Evaluator” to validate the C# expressions. Select “Email” to validate the email settings with content. Select “SQL Query” to validate the sql syntax using SELECT statements (only).   

 

Expression evaluator tool

Expressions are used throughout many workflow processes.  Use the expression evaluation tool to test expressions to make sure expressions are defined correctly and they work.  The following UI can be used to test expressions:  

This tool accepts any C# format expression including variables within these expressions. Create variables with appropriate data types and select Add option. 

Here are some example expressions:

34 + 45

355 / 5

Variable.num1 + Variable.num2

DateTime.Now.AddDays(5) 

Click on “Compute Expression” button to see the result of your calculations.

Select “Save Expression” button for reuse later on. Provide an unique name for the expression.

Reuse the expression by selecting from the dropdown list. The expression is copied to the text area. Click on “Compute Expression” button to see the result of your calculations. 

 

Expression evaluator supports LINQ / LAMBDA C# expressions

Now supports LINQ / LAMBDA C# expressions.

e.g: The following example demonstrates how to concantenate 3 variable values with comma and also handle null values.

string1 = "Apples, Bananas"

string2 = ""

string3 = "Mangoes, Oranges"

The expression syntax is as follows.

string.Join(" , ", new string[] { variable.string1, variable.string2, variable.string3 }.Where(s => !string.IsNullOrEmpty(s))) 

Define the variables with values and use the above syntax in the Expression to evaluate. 

Click on the (fx) icon to invoke the Expression Builder feature as a modal window inside the box marked. Use the expression builder UI to build an expression and validate it. Copy the expression to clipboard and paste it where an input is required for workflow step property (like above). Click on Clear Expression button to remove previous expression syntax from the workspace.  

 

Email

Using the email test tool, test email messages can be sent to test the email configuration.

 

SQL Query

SQL tool allows the user to execute and test SQL queries by selecting the desired database connection. The UI is as shown below: 

Provide a sql statement and select “Execute SQL Query” button to see the result. 

Use “Save SQLQuery” button to save the sql syntax by providing an unique name. And reuse it by selecting “Load SQLQuery” button.

Select “Load SQLQuery” button to view the list of previous saved queries. Choose any query from the list and the expression is loaded to the text area. Select Execute SQL Query button to see the result. 

Select Generate INSERTs button to generate sql insert statements for the result obtained above. The file is downloaded to the local download folder.

Use the notepad to view the sql inserts generated by the tool. Note: User discretion is advised to validate the inserts statements before execution as the SQL Tool is not familiar with the target table intended for data insertion.