January 13th, 2013

Database Change Notifications in ASP.NET using SignalR and SqlDependency

This article shows how to display real time sql server database change notification in ASP.NET using SignalR and SqlDependency object which represents a query notification dependency between an application and an instance of SQL Server. Consider your database is updated or synchronized by windows service in background, you have to display real time updated data. This article explains how to implement it.
Continue reading Database Change Notifications in ASP.NET using SignalR and SqlDependency

April 5th, 2012

SQL Query To Check Money Data Type and Convert it to Decimal Dynamically

Sometimes we need to convert one data type to another data type to map columns in sql server. You might not be allowed to change table structure directly. In this case you’ve to convert in your query or stored procedure. Suppose you’ve to convert money data-type to decimal for greater precision in calculation then you can do it easily using Cast or Convert methods. Continue reading SQL Query To Check Money Data Type and Convert it to Decimal Dynamically

February 26th, 2012

How To Use SQL IN Statement to Select Data Having All Specified Values

Generally, We use SQL Where .. IN Statement to determine whether a specified value matches ANY value in a sub-query or a list. But sometimes we require to get data which have ALL specified values, not ANY value. In this post, we’ll see how to accomplish it. Let’s take an example, Consider following data in Orders table Continue reading How To Use SQL IN Statement to Select Data Having All Specified Values