如何通过MS-SQL和ASP.NET立即发送和接收 [英] How can i send and recieve instantly through MS-SQL and ASP.NET

查看:75
本文介绍了如何通过MS-SQL和ASP.NET立即发送和接收的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Pls伙计们,

我目前正在使用工具跟踪软件,它需要工人在石油钻井平台上工作时登录并请求工具/设备。

我在办公室有一个控制面板,以便立即发送项目请求,它可以立即被视为通知。

如何触发即时更新。从看到的情况来看,使用Ajax计时器搜索数据库会给服务器带来麻烦。

任何帮助都将被接受..提前感谢

Pls guys,
Am currently working on a tool-tracking software and it requires workers to login and request for Tools/equipments while working on an oil rig.
Am having a control panel for those at the offices so that immediately the request for items are sent, it can been seen instantly as a notification.
How can i trigger the instant update. From what am seeing, using an Ajax timer to search the database will trouble the server.
Any help will be accepted.. Thanks in advance

推荐答案

我假设您正在使用SQL Server数据库。请参阅此链接,这可能会有所帮助。



使用查询通知[msdn] [ ^ ]



问候..:笑:
I assume you are using SQL server database. Refer this link it might be helpful.

Using Query Notifications [msdn][^]

Regards..:laugh:


如果这是一个Web应用程序,您正在使用IIS来提供您的asp页面(我假设你用标记的方式),你可能想看一下SignalR。它是一个向Web客户端发送通知的框架,没有轮询的开销。



使用SignalR,通知的逻辑被移入服务器。因此,当您的用户请求某些内容并且该请求被授予时,当您将该请求发送回客户端时,您也可以通过SignalR通知任何听众。该体系结构超出了这一响应范围,但SignalR上有很多内容以及如何在连接的Web应用程序的通知中使用它。
If this is a web app an you are working against IIS serving up your asp pages (which I assume by what you tagged the question with) you will probably want to look at SignalR. It is a framework for notifications to web clients without the overhead of polling.

With SignalR, the logic for notifications is moved into the server. So when your user requests something and that request is granted, when you are sending that back to the client you can also notify any "listeners" via SignalR. The architecture is beyond this response but there is a lot out there on SignalR and how to use it in notification of connected web apps.


这篇关于如何通过MS-SQL和ASP.NET立即发送和接收的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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