使用代理服务将表更改通知到.net应用程序 [英] Notify table changes to .net application using broker service

查看:41
本文介绍了使用代理服务将表更改通知到.net应用程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个SQL Server表"tblData".它包含固定的行数(300-500行).这些行中的值将由服务器中运行的.NET应用程序根据一些输入来更新.
将有20-30个客户访问服务器.如果该表中发生任何更改,应通知所有客户端.之后,客户端将查询表并用于进一步处理.我打算通过SQLDependency类进行操作.

我的查询是:

1.考虑到表的大小,没有客户端,也没有对表的访问权,对表(锁定)来说会不会有问题?
2.我想通过正在通过代理服务在服务器中运行的值(行ID和新列值)从正在更新表的应用程序(.NET)中更新表.

I have a SQL server table ''tblData''. It contains fixed no of rows(300 - 500 rows). Values in those rows will be updated by a .NET application running in server based on some inputs.
There will 20-30 clents accessing server. All the clients should be notified if any changes occured in that table. After that the client will query the table and use for further processing. I am planning to do through SQLDependency class.

My queries are:

1. Considering the table size,no of clients and no of access to the table, will it be a problem for table(locking)?
2. I want to pass the values(row ID & New column value) which are updating the table from the application(.NET) updating it, running in the server thru broker service.

推荐答案

2)这不是Service Broker的用途或使用方式

也许这会给你一些想法
使用SqlDependency进行数据更改事件 [
2) That is not what Service Broker is for or how it is used

Maybe this will give you some ideas
Using SqlDependency for data change events[^]


这篇关于使用代理服务将表更改通知到.net应用程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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