Groups | Blog | Home
all groups > sql server notification services > october 2004 >

sql server notification services : Columns in events, or from join?


brooks NO[at]SPAM frnk.com
10/13/2004 4:37:34 PM
Hi, everyone. I'm getting started with notification services and so
far it's been a blast.

I've got a question about best practices: is it generally better to
define events using the minimum of columns, and then join those
columns against application tables in the notification rule, or to
just put all of the columns needed for notifications right into the
event and have the application submit the events with all of the data?

Thanks
Colin Meek [MSFT]
10/14/2004 6:25:41 AM
Let's call the case where the event data is contained in the event class
scenario A, and the case where the event data is contained in some
referenced application table scenario B:

A: EventClass(Data)
B: EventClass(DataId), EventData(DataId, Data)

Scenario A has the advantage in terms of simplicity, schema normalization
(in some cases) and <Rule><Action> query cost.

Scenario B can -- despite the increased complexity of the join -- offer
performance advantages when the event class contains a lot of data or when
information is shared between many events. You _must_ use this approach if
"Data" includes XML, TEXT, NTEXT, or other unsupported data types.

Generally, scenario A is the best choice unless you need to incorporate data
types not supported for an event class definition.

-Colin Meek [MSFT]

--
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.

Please do not send e-mail directly to this alias. This alias is for
newsgroup purposes only.
--

[quoted text, click to view]

Joe Webb
10/14/2004 11:07:49 AM
This is especially true when the other data lives on a remote server and
heterogenous queries would be required to pull all of the data together
in Scenario B.


HTH...
Joe Webb

~~~
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