Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 Email options other than SQLMail/CDONTS

Author  Topic 

jackstow
Posting Yak Master

160 Posts

Posted - 2002-11-21 : 04:57:30
I'm moving a website over from one hosting company to another. With the old hosting company SQL Server and IIS were on the same box. The new company have a dedicated SQL box and an IIS box. Great I thought! Problem is that there is a job that runs each day and, under certain conditions, fires off emails. This worked fine on the old server using CDONTS but as the new SQL box doesn't have IIS/SMTP installed that won't work. They do have SQLMail, but it keeps falling over and just doesn't run reliably.

Are there any other options for sending email from a dedicated SQL Server box? Hosting company not keen on installing Notification Services either..

Merkin
Funky Drop Bear Fearing SQL Dude!

4970 Posts

Posted - 2002-11-21 : 07:14:06
Hi there

Here is a way I have gotten around this.

Store the queries as procs on the SQL Server box, then write a vb script that calls it and fires off the email.

You can schedule the vbscript on the IIS box.

Hope that helps

Damian
Go to Top of Page

SamC
White Water Yakist

3467 Posts

Posted - 2002-11-21 : 20:33:52
I think you mean to schedule a VB script that calls a SP retrieves the email subject, body, to, from and sends the email from VB. Is that right?

Sam

Go to Top of Page

Merkin
Funky Drop Bear Fearing SQL Dude!

4970 Posts

Posted - 2002-11-21 : 21:04:25
Yeah, something like that

Damian
Go to Top of Page

SamC
White Water Yakist

3467 Posts

Posted - 2002-11-21 : 22:35:17
Ya know, I think Merkin's got a good solution, but I'd rather find a provider that provides email from the sql server rather than rewrite and debug what may be several points of code that send mail.

There are several good hosting services around. You might look into ORCSweb.com . They host the sqlteam site (check sqlteam homepage).

Sam

Go to Top of Page

jackstow
Posting Yak Master

160 Posts

Posted - 2002-11-22 : 04:22:34
I'm afraid the decision has already been made about the hosting so I'm stuck with it. The scheduled VB script will do the job, but it is a bit of a fudge in the end and will require quite a bit of recoding. Lastest idea from the hosting company is Blat - http://pages.infinit.net/che/blat/blat.html - which is installed on the database server. Doing something like this might work (but doesn't at the moment!):

exec xp_cmdshell 'blat.exe - -f db@myserver.com -t email@myclient.com -server mymailserver -subject test -body hello'

Is it really a that bad an idea to have IIS/SMTP on a db box by the way?

Edited by - jackstow on 11/22/2002 04:30:45
Go to Top of Page

jackstow
Posting Yak Master

160 Posts

Posted - 2002-11-22 : 05:55:02
Oh! This seems to work - http://support.microsoft.com/view/tn.asp?kb=312839 - CDOSYS Mail.. Cool!
Go to Top of Page
   

- Advertisement -