You can create operations that call any stored procedure
that is deployed in your database.
Before you begin
The stored procedure must be deployed on the database that
is associated with the Web service in which you want to create the
operation.
About this task
Restrictions:- Each operation within a Web service must have a unique name.
- You can include one stored procedure call per operation.
Procedure
To add to a Web service an operation that calls a stored
procedure:
- Drag the stored procedure from the Data Source Explorer
and drop it onto the Web service in the Data Project Explorer.
- If the stored procedure is listed in the Stored
Procedures folder of your project and the stored procedure
is deployed to the database that your project is using, right-click
the stored procedure and select Add to Web Service.
- If an operation that is based on the stored procedure already
exists in a Web service in a project in your workspace, drag the operation
and drop it onto the target Web service. If you drag from
one project to another, either of these conditions must be true:
- Both projects are associated with the same datasource.
- One project is associated with a snapshot of the database that
is associated with the other project.
What to do next
If the stored procedure returns result sets and always accepts
the same input values, use the
Edit Operation wizard
to specify the input values. The workbench then runs the stored procedure
to generate an XML schema that describes the result sets in detail.