Connecting to a Web Service as a source

This shows how to connect to the Scribe Sample Web Service and use it to push data to your local implementation of the Scribe Sample database.

The source data in this example is an array of complex types representing a contact. As it is a complex type, the field names are prefixed by the parent object, for example ReturnValue_ContactID.

Each Contact has a ContactID, Name and Company property. Furthermore, each Contact has 2 addresses (BillToAddress and ShipToAddress). Each Address has a Street, City, State and Zip property.   

The UML for this sample type is as follows:

 

Example

Note: The purpose of this sample is only to illustrate connecting to a Web Service as a source. It does not produce a working sample that can be run. To complete the sample so it can be run, add valid data links or formulas for all required fields.

To create a source connection for the Adapter for Web Services

  1. In the Scribe Workbench, click View > Connections. The Connection Manager appears.
  2. Click New. The Add a Connection dialog box appears.
  3. Expand Adapters, click Web Services, and click OK. The Web Services Connection Manager appears.
  4. Click Add. The Edit Web Service dialog box appears.
  5. In Location of WSDL, type the location of the connection to the Scribe Sample Web Service - http://community.scribesoft.com/ScribeSample/ScribeSampleWebService.asmx?WSDL
  6. Click Validate.
  7. In Display Name, type a unique name.
  8. Click Save. You return to the Web Services Connection Manager.
  9. Select your new Web Services connection, and click Connect. The Login dialog box appears.

    There are no additional credentials (that is, a User ID and Password) required.

  10. Click OK. The Connection Settings dialog box appears.
  11. Click OK. The Connection Manager dialog box appears.
  12. Click Close.

create a target connection for the Scribe Sample database

  1. In the Scribe Workbench, click View > Connections. The Connection Manager dialog box appears.
  2. Click New. The Add a Connection dialog box appears.
  3. Expand ODBC Data Sources and click Scribe Sample.
  4. Click OK. The SQL Server Login dialog box appears.
  5. Enter the Login ID SCRIBE and the password integr8!.
  6. Click OK. The Connection Settings dialog box appears.
  7. Click OK. The Connection Manager dialog box appears.
  8. Click Close.

configure the source

  1. In the Scribe Workbench, click Source > Configure.
  2. From the drop-down list of connections, select the connection for the Web Service you just set up.
  3. Expand All Data Objects, select the Web method GetContacts, and click OK.

At this point, you should see the various Contact and Address fields in the Scribe Workbench that represents your source data.

configure the target

  1. In the Scribe Workbench, click Target > Configure Steps. The Configure Steps dialog box appears.
  2. From the drop-down list of connections, select the connection for Scribe Sample.
  3. Add an Insert step for the table ACCOUNT.
  4. Click Close.

set up the data links

  1. Create a data link between the ReturnValue_Company field on the source, and the ACCOUNTNAME field on the target.
  2. Do one of the following to save the sample DTS file:
  3. Click the Test button and preview your integration in the test window. You should see all of the contact data for the first contact returned by the Web Method.
  4. Click Next to see the contact data for the next record. This sample returns two contacts; if you click Next again, you will receive an error message.
  5. Click Close. The Test window closes.

See Also

Creating a Web Service connection

Using a Web Service as a source