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: C# Tips, C#.Net, Empty check in C#, isNullorEmpty method in c#, Null check in c#
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: C# Tips, C# Using Statement, Restrict scope of object using statement in c#, Using Statement in C#
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: Common Table Expressions, CTE, SQL Server Developer Tips
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: ado.net, ADO.Net Tips, MSDTC, Transaction Scope
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: C# Tips, C# Yield Keyword, DotNet Tips
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: Relational Database Engine, SQL Server 2005, SQl Server Agent, SQL Server Analysis Services, SQL Server Broker, SQL Server Integration Services, SQL Server Notification Services, SQL Server Replication, SQL Server Reporting Services
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: SET vs SELECT, SQL TIPS
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: C# Tips, C# Tips for ENUM, ENUM, Flag Attributes
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: Application pool, CPU monitoring error, DefaultAppPool, Event ID: 1025, iis, iis warning, Internet Information Services
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: fixed file format, FTP larger files, ftp to mainframe, variable file format




