Click here to Skip to main content
15,884,099 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello All,

This is my 1st post in CODE PROJECT and new to C#.net(But i have Knowledge in C++ and VB).and started learning about c# and SQL server

I'm creating work allocation and TAT system, (we receive the Job tickets from customer each request has unique id,ticket tat end time )

i just created the windows form that import the excel from my pc and stores the data into SQL server(Table name:W_Allocation).this table have TAT start time,end time and Ticket status for each request.

What i'm expecting from you people is SQL needs to send a mail to me before 2 hour of TAT end time if the ticket status is pending

Someone said SQL Jobs can do this . But i have basic Knowledge in SQL and i dont know how to create SQL jobs programmatically from windows form.

Or is there any other way to do this, looking forward your responses,

Sincerely,
Sathish.K
Posted
Comments
[no name] 28-Nov-12 10:50am    
Have you already created a procedure to send the email? You can create a schdeuled job after you have your email procedure set up, the job will just be you scheduled email procedure with your inputs for the email to send.
Sathish.K4 4-Dec-12 5:31am    
Thanks Mathlab,
Now i learned SQL - Jobs will help me in this.. i'm slowly learning and Practicing(Bec i'm new to SQL) . Thanks for your suggestion :)

1 solution

Hi,

Yes, SQL also have some features that can send message via mail
here is my suggested link for you to check out: http://www.sqlteam.com/article/sending-smtp-mail-using-a-stored-procedure[^]
(by the way i do not own this article, just i dont want to re-write the thing that is there)

I hope this helps,

Regards,
Joven
 
Share this answer
 
Comments
Sathish.K4 4-Dec-12 5:34am    
Hey Joven ,

Really thanks for your link .. Started learning from you people suggestions .. will come and ask , if i have any clarification :)

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900