You can test the actual Data Access request and response during simulation by performing some additional steps prior to beginning simulation. The steps involve using the Eclipse Data Source Explorer that is bundled with Process Developer.
Using the Data Source Explorer, you can generate sample data from an actual statement execution and export the data to Process Developer in the correct schema format. This technique makes the actual data returned from the result set available to a process variable to which you are mapping data.
Step 1. Set up a database connection:
Window > Show View > Other > Data Management > Data Source Explorer
Right-mouse click on Database Connections and select
Select a Connection Profile Type from the list. For example, select MySQL.
Name the new profile, and select
On the Driver page, select your database driver from the list. If the driver is not in the list, select
and specify a driver definition.
Enter the URL to connect to your database. For example, the default URL for MySQL is j
Select Test the Connection, and if successful, finish the wizard.
Notice there is a new database listed in the Data Source Explorer.
Step 2. Connect to the database and execute a statement:
In the Data Source Explorer, right-mouse click on your database and select Connect if needed. Expand the tree, and you can see an outline of all the tables in your database.
Right-mouse-click on your database and select Open SQL Scrapbook.
Select your database from the Name list.
Your Data Source Explorer and SQL Scrapbook window should look similar to the following example:
If your Data Access invoke is based on the
operation, copy and paste your single execution statement into the SQL Scrapbook.
Right-mouse click and select
Execute Selected Text
. Notice that the results are returned in the SQL Results tab.
operation, copy and paste your statements into the SQL Scrapbook. Right-mouse click and select
Step 3. Save the SQL Results as sample data:
In the SQL Results view, right-mouse click and select
Save > Current Result
You must select Current Result for a a single statement execution and All Results for multiple statement execution. The format of the data differs depending on your selection.
dialog, browse to your Data Access project in your workspace and select the
folder. Name and save your file into this location.
In the File Type box, select Process Developer Data Access Sample. Then set the Output encoding to UTF-8. The following example shows all settings: