all groups > sql server notification services > april 2005 >
You're in the

sql server notification services

group:

Application Relationship Map



Application Relationship Map RDV
4/11/2005 6:18:28 PM
sql server notification services: I think an important part of quickly understanding a new application is
knowing how the various entities in the application relate to one
another. Is there relationship map for NS ?

For example, it would show you the relationship between the various
parameters in the instance and app config files as well as the
relationship between the event, subscribers, subscriptions, chronicles
settings, etc.

Any thoughts ?
Re: Application Relationship Map Shyam Pather [MSFT]
4/12/2005 11:22:31 AM
I don't know of any such document for NS.

Though NS can be a bit intimidating at first, if you do the walkthrough in
the Books Online and play with some of the samples, you'll be able to see
pretty quickly how the pieces fit together.

Is there a specific question you have about how to build your application?
Thanks
-shyam
--
Learn more about SQL-NS:
http://www.amazon.com/exec/obidos/tg/detail/-/0672326647/
---------------------------------------------
This posting is provided "AS IS" with no warranties, and confers no rights.
Use of included script samples are subject to the terms specified at
http://www.microsoft.com/info/cpyright.htm.
---------------------------------------------
[quoted text, click to view]

Re: Application Relationship Map Joe Webb
4/13/2005 9:53:29 AM
Roger -

I gave a presentaion on SQLNS in Orlando last year at PASS
(sqlpass.org). In it, I talked about how all the different components
relate to each other. Though not really a map, maybe it'd help a bit.
You can download the ppt file from the downloads section of my site
(http://www.webbtechsolutions.com) if you'd like.

As Shyam said, go through the Stocks walkthrough; it'll help put the
pieces together for you.


HTH...
Joe Webb
SQL Server MVP

~~~
Get up to speed quickly with SQLNS
http://www.amazon.com/exec/obidos/tg/detail/-/0972688811




[quoted text, click to view]
Re: Application Relationship Map RDV
4/14/2005 11:28:14 AM
The examples tend to trigger off of absolute conditions. For example,
let me know when a stock price is > a value. Can you create a
subscription rule where the operator is included in the subscription?
For example, a single subscription template would allow you to
determine when the stock is <, >, = to a value. The user would choose
the operator when setting up the subscription.
What would this look like?
Re: Application Relationship Map Joe Webb
4/16/2005 8:19:59 AM
RDV -

The current version of SQLNS doesn't really provide a *direct* way for
you to allow users to select the operator for the subscription. But
there are a couple of ways to do it leveraging the flexibility of the
current architecture.

First you can, of course, create multiple subscription classes, one for
each possibility. In your stock example, there'd be three - >, <, and =.
This is straightforward to do so I won't expound on this option.

But, there is a way to do it with just one subscription class. You can
create the subscription class with multiple conditions, allowing the
user to specify only the ones that apply to them.

For example, let's say the event data has StockSymbol and StockPrice as
it's fields. A subscription class could be created that has StockSymbol,
PriceGreaterThan, PriceLessThan, and PriceEqualTo. (I'm using your
example, but realistically the PriceEqualTo wouldn't be very useful.)

Your matching rule needs to make some of these conditions optional by
including some OR's in the WHERE clause. Something like this:

SELECT StockNotify(<parameter list goes here>)
FROM StockEvents e, StockSubscriptions s
WHERE e.StockSymbol = s.StockSymbol
AND ((s.PriceGreaterThan IS NULL) OR (e.StockPrice > s.PriceGreaterThan))
AND ((s.PriceLessThan IS NULL) OR (e.StockPrice < s.PriceLessThan))
AND ((s.PriceEqualTo IS NULL) OR (e.StockPrice = s.StockPrice))

Your Subscription Management Application would then be designed to allow
users to specify a stock symbol and one or more of the conditions. A
stock symbol is required, but the others are not (You should of course
require at list one, but that's a front end issue).



HTH...
Joe Webb
SQL Server MVP

~~~
Get up to speed quickly with SQLNS
http://www.amazon.com/exec/obidos/tg/detail/-/0972688811



[quoted text, click to view]
Re: Application Relationship Map MarkSW
4/18/2005 9:04:04 AM
Thanks for the link. These slides look great! Do you mind if I crib from
the liberally for an internal presentation, with attribution?

[quoted text, click to view]
Re: Application Relationship Map Joe Webb
4/18/2005 11:13:38 AM
Not at all! (Thanks for asking, though.)

Hope they find the information useful!


HTH...
Joe Webb
SQL Server MVP

~~~
Get up to speed quickly with SQLNS
http://www.amazon.com/exec/obidos/tg/detail/-/0972688811



[quoted text, click to view]
AddThis Social Bookmark Button