Hi,
In my application, i am sending mails to the respective approvers who have to approve the pending requests allocated to them.
Currently,i am adding the subscriber using the sql statement : select distinct users from requestapprover.
For every user i am adding the subscriber device info and subscription data.
So, this way it will send mails to only those approvers (subscribers) whose ids are stored. How do I add new subscribers? because this statement will run only once.
Is there a way to add subscribers periodically or a way to run the AddSubscriber.cs periodically, so that the new subscriber can be added.
Currently, only those subscriber which are added at the first are added.
Is this approach good , if not , please suggest one.
Thanks in advance,
Hi navbhan -
>>For every user i am adding the subscriber device info and subscription data.
That sounds right. Each approver would become a subscriber. The device would tell SQLNS how to notify that approver. And the subscription indicates what the approver is interested in. Since you're automatically adding subscribers, you'll want to check to make sure they are not already in the system first.
>>So, this way it will send mails to only those approvers (subscribers) whose ids are stored.
This is where the match rule comes in to play. Rather than sending notifications to all subscribers, the match rule merges the subscription data with the event data and creates notifications.
>>How do I add new subscribers?
I've blogged about creating subscribers in v2.0 and 2005.
http://sqlns.blogspot.com/2006/08/creating-test-subscriptions-in-sqlns.html
http://sqlns.blogspot.com/2005/10/creating-subscribers-in-2005.html
http://sqlns.blogspot.com/2005/09/creating-subscribers-in-v20.html
HTH...
Joe
No comments:
Post a Comment