监视在SQL Azure中数据的变化 [英] Monitor data changes in SQL Azure

查看:144
本文介绍了监视在SQL Azure中数据的变化的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有没有办法当插入SQL Azure的数据发生变化,或当新数据得到通知?我想将通知发送到ASP.NET Web应用程序和推送通知到的Windows Phone。我知道的SqlDependency类和查询通知被用于监视SQL Server 2008数据库的数据更改,但SQL Azure不支持这个呢。

Is there a way to to get notifications when SQL Azure data changes or when new data is inserted? I would like to send notifications to an ASP.NET web application and push notifications to a Windows Phone. I know that the SqlDependency class and Query notifications are used to monitor SQL Server 2008 database data changes but SQL Azure doesn't support this yet.

推荐答案

很抱歉,但你没有比滚动自己的通知机制提供的其他任何选项。一个你可以做到这一点的方法之一是在要监视和测试的字段级更新,事件存储在二级表的表创建触发器和code您的应用程序读取特定频率的那些事件。该 COLUMNS_UPDATED功能可以帮助你找出哪些领域是一个触发器中改变。

Sorry but you don't have any options available other than rolling your own notification mechanism. One of the ways you could do this is to create triggers on the table you want to monitor and test for field-level updates, store the event in a secondary table, and code your application to read those events on a specific frequency. The COLUMNS_UPDATED function can help you figure out which fields were changed inside a trigger.

这篇关于监视在SQL Azure中数据的变化的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆