Yukon "Query Notification": a life saver

At the Israeli SQL user group today we had a special visit: Roger Woter - PM at Microsoft. he talked about the Service broker in Yukon. very cool stuff. However I learned a little thing that I think is absolutely fabulous:
 
One of the coolest new features to me in Yukon will be a little thing called "Query Notification". What's that?
I'll give you a hint.
Ever used the ASP.Net Cache object? you know how it has a cache expiry period that can be based upon a time span or a file changing on disk? What's the thing missing most from this functionality? that's right - auto-expiry when the data that you cached changes in the database. It's just not there. People have to go through hoops to find out when data has changed. Not anymore.
 
With Yukon you can "signal" to the server with the same query that you used to fetch the data you have in memory, and if any row in one of the tables that is in the query is changed, inserted or deleted (meaning running the query now will yield different results) you'll get an automatic notification of this that will be sent to a special queue on which you can listen on and re-cache your query with the new data. no more hopping around trying to know if something changed.
Thank you thank you thank you.
:)
 
Published Tuesday, September 07, 2004 12:59 AM by RoyOsherove
Filed under:

Comments

Wednesday, September 08, 2004 7:38 AM by Anatoly Lubarsky

# re: Yukon "Query Notification": a life saver

hm, this way you can do it today, but it is not so effective, imho
Sunday, September 12, 2004 6:58 AM by Leon Langleyben

# re: Yukon "Query Notification": a life saver

And the best thing: You don't even need Yukon for it. Cache invalidation future can be configured in SQL Server 7/2000 using aspnet_regsqlcache.exe command line tool.
Wednesday, October 06, 2004 5:14 PM by Jared Evans

# re: Yukon "Query Notification": a life saver

Hi,

2 quick questions:

If I used WinForm rather than ASP.NET then the application in question would be getting a live notification from Yukon and I could handle it right there on the spot? For my application, I would require very timely response to any changes in the database.

Also, If the user of the application is only watching certain rows in a table of a database, such as those rows matching his/her userID, would that user only get an notification if only those certain rows got updated?

Jared