Quantcast
Channel: Microsoft SQL Server
Viewing all articles
Browse latest Browse all 4871

SQL Trigger

$
0
0

Hi Guys,

I hope that someone in our clever community have an answer for me on the following:

I've created a few sql tables . These tables gets update when an Invoice is raised within my application system (ERP SAP B1) . The problem I have is that my Stored Proc takes some time to run and slows down the Invoicing process.

The only problem why I can't use a service /Task scheduler to run the Stored proc every night is because the tables get updated on a customer level per Invoice . So I need my stored proc to run before the same customer places another invoice which a customer could place up to threeinvoices a day.

Is there any way I could add a query in transact notification that will do the following:

Before exec the stored proc look at the following :

If this customer(Customer that's currently being invoiced)had aninvoice placed today

then...


Viewing all articles
Browse latest Browse all 4871

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>