hasDBRows Step
Description:
This step checks whether DB rows are available.
Inputs
- connectionString– Connection
- changeDatabase-- Connect to different database description
- sqlStatement– SQL statement multiline
- variableName – Variable/Global to store the record count
- commandTimeOut – Command timeout value
Returns
- True – step executed successfully
- False – step failed to execute
Usage:

Example:
Let’s build and execute the “hasDBRowsDef” example.
- Create a new process definition named “hasDBRowsDef” and open it in designer mode.
- Drag a “hasDBRows” step to the canvas.
- Define a variable or a global to store the result.
- Connect the dots between the “Start” step and “hasDBRows” steps, as shown above.
- Click the “hasDBRows” step to configure its “Required” properties. Provide a name for the step. Select the connection string from the drop-down list. Enter a SQL SELECT query. Click the Save button. Note: Click the "AI Predict" button to have the Copilot add new process steps that match your process description.

- Click the “hasDBRows” step to configure its “Optional” properties. If required, specify a different DB name (other than FlowWright); by default, the step connects to the FlowWright database. Specify a variable or global reference to store the result. Specify the time-out value (in seconds). Click the Save button.

- The “Logging” configuration is necessary for documentation and for measuring workflow progress and the percentage complete. This is achieved by configuring the step state and percent fields individually, as shown in the images below. Configure the “Logging” using the following properties.

- Save the process definition, create a new instance, and execute it. Render the process instance. Click the process step to view its properties. The step should check whether database rows are available. Render the process instance again to view the result stored in the variable or global.

Definition Sample:
You may download the sample definition(s) from the link provided and later import them (drag-and-drop) into your FlowWright Process Definition (XML file) or Form Definition (HTML file) page.
Note: Please verify and complete the process steps for any missing configurations, such as file path references and database connections, after the import. Then, save the definition to confirm the changes.