I have a table that has a date/time stamp in it. When this time expires (sort of like an auction is over) I want it to trigger an event.
I know how to write a DTS to run every 5 minutes or whatever and run a query to see if the time expired and to send the emails, but this wil run every 5 minutes. These items might only end once a week. Seems like a lot of overhead for such a small task.
So I was wondering if I can create a trigger for that time, but I see they are mostly for inserts, updates and deletes. I am not doing any of those things.
Here is an example of my select query:
Then I will email Purchasing, QuoteID is closed for bidding.
Any Ideas? Examples are most helpful.
I know how to write a DTS to run every 5 minutes or whatever and run a query to see if the time expired and to send the emails, but this wil run every 5 minutes. These items might only end once a week. Seems like a lot of overhead for such a small task.
So I was wondering if I can create a trigger for that time, but I see they are mostly for inserts, updates and deletes. I am not doing any of those things.
Here is an example of my select query:
Code:
SELECT QuoteID, BidClose FROM BidHeader WHERE BidClose < getdate() AND BidComplete = 0
Any Ideas? Examples are most helpful.