MSSQL回调函数asp.net网站 [英] MsSQL callback function to asp.net website

查看:141
本文介绍了MSSQL回调函数asp.net网站的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在看,当涉及到制作SQL服务器上的一个触发的可能性,触发我的网站功能(无需轮询它每隔x分钟)。

I am looking at the possibilities when it comes to making a trigger on a SQL server, trigger a function on my website (without having to poll it every x minutes).

其原因是,我试图对我的SQL数据到它的时候有改动它设置为表将只更新高速缓存中创建一个缓存服务。的想法将是它们在数据库中的物品,很少改变,并且使用频率足以要跳过的昂贵行程到数据库中。

The reason being, I am attempting to create a caching service for my SQL data to where it will only update the cache when there are changes to the table it is setup for. The idea would be that items which are in the database, rarely changed and used often enough to want to skip the expensive trip to the database.

任何想法将是巨大的,谢谢。

any ideas would be great, thanks.

推荐答案

SQL Server有CLR集成(虽然最后的检查,只能用.NET 2.0)。这意味着您可以从一个函数/存储过程/查询运行一些装配标记。下面是文档:

SQL Server has CLR integration (albeit at last check, only with .NET 2.0). This means you can run some assembly marked as such from a function/stored-procedure/query. Here is the documentation:

MSDN的SQL Server CLR描述

您可以编写与SQL Server中暴露的方法的组装和直接运行它,从而完成你在你所选择的C#/ VB / .NET语言循环。这可能是交到如果以上答案有你要找的内容有点重,但我pretty确保提供你控制一切最灵活的方法。

You can write an assembly with an exposed method for SQL Server and run it directly from there, thus completing your loop in C#/VB/.NET language of your choosing. This may be a little heavy handed if none of the above answers have what you're looking for, but I'm pretty sure offers the most flexible approach where you control everything.

这篇关于MSSQL回调函数asp.net网站的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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