Tech Guy on April 26th, 2010

Purpose : Returns true if the value is either null or Empty String (“”)
Eg :

String a = “”;
If (String.IsNullOrEmpty(a))
{
Console.WriteLine(“a is either null or empty string”);
}

Tags: , , , ,

Tech Guy on April 26th, 2010

Purpose : Using statement can be used to restrict the scope of an object…  The object will not be available outside the block and will be disposed of as soon as the block is completed.
Eg :

using (DataSet SomeLargeDataSet = Bll.getLargeData())
{
// Perform Action with SomeLargeDataSet
}
// SomeLargeDataSet [...]

Tags: , , ,

Tech Guy on April 26th, 2010

Purpose : A common table expression (CTE) can be thought of as a temporary result set that is defined within the execution scope of a single SELECT, INSERT, UPDATE, DELETE, or CREATE VIEW statement. A CTE is similar to a derived table in that it is not stored as an object [...]

Tags: , ,

Tech Guy on April 26th, 2010

Purpose: Transaction Scope is very helpful to maintain transaction across multiple Connection.  Even when the connections are to two different database.
Usage: Transaction Scope is generally used, when we need to perform ACID actions across various connection as one batch…  (ie… If one action in any one [...]

Tags: , , ,

Tech Guy on April 21st, 2010

The yield keyword signals to the compiler that the method in which it appears is an iterator block. The compiler generates a class to implement the behavior that is expressed in the iterator block. In the iterator block, the yield keyword is used together with the return keyword to provide a value to the enumerator [...]

Tags: , ,

Tech Guy on April 21st, 2010

SQL Server 2005 – Relational Database Engine
Database Engine is the primary component of SQL Server 2005, It is the Online Transaction Processing (OLTP) engine for SQL Server. It is responsible for the efficient storage, retrieval, and manipulation of relational and Extensible Markup Language (XML) formatted data. It is highly optimized for transaction processing
[...]

Tags: , , , , , , , ,

Tech Guy on April 21st, 2010

Following are the difference between SET and SELECT while using for DML
1.   SET can assign only one variable at a time… SELECT can assign multiple variable in one line
2.   If assigning from Query, SET can assign only scalar values
3.   If query returns multiple values / rows, SET raises an error… Select simply assigns one row [...]

Tags: ,

Tech Guy on April 21st, 2010

Purpose : Used to represent Enum values in combinations… ie.  Flags Attribute indicates that an enumeration can be treated as a bit field; that is, a set of flags.
Example:

// Example of the FlagsAttribute attribute.
using System;

class FlagsAttributeDemo
{
// Define an Enum without FlagsAttribute.
enum SingleHue [...]

Tags: , , ,

This warning in event log will cause the high CPU usage and leads to the service unavailable error in IIS. This issue is due to enable CPU monitoring.

Tags: , , , , , ,

Tech Guy on February 24th, 2010

FTP files to mainframe In order to FTP the file to Mainframe we have to use: put < path/filename1 > < ’filename2’ > (put command is used when we logged to one server and are transferring the file to different server) or get [...]

Tags: , , ,