Friday, February 24, 2012

about SQL mail

I want to try SQL mail function in my machine but I can't get it works.
information about my machine:
OS: windows 2000 as a workgroup
sql 2000
office 2000 (also tried office xp)
the mail was sent to my outlook
when I try parameter TYPE with IPC, I got it work but only once. later I
can't get it work. I don't know why.
I don't know how to set up TYPE.
THANKS,
TOMThank you Tony,
I downloaded that file but I don't know how to use it. Could you give me
more information about it?
thanks,
Tom Li
"Tony Rogerson" <tonyrogerson@.sqlserver.eu.com> wrote in message
news:eKZeQTKYDHA.2020@.TK2MSFTNGP10.phx.gbl...
> If you just want to send mails from SQL Server then forget about using
MAPI
> etc... and download the xp_smtp_sendmail extended stored procedure from
> sqldev.net, so long as you have an SMTP server then it will work and its
> really good!
> --
> Tony Rogerson
> SQL Server MVP
> http://www.sqlserverfaq.com?mbr=21
> (Create your own groups, Forum, FAQ's and a ton more)
>|||Hi
Usage is described with example on the download page.
http://www.sqldev.net/xp/xpsmtp.htm
What is your particular problem?
John
"Tom Li" <mrpiiii@.sina.com> wrote in message
news:Oqn30rMYDHA.652@.TK2MSFTNGP10.phx.gbl...
> Thank you Tony,
> I downloaded that file but I don't know how to use it. Could you give me
> more information about it?
> thanks,
> Tom Li
> "Tony Rogerson" <tonyrogerson@.sqlserver.eu.com> wrote in message
> news:eKZeQTKYDHA.2020@.TK2MSFTNGP10.phx.gbl...
> > If you just want to send mails from SQL Server then forget about using
> MAPI
> > etc... and download the xp_smtp_sendmail extended stored procedure from
> > sqldev.net, so long as you have an SMTP server then it will work and its
> > really good!
> >
> > --
> > Tony Rogerson
> > SQL Server MVP
> > http://www.sqlserverfaq.com?mbr=21
> > (Create your own groups, Forum, FAQ's and a ton more)
> >
> >
>|||Hi Tom,
Its best to read through the instructions supplied on the site - there are a
lot of examples - just follow them through.
Tony.
--
Tony Rogerson
SQL Server MVP
http://www.sqlserverfaq.com?mbr=21
(Create your own groups, Forum, FAQ's and a ton more)|||Sorry Sir,
I saw there are two procedure names in the code, xp_smtp_sendmail and
sp_smtp_sendmail. I have no experience of creating stored procedure. so that
may be a stupid question.
And we may be in different location with different time zone. Are you in the
States. I am in China.
"Aaron Bertrand - MVP" <aaron@.TRASHaspfaq.com> wrote in message
news:uT7pfHNYDHA.2152@.TK2MSFTNGP09.phx.gbl...
> > I found out that the procedure has different name in the file. Please
see
> > attached file.
> I'm still not clear what the problem is. Also, can you please fix your
> system clock.
>|||Thanks John,
I don't know how to use it after I downloaded xp_smtp_sendmail procedure.
Tom
"John Bell" <jbellnewsposts@.hotmail.com> wrote in message
news:3f38e335$0$18495$ed9e5944@.reading.news.pipex.net...
> Hi
> Usage is described with example on the download page.
> http://www.sqldev.net/xp/xpsmtp.htm
> What is your particular problem?
> John
>
> "Tom Li" <mrpiiii@.sina.com> wrote in message
> news:Oqn30rMYDHA.652@.TK2MSFTNGP10.phx.gbl...
> > Thank you Tony,
> >
> > I downloaded that file but I don't know how to use it. Could you give me
> > more information about it?
> >
> > thanks,
> >
> > Tom Li
> >
> > "Tony Rogerson" <tonyrogerson@.sqlserver.eu.com> wrote in message
> > news:eKZeQTKYDHA.2020@.TK2MSFTNGP10.phx.gbl...
> > > If you just want to send mails from SQL Server then forget about using
> > MAPI
> > > etc... and download the xp_smtp_sendmail extended stored procedure
from
> > > sqldev.net, so long as you have an SMTP server then it will work and
its
> > > really good!
> > >
> > > --
> > > Tony Rogerson
> > > SQL Server MVP
> > > http://www.sqlserverfaq.com?mbr=21
> > > (Create your own groups, Forum, FAQ's and a ton more)
> > >
> > >
> >
> >
>|||Hi
On http://www.sqldev.net/xp/xpsmtp.htm there is section called installation
which details how to install the extended stored procedure. The other
examples of how to call the extended stored procedure can be cut and pasted
into query analyser... but at a guess you have MSDE, in which case paste an
example into a text editor and save the file to run from osql. If you do
have MSDE then you may want to look at
http://www.aspfaq.com/show.asp?id=2442
John
"Tom Li" <mrpiiii@.sina.com> wrote in message
news:eyojRMWYDHA.2592@.TK2MSFTNGP09.phx.gbl...
> Thanks John,
> I don't know how to use it after I downloaded xp_smtp_sendmail procedure.
> Tom
> "John Bell" <jbellnewsposts@.hotmail.com> wrote in message
> news:3f38e335$0$18495$ed9e5944@.reading.news.pipex.net...
> > Hi
> >
> > Usage is described with example on the download page.
> >
> > http://www.sqldev.net/xp/xpsmtp.htm
> >
> > What is your particular problem?
> >
> > John
> >
> >
> > "Tom Li" <mrpiiii@.sina.com> wrote in message
> > news:Oqn30rMYDHA.652@.TK2MSFTNGP10.phx.gbl...
> > > Thank you Tony,
> > >
> > > I downloaded that file but I don't know how to use it. Could you give
me
> > > more information about it?
> > >
> > > thanks,
> > >
> > > Tom Li
> > >
> > > "Tony Rogerson" <tonyrogerson@.sqlserver.eu.com> wrote in message
> > > news:eKZeQTKYDHA.2020@.TK2MSFTNGP10.phx.gbl...
> > > > If you just want to send mails from SQL Server then forget about
using
> > > MAPI
> > > > etc... and download the xp_smtp_sendmail extended stored procedure
> from
> > > > sqldev.net, so long as you have an SMTP server then it will work and
> its
> > > > really good!
> > > >
> > > > --
> > > > Tony Rogerson
> > > > SQL Server MVP
> > > > http://www.sqlserverfaq.com?mbr=21
> > > > (Create your own groups, Forum, FAQ's and a ton more)
> > > >
> > > >
> > >
> > >
> >
> >
>|||Hi, John
It is a really great help. I have installed the procedure. But I can't send
mail. I guess something wrong with the SMTP server. My SMTP server is
"263commail.com" which I used in my outlook express. I try the PING command
with this server name and get the following message:
====================================================C:\>ping 263commail.com
Pinging 263commail.com [211.150.100.11] with 32 bytes of data:
Request timed out.
Request timed out.
Request timed out.
Request timed out.
Ping statistics for 211.150.100.11:
Packets: Sent = 4, Received = 0, Lost = 4 (100% loss),
Approximate round trip times in milli-seconds:
Minimum = 0ms, Maximum = 0ms, Average = 0ms
======================================================I was told that some server stopped any message from a PING command. Also my
outgoing server requires authentication. Is that a problem?
thanks,
Tom
"John Bell" <jbellnewsposts@.hotmail.com> wrote in message
news:3f39e4de$0$15036$ed9e5944@.reading.news.pipex.net...
> Hi
> On http://www.sqldev.net/xp/xpsmtp.htm there is section called
installation
> which details how to install the extended stored procedure. The other
> examples of how to call the extended stored procedure can be cut and
pasted
> into query analyser... but at a guess you have MSDE, in which case paste
an
> example into a text editor and save the file to run from osql. If you do
> have MSDE then you may want to look at
> http://www.aspfaq.com/show.asp?id=2442
> John
>
> "Tom Li" <mrpiiii@.sina.com> wrote in message
> news:eyojRMWYDHA.2592@.TK2MSFTNGP09.phx.gbl...
> > Thanks John,
> >
> > I don't know how to use it after I downloaded xp_smtp_sendmail
procedure.
> >
> > Tom
> >
> > "John Bell" <jbellnewsposts@.hotmail.com> wrote in message
> > news:3f38e335$0$18495$ed9e5944@.reading.news.pipex.net...
> > > Hi
> > >
> > > Usage is described with example on the download page.
> > >
> > > http://www.sqldev.net/xp/xpsmtp.htm
> > >
> > > What is your particular problem?
> > >
> > > John
> > >
> > >
> > > "Tom Li" <mrpiiii@.sina.com> wrote in message
> > > news:Oqn30rMYDHA.652@.TK2MSFTNGP10.phx.gbl...
> > > > Thank you Tony,
> > > >
> > > > I downloaded that file but I don't know how to use it. Could you
give
> me
> > > > more information about it?
> > > >
> > > > thanks,
> > > >
> > > > Tom Li
> > > >
> > > > "Tony Rogerson" <tonyrogerson@.sqlserver.eu.com> wrote in message
> > > > news:eKZeQTKYDHA.2020@.TK2MSFTNGP10.phx.gbl...
> > > > > If you just want to send mails from SQL Server then forget about
> using
> > > > MAPI
> > > > > etc... and download the xp_smtp_sendmail extended stored procedure
> > from
> > > > > sqldev.net, so long as you have an SMTP server then it will work
and
> > its
> > > > > really good!
> > > > >
> > > > > --
> > > > > Tony Rogerson
> > > > > SQL Server MVP
> > > > > http://www.sqlserverfaq.com?mbr=21
> > > > > (Create your own groups, Forum, FAQ's and a ton more)
> > > > >
> > > > >
> > > >
> > > >
> > >
> > >
> >
> >
>|||Hi
I can't say I am a SMTP expert so others might want to chip in!
I am not sure how you would handle authentication as the procedure doesn't
have these parameters. One way may be to have a local server that relays the
mails to the remote server. This would have to be set up so that others
could not hijack your SMTP server! Windows 2000/IIS comes with a SMTP
server.
Some Routers/Firewalls will not reply to PINGS to avoid DOS attacks. You may
want to try telnet, but there is also a @.Ping parameter to xp_smtp. Check
that you should be using the default port, if not may need to specify a
different port using the @.port parameter.
John
"Tom Li" <mrpiiii@.sina.com> wrote in message
news:e9x9n%23XYDHA.1056@.TK2MSFTNGP10.phx.gbl...
> Hi, John
> It is a really great help. I have installed the procedure. But I can't
send
> mail. I guess something wrong with the SMTP server. My SMTP server is
> "263commail.com" which I used in my outlook express. I try the PING
command
> with this server name and get the following message:
> ====================================================> C:\>ping 263commail.com
> Pinging 263commail.com [211.150.100.11] with 32 bytes of data:
> Request timed out.
> Request timed out.
> Request timed out.
> Request timed out.
> Ping statistics for 211.150.100.11:
> Packets: Sent = 4, Received = 0, Lost = 4 (100% loss),
> Approximate round trip times in milli-seconds:
> Minimum = 0ms, Maximum = 0ms, Average = 0ms
> ======================================================> I was told that some server stopped any message from a PING command. Also
my
> outgoing server requires authentication. Is that a problem?
> thanks,
> Tom
>
> "John Bell" <jbellnewsposts@.hotmail.com> wrote in message
> news:3f39e4de$0$15036$ed9e5944@.reading.news.pipex.net...
> > Hi
> >
> > On http://www.sqldev.net/xp/xpsmtp.htm there is section called
> installation
> > which details how to install the extended stored procedure. The other
> > examples of how to call the extended stored procedure can be cut and
> pasted
> > into query analyser... but at a guess you have MSDE, in which case
paste
> an
> > example into a text editor and save the file to run from osql. If you do
> > have MSDE then you may want to look at
> > http://www.aspfaq.com/show.asp?id=2442
> >
> > John
> >
> >
> > "Tom Li" <mrpiiii@.sina.com> wrote in message
> > news:eyojRMWYDHA.2592@.TK2MSFTNGP09.phx.gbl...
> > > Thanks John,
> > >
> > > I don't know how to use it after I downloaded xp_smtp_sendmail
> procedure.
> > >
> > > Tom
> > >
> > > "John Bell" <jbellnewsposts@.hotmail.com> wrote in message
> > > news:3f38e335$0$18495$ed9e5944@.reading.news.pipex.net...
> > > > Hi
> > > >
> > > > Usage is described with example on the download page.
> > > >
> > > > http://www.sqldev.net/xp/xpsmtp.htm
> > > >
> > > > What is your particular problem?
> > > >
> > > > John
> > > >
> > > >
> > > > "Tom Li" <mrpiiii@.sina.com> wrote in message
> > > > news:Oqn30rMYDHA.652@.TK2MSFTNGP10.phx.gbl...
> > > > > Thank you Tony,
> > > > >
> > > > > I downloaded that file but I don't know how to use it. Could you
> give
> > me
> > > > > more information about it?
> > > > >
> > > > > thanks,
> > > > >
> > > > > Tom Li
> > > > >
> > > > > "Tony Rogerson" <tonyrogerson@.sqlserver.eu.com> wrote in message
> > > > > news:eKZeQTKYDHA.2020@.TK2MSFTNGP10.phx.gbl...
> > > > > > If you just want to send mails from SQL Server then forget about
> > using
> > > > > MAPI
> > > > > > etc... and download the xp_smtp_sendmail extended stored
procedure
> > > from
> > > > > > sqldev.net, so long as you have an SMTP server then it will work
> and
> > > its
> > > > > > really good!
> > > > > >
> > > > > > --
> > > > > > Tony Rogerson
> > > > > > SQL Server MVP
> > > > > > http://www.sqlserverfaq.com?mbr=21
> > > > > > (Create your own groups, Forum, FAQ's and a ton more)
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > >
> > > >
> > >
> > >
> >
> >
>|||> I saw there are two procedure names in the code, xp_smtp_sendmail and
> sp_smtp_sendmail.
xp_smtp_sendmail is the extended stored procedure (a DLL file) that you
download from www.sqldev.net and register in SQL Server according to the
instructions on that site.
sp_smtp_sendmail is a wrapper for the call to this stored procedure... you
can simplify the number and/or order of parameters. I have a wrapper for
xp_smtp_sendmail called smtpmail which has only a few of the parameters
(because I don't use many of the functions that come with the xp).
> And we may be in different location with different time zone. Are you in
the
> States. I am in China.
The news server adjusts your posting time (according to your time zone) to
the reader's time zone settings. This is why *most* threads appear to occur
in chronological order; however, if my reply shows up 7 1/2 hours before
your initial post (what does *your* newsreader tell you are the times of my
previous reply, and your message that I replied to?), then either your clock
is fast, or your time zone is incorrect. For more information, see:
http://www.aspfaq.com/5005
http://www.aspfaq.com/2257|||Thanks for your explanation about the procedure name.
You are really a MVP. My time zone was not correct, which was: (GMT)
Casablanca, Monrovia. Now I correct it.
thanks,
Tom
"Aaron Bertrand - MVP" <aaron@.TRASHaspfaq.com> wrote in message
news:uAtAh5ZYDHA.2960@.tk2msftngp13.phx.gbl...
> > I saw there are two procedure names in the code, xp_smtp_sendmail and
> > sp_smtp_sendmail.
> xp_smtp_sendmail is the extended stored procedure (a DLL file) that you
> download from www.sqldev.net and register in SQL Server according to the
> instructions on that site.
> sp_smtp_sendmail is a wrapper for the call to this stored procedure... you
> can simplify the number and/or order of parameters. I have a wrapper for
> xp_smtp_sendmail called smtpmail which has only a few of the parameters
> (because I don't use many of the functions that come with the xp).
> > And we may be in different location with different time zone. Are you in
> the
> > States. I am in China.
> The news server adjusts your posting time (according to your time zone) to
> the reader's time zone settings. This is why *most* threads appear to
occur
> in chronological order; however, if my reply shows up 7 1/2 hours before
> your initial post (what does *your* newsreader tell you are the times of
my
> previous reply, and your message that I replied to?), then either your
clock
> is fast, or your time zone is incorrect. For more information, see:
> http://www.aspfaq.com/5005
> http://www.aspfaq.com/2257
>
>|||Hi,
Your thoughts is correct. I am thinking about to setup a local SMTP server.
Thanks
Tom
"John Bell" <jbellnewsposts@.hotmail.com> wrote in message
news:3f3a19ed$0$15041$ed9e5944@.reading.news.pipex.net...
> Hi
> I can't say I am a SMTP expert so others might want to chip in!
> I am not sure how you would handle authentication as the procedure doesn't
> have these parameters. One way may be to have a local server that relays
the
> mails to the remote server. This would have to be set up so that others
> could not hijack your SMTP server! Windows 2000/IIS comes with a SMTP
> server.
> Some Routers/Firewalls will not reply to PINGS to avoid DOS attacks. You
may
> want to try telnet, but there is also a @.Ping parameter to xp_smtp. Check
> that you should be using the default port, if not may need to specify a
> different port using the @.port parameter.
> John
>
> "Tom Li" <mrpiiii@.sina.com> wrote in message
> news:e9x9n%23XYDHA.1056@.TK2MSFTNGP10.phx.gbl...
> > Hi, John
> >
> > It is a really great help. I have installed the procedure. But I can't
> send
> > mail. I guess something wrong with the SMTP server. My SMTP server is
> > "263commail.com" which I used in my outlook express. I try the PING
> command
> > with this server name and get the following message:
> > ====================================================> > C:\>ping 263commail.com
> >
> > Pinging 263commail.com [211.150.100.11] with 32 bytes of data:
> >
> > Request timed out.
> > Request timed out.
> > Request timed out.
> > Request timed out.
> >
> > Ping statistics for 211.150.100.11:
> > Packets: Sent = 4, Received = 0, Lost = 4 (100% loss),
> > Approximate round trip times in milli-seconds:
> > Minimum = 0ms, Maximum = 0ms, Average = 0ms
> > ======================================================> > I was told that some server stopped any message from a PING command.
Also
> my
> > outgoing server requires authentication. Is that a problem?
> >
> > thanks,
> >
> > Tom
> >
> >
> >
> > "John Bell" <jbellnewsposts@.hotmail.com> wrote in message
> > news:3f39e4de$0$15036$ed9e5944@.reading.news.pipex.net...
> > > Hi
> > >
> > > On http://www.sqldev.net/xp/xpsmtp.htm there is section called
> > installation
> > > which details how to install the extended stored procedure. The other
> > > examples of how to call the extended stored procedure can be cut and
> > pasted
> > > into query analyser... but at a guess you have MSDE, in which case
> paste
> > an
> > > example into a text editor and save the file to run from osql. If you
do
> > > have MSDE then you may want to look at
> > > http://www.aspfaq.com/show.asp?id=2442
> > >
> > > John
> > >
> > >
> > > "Tom Li" <mrpiiii@.sina.com> wrote in message
> > > news:eyojRMWYDHA.2592@.TK2MSFTNGP09.phx.gbl...
> > > > Thanks John,
> > > >
> > > > I don't know how to use it after I downloaded xp_smtp_sendmail
> > procedure.
> > > >
> > > > Tom
> > > >
> > > > "John Bell" <jbellnewsposts@.hotmail.com> wrote in message
> > > > news:3f38e335$0$18495$ed9e5944@.reading.news.pipex.net...
> > > > > Hi
> > > > >
> > > > > Usage is described with example on the download page.
> > > > >
> > > > > http://www.sqldev.net/xp/xpsmtp.htm
> > > > >
> > > > > What is your particular problem?
> > > > >
> > > > > John
> > > > >
> > > > >
> > > > > "Tom Li" <mrpiiii@.sina.com> wrote in message
> > > > > news:Oqn30rMYDHA.652@.TK2MSFTNGP10.phx.gbl...
> > > > > > Thank you Tony,
> > > > > >
> > > > > > I downloaded that file but I don't know how to use it. Could you
> > give
> > > me
> > > > > > more information about it?
> > > > > >
> > > > > > thanks,
> > > > > >
> > > > > > Tom Li
> > > > > >
> > > > > > "Tony Rogerson" <tonyrogerson@.sqlserver.eu.com> wrote in message
> > > > > > news:eKZeQTKYDHA.2020@.TK2MSFTNGP10.phx.gbl...
> > > > > > > If you just want to send mails from SQL Server then forget
about
> > > using
> > > > > > MAPI
> > > > > > > etc... and download the xp_smtp_sendmail extended stored
> procedure
> > > > from
> > > > > > > sqldev.net, so long as you have an SMTP server then it will
work
> > and
> > > > its
> > > > > > > really good!
> > > > > > >
> > > > > > > --
> > > > > > > Tony Rogerson
> > > > > > > SQL Server MVP
> > > > > > > http://www.sqlserverfaq.com?mbr=21
> > > > > > > (Create your own groups, Forum, FAQ's and a ton more)
> > > > > > >
> > > > > > >
> > > > > >
> > > > > >
> > > > >
> > > > >
> > > >
> > > >
> > >
> > >
> >
> >
>|||> But I recommend setting up an SMTP server (e.g. within your
> firewall) that doesn't require outgoing authentication.
I think that is a good way to me. But my current condition is not good
enough to do it so that I have to do it later. Anyway I appreciate your
great help and I do learn a lot from you.
Thank you very much
Tom
"Aaron Bertrand - MVP" <aaron@.TRASHaspfaq.com> wrote in message
news:%23dKH$5ZYDHA.1480@.tk2msftngp13.phx.gbl...
> > Also my outgoing server requires authentication. Is that a problem?
> Yes, that is a problem. You will need another SMTP server, or you will
need
> to use a COM object which supports outgoing authentication (e.g.
> www.aspemail.com). You can instantiate such a COM object from within a
> stored procedure using the sp_OA* stored procedure calls. But I recommend
> setting up an SMTP server (e.g. within your firewall) that doesn't require
> outgoing authentication.
>

No comments:

Post a Comment