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

sql server notification services : XSLT formatter for digest delivery


Ben Chan
8/1/2004 6:21:10 PM
Dear All
I defined a scheduled subscriptions and it works fine, and
I want to use digest delivery to group the notification
together,but I don't know what modifications are needed in
the XSLT formatter,simply adding a xsl:for-each statement
to enumerate all the items?
Thanks
Bob Beauchemin
8/1/2004 8:59:32 PM
Hi Ben,

For digest delivery, you will receive one <notifications> element for the
entire message and one <notification> element for each item. Use the
NoOp.xslt (in one of the samples) if you want to confirm the format. Have a
look at the stock sample XSLT. It will work fine in digest or non-digest
mode.

Long answer:

You should have an XSLT with your "greeting" when you match the
<notifications> element (eg "Here's the baseball game scores you requested".
<notifications> should also have an <xsl:apply-templates> as you are going
to match each <notification> element (your detail items). When you match
<notification> (your detail items), you are going to have as many matches as
you have items. So it should look something like this:
<xsl:value-of select="team1"/> <xsl:value-of select="score1"> <xsl:value-of
select="team2"/> <xsl:value-of select="score2">

That will produce one detail (individual baseball game score) for each item
(game).



Cheer,
Bob Beauchemin
http://staff.develop.com/bobb


[quoted text, click to view]

Ben Chan
8/1/2004 9:22:00 PM
Dear Bob
Thanks a lot for your reply!, I got it working now
:)
cheers
Ben

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