Today in my current project we are supposed to build an image from Binary data stored in a SQL Server column. AS we know SQL Server allows us to store BLOB (Binary Large Objects) data. Here in our case the situation is as below.
In Source System data (read as Images,Videos or documents(.xls,.ppt,.pptx,.xlsx,.doc,.docx) )is stored in a [...]
Archive for the ‘.NET Framework’ Category
Retrieving BinaryData from SQL Server 2008
Posted in .NET Framework, SQL Server on April 24, 2009 | Leave a Comment »
Resolving the concurrency conflicts in LINQ using Transactions
Posted in .NET Framework, LINQ on April 23, 2009 | 1 Comment »
As we were discussing concurrency options in my previous articles here , we noted that updating the database with SubmitChanges could update a single record or any number of records (even across multiple tables). If we run into conflicts, we can decide how to handle the conflict. However, we didn’t point out previously that if [...]
Handling Concurrency in LINQ to SQL -Part 3
Posted in .NET Framework, LINQ on April 23, 2009 | Leave a Comment »
In my earlier articles I showed how we can handle the concurrency using UpdateCheck. In this articles I will show how to deal with Concurrency Exceptions.
In using the Always or WhenChanged options for UpdateCheck, it is inevitable that two users will modify the same values and cause conflicts. In those cases, the DataContext will raise a [...]
Handling Concurrency in LINQ to SQL -Part 2
Posted in LINQ on April 21, 2009 | Leave a Comment »
In my earlier article here I showed you how to reproduce the concurreny issues in LINQ to SQL. In this article and in the subsequent articles I will write more about how to resolve the conflicts arising out of these concurrency.
USING UpdateCheck :
When SubmitChanges is called on the DataContext, the Update statement is generated and [...]
Handling Concurrency in LINQ to SQL-Part 1
Posted in .NET Framework, LINQ on March 19, 2009 | Leave a Comment »
In a typical production system which is used by multiple users at the same time, we need to take into account the conflicts that arise when two users try to change the same record at the same time. These are generally handled by two types of strategies.
1. Pessimistic Concurrency
2. Optimistic concurrency.
By default LINQ will [...]
Native Code Generation Tool: NGen.exe
Posted in .NET Framework on April 15, 2008 | Leave a Comment »
This tool compiles all of an assembly language into native CPU instructions and saves this file to a disk. At run time when the assembly is loaded, the CLR checks To see whether any precompiled version of the assembly exists, if it exists then the CLR loads this precompiled version so that no code compilation [...]
“Namespaces” and “Assemblies” how they relate each other…………
Posted in .NET Framework on April 3, 2008 | Leave a Comment »
Namespaces allow for the logical grouping of related types. For example System.Web.UI relates all the types related to the web. i.e it provides classes and interfaces that helps us in building ASP.NET server controls and ASP.NET web pages that form the user interface of the web application. Similarly System.Windows.Forms namespace will contain all the classes required for [...]
ArrayList vs List
Posted in .NET Framework on January 21, 2008 | 2 Comments »
What is the difference between an ArrayList and a Generic List Collection of type List<T>?
The article here decently lists out the subtle differences between the above two.
To summarize it if you use list<t> no unboxing is required.
Private Constructors in C#
Posted in .NET Framework on November 16, 2007 | Leave a Comment »
Recently I had a discussion with the technical team to use Constructors in our project and I had a doubt that what does a private constructor do ? What purpose does they solve.So I googled and here I am summarizing the facts.
Firstly, a private Constructor is used when you don’t want to create an object for [...]