You are here: Re: Using trigger to notify an assembly of changes. « MsSQL Server « IT news, forums, messages
Re: Using trigger to notify an assembly of changes.

Posted by Hugo Kornelis on 10/13/06 21:35

On 12 Oct 2006 19:31:52 -0700, simo wrote:

>
>I have a requirement to create a sorted list of objects, stored within
>an assembly, and I would like to use a After Insert/Update trigger to
>notify that assembly that something has changed, rather than polling
>the database for changes all the time.
>
>My initial problem is that I need to create a static list so that it
>can be dynamically looked at by other assemblies, but SQL Server won't
>allow me to attach a dll which contains a static method.
>
>Has anyone done something like this? Are there any decent examples
>available anywhere?
>
>any help will be appreciated.

Hi simo,

Not a direct reply to your question - but have you looked into using
Query Notifications rather than using triggers to roll your own
notification solution? Query Notifications are designed specifically to
notify front-end applications when the result of a query has changed.
Note that Query Notifications work only on SQL Server 2005.

Here's a link to the relevant documentation in Books Online:
ms-help://MS.SQLCC.v9/MS.SQLSVR.v9.en/udb9/html/06b1c6fa-3024-4425-bd99-64b6d3c80267.htm

--
Hugo Kornelis, SQL Server MVP

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация