RUN SQL Server R2 Query based on Outlook Rule/Script

pawanhsharma

Board Regular
Joined
Feb 12, 2013
Messages
64
Hello All,

I guess there might be some way to trigger an SQL Query based on incoming Email. Here is what I want to do. I get several load delete request which I need to then process in SQL by running particular Query based on subject line of the mail. The subject line is predefined to determine which table, what environment and load or delete etc.
Ex: The subject line would be in the format
FullTableName#Environment#Server#RequestNumber#User#Load or DEL
Where the details are separated by "#"
This is fixed format and then I have to use the details and load or delete the data attached in the mail by running SQL Query. The attachment is always in Text format.
The problem is I have to keep track of mails all the time and some time it is on priority so it has to be done within time.
Is there any way I can save all the queries in SQl and trigger one based on subject line and process the attachment.
I guess that is very long and weird request but I believe there is some way to automate this as All the application are VBA compatible.
Thanks in advance.
 

Excel Facts

Using Function Arguments with nested formulas
If writing INDEX in Func. Arguments, type MATCH(. Use the mouse to click inside MATCH in the formula bar. Dialog switches to MATCH.

Forum statistics

Threads
1,225,759
Messages
6,186,864
Members
453,380
Latest member
ShaeJ73

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top