In this section: |
You want to be able to track success or failure when the data flow runs. You will do this by creating two procedures and including them in your process flow. Then you will supply the logic that invokes the appropriate one for the condition that is encountered.
Following the same modular model we have been using, you will create each of the stored procedures as a separate file that can be used in this process flow and others.
First you will create a procedure that will appear in the log when the data flow executes correctly.
-TYPE SUCCESS!
Right-click the salesdemo application directory again, and choose New and Procedure.
-TYPE FAILURE!
If applicable, this entry will be displayed in the DataMigrator log. Close the editing window.
Both procedures are now listed in the salesdemo application directory.
The Process Flow tab should now look like this:
Next step: You have now created two branches from the data flow object to the procedures. Now you need to define the behavior associated with each branch of the flow. You will do that from the connector arrows.
Follow-up actions based on the success or failure of the data flow execution are initiated by connection logic, in the form of return codes.
In the tutorial, we will use the default connection logic associated with the green and red arrows that branch to the stored procedures you created. Since these procedures write a line of code in the DataMigrator log, you will be able to see quickly which path the execution followed.
Tip: The implementation we have chosen to demonstrate can be built quickly and offers easily demonstrable results. However, there are many ways you can use branching within a process flow. For example:
or
Your options are many and varied.
Let us now review the default logic that will trigger the running of your two stored procedures.
OK Default Condition (Return Code is 0) is selected by default, as shown below.
Next step: It is time to run the Process Flow to see the results, as reflected in the DataMigrator log.
iWay Software |