Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to post an HTTP FORM from SQL Server?

Status
Not open for further replies.

jimlord

Programmer
Joined
Nov 29, 2001
Messages
4
Location
US
Does anyone know how to execute an HTTP FORM from within SQL Server (not build a form, but actually fire off the URL)?

In our particular case, we are using Cold Fusion and have developed Cold Fusion form API's to other systems. It is these forms we would like to call from within SQL Server.

Jim
 

Why would you do that? SQL queries run on the server not in a client interface. Terry L. Broadbent
FAQ183-874 contains tips for posting questions in these forums.
NOTE: Reference to the FAQ is not directed at any individual.
 
Yep, I know bud. But it's not my database I want to interact with. It's 3rd party systems that have developed form-driven API's to their systems and are loathe to provide me any other access to their systems. I have to interact with those systems, but as I've designed my system in 3-tier architecture (ie, most processes take place in SQL Server stored procs or xp's), I'm in the position that I mentioned above -- having to call foreign http forms from within SQL Server.
What I've figured out for the moment is to write transactions to a queue table and then run a recurring Cold Fusion process to fire off the forms based on records it finds in the queue table. However, this is both inelegant and subject to instability and, I believe, unnecessarily complex. This is why I'm hoping there's some way to effect an http call from SQL Server.
Any ideas?
 
Hello Lord Jim,

It's not so crazy to need to do this. I have a similar problem in an application which I fully control. It is an ASP web site with scripts to generate and display reports from a database. When the request came to automatically generate these reports on a schedule, it seemed easiest to write an ASP script to run the reports. But how to do this without a person using the web site? The solution I found uses the Windows task scheduler to start and stop an instance of iexplore.exe as a Windows Service. So IE is running in background for a few minutes, it requests my control script, which runs the reports and sends emails.

Point is, if I knew how to make an http request from SQL Server, I might have done that instead.

By the way my Sys Admins were appalled at this whole idea, but they had no alternative solution.

Richard
 
Hi rac2,
Okay, here's an update and upgrade on our current solution. We've now written a C++ xp that our SQL Server can call. The xp processes HTTP requests that are passed to it as parameters. It's working pretty well but it's still not as elegant as an internal SQL HTTP would be. As for stability, well only time and log files will tell...
Still if anyone comes across an MS SQL HTTP call, I'ld love to know about it.

Jim
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top