Configure a database statement for a SQL service provider
After creating a database connection, you can configure database statement for a SQL service provider.
Procedure
- In the navigator, click .
- Click Add Statement.
- In the Name and Description fields, enter a name and description for the resource.
- In the Displays panel, click Database Editor.
- Click the Designer tab.
-
From the Statement Type drop-down list, select one of the
following actions for a statement.
Select... To... Query select Update insert, update, or delete - From the Provider drop-down list, select SQL Data Provider.
- In the Statement section, enter a valid SQL string, and then click Create Parameters to generate automatically any parameters used in the statement.
- Optional: To add other parameters, in the data grid, click Add.
- Optional:
To configure the data grid properties:
- In the Name column, select a cell, and then enter a new name.
- In the DataType column, select a cell, and then from the drop-down list, select a data type.
Note: The parameters must match those used in the statement string. - To remove a parameter, in the data grid, select a row, and then click Delete.
- Click Save.
-
To test the statement:
- To execute a statement, open a workflow, and then insert and configure a Call Method activity.
-
From the call method activity configuration panel:
- Optional: You can also execute a procedure from WPF and Silverlight forms by invoking a server method. For more information see Bind a return value to a DataGrid using from server methods.