call a web service from T-SQL in Sql Server 2008

14,122

Solution 1

You can automate the XMLHTTP server object using the Object Automation extended stored procedures.

Example here

I suggest you use the CLR or an SSIS package though.

Solution 2

The Web Service Task should allow you to do that.

  1. Web Service Task

  2. How to: Call a Web Service by Using the Web Service Task (SQL Server Video)

I'm assuming you are doing this from an "intergration services" package

Solution 3

If you are doing this in a sproc, then you could create a tiny VB program and use

exec sp_cmdshell 'c:\path\myapp.exe'

to call your program. Technically its not CLR embedded in SQL Server right? :)

Share:
14,122
Sako73
Author by

Sako73

Updated on June 14, 2022

Comments

  • Sako73
    Sako73 about 2 years

    Is there a way to call a HTTP web service from T-SQL (no SQLCLR) in Sql Server 2008? I just need to send information out, I do not need to receive anything into T-SQL.

    Thanks.