Integrating an External Database with a Flow (3.2.0)

Last Updated: 07/20/2016 Introduced in Verision: 2.0

Database entities represent external databases which can be integrated with a flow. To add a database within the portal, navigate to the folder System > Designers > Integrations > Databases, click the Create Connection button, and supply the necessary details. Once a database is introduced, components to query, insert, or update data to or from the database within the Flow Designer can be used. They are found under Integrations > My Integrations > Database > [Database Name](Database) > [Table Name].

Example:

Our example flow will access a local database called Northwind, retrieve all of the records from the table Products, and display them in a data grid form.

formInDebugger

Begin in the portal by navigating to the folder System > Integrations > Databases. Click the Create Connection button.

createConnection

In the resulting window we fill in all required fields to connect to the database and click Test to test our connection.

testConnection

After testing the connection Decisions informs us if the connection was Successful. If the connection was successful we can click Ok to save Database integration.

connectionSuccess

Our database integration shows up in the Databases Folder. We navigate to the Northwind database integration Folder and click Add Table from Folder Actions Panel.

addTable

 

In the Add Table window we select available Table first (in this case we use Products table).

pickTable

When table is picked, we can select what fields we want to work with, define primary keys for the Table, and check what Steps should be generated by the System. Click Ok to save this Table integration.

definePickedTable

In the Northwind Database integration Folder we should be able to see our Products Table now.

tableAdded

To use data from the integrated Table we can create a Flow. We navigate to the Designer Folder and click Create Flow button from the Folder Actions panel.

createFlow

Next, we Name the Flow and click create to proceed to the Flow Designer.

nameFlow

In the Flow Designer we add Get all from dbo.Products step from the Integrations > My Integrations > Database > Northwind (Database) > dbo.Products (Table) category.

addGetAllStep

Then, we connect Failed outcome from the Get all from dbo.Products step to the End Step in our Flow. We select Get all from dbo.Products step on the workspace and Ignore Limit Count input in the Step Information Layer window. Click Add Step.

addStepAfterGetAll

On the Done outcome we add Show Form step from the Favorite Steps category.

addShowFormStep

In the resulting window we Name our Form and click Create to proceed to the Form Designer.

nameForm

Our form has a Button control from the Actions category and a Data Grid component from the List category in the ToolBox to display data from our Table. Data Grid component configured to display data of Northwind_dboProducts type. When we finished designing our Form we can save and close Form Designer.

formDesign

Back in the Flow Designer we select our Form step on the workspace and Step Information Layer pops up. We locate Products Input to our Form and using Select Value Mapping Type we pick Products_Result data from the Get all from dbo.Products step’s outcome.

dataMappingForForm

Then, we connect Done outcome from the Form step to the End Step in our Flow. This completes our Flow design. From the top panel of the Flow Designer we click Debug Flow to test our Flow.

Note that in Decisions version 3.5, you’ll need to click Test Flow to access this process.

3.5 Test Flow Shot

debugFlow

Our Form opens in the Debugger. Data Grid component is populated with data from the Get all from dbo.Products step. We can click Done to close the Form and terminate our Flow execution.

formInDebugger

 

 

 

Additional Resources