-->

Jun 30, 2014

Last vs LastOrDefault in LINQ

Last vs LastOrDefault in LINQ
S.NoLastLastOrDefaulf
1Last extension method gives last element from the collection. If there is no element in the collection, it throws error.LastOrDefault extension method gives the last element form the collection, if not gives null.

Jun 27, 2014

Constants Vs Read-only

Constants Vs Read-only
S.NoConstantsRead-only
1Constants are dealt with at compile-time.Read-only variables are evaluated at runtime.
2Constants supports value-type variables.Read-only variables can hold reference type variables.
3Constants should be used when it is very unlikely that the value will ever change.Read-only variables should be used when run-time calculation is required.

Jun 25, 2014

Double.Parse Vs ConvertTo.Double

Double.Parse Vs ConvertTo.Double
S.NoParticularsDouble.ParseConvertTo.Double
1thrown errorthrown error.Doen not thrown error,Return O Value.

Jun 24, 2014

Int.Parse Vs Convert.ToInt32

Int.Parse Vs Convert.ToInt32
S.NoParticularsInt.ParseConvert.ToInt32
1thrown errorthrown error.Doen not thrown error,Return O Value.

Jun 23, 2014

Local Temp Table Vs Global Temp Table

Local Temp Table Vs Global Temp Table
S.NoParticularsLocal Temp TableGlobal Temp Table
1AvailableSQL Server session or connection (means single user).all SQL Server sessions or connections (means all the user).
2DeletedThese are automatically deleted when the session that created the tables has been closed.These can be created by any SQL Server connection user and these are automatically deleted when all the SQL Server connections have been closed.
3Stared with signLocal temporary table name is stared with single hash ("#") sign.Global temporary table name is stared with double hash ("##") sign.

Jun 21, 2014

ComboBox vs List Box

ComboBox vs List Box
S.NoParticularsComboBoxListBox
1SelectOne Data.Multiple Data.
2FacilityDrop Down Facility.Drop up and Drop Down Facility.
3Check Boxcan't Use CheckBox.Can use Check Box.

Dynamic vs Anonymous Type

. Dynamic vs Anonymous Type
S.NoParticularsDynamicAnonymous types
1Run timeDynamic types work at run time by late binding of object properties.Anonymous types cause the compile time errors.
2KeywordDynamic KeywordVar Keyword.

Jun 20, 2014

LINQ Vs DLINQ Vs XLINQ

LINQ Vs DLINQ Vs XLINQ
S.NoLINQDLINQXLINQ
1programming model that introduces queries as a first-class concept into any Microsoft .NET language.an extension to Linq that allows querying a database and do object-relational mapping.an extension to Linq that allows querying XML documents, as well as creating or transforming XML.

Jun 19, 2014

WindowsDefaultLocation vs WindowsDefaultBounds

WindowsDefaultLocation vs WindowsDefaultBounds
S.NoParticularsWindowsDefaultLocationWindowsDefaultBounds
1sizetells the form to start up at a location selected by OS, but with internally specified size.delegates both size and starting position choices to the OS.

Jun 18, 2014

Store Procedure Vs Function

Store Procedure Vs Function
S.NoParticularsStore ProcedureFunction
1ReturnNo return value.Must return Value.
2ParameterInput/Output.Input.
3Callcan't called to Function.can called to Store Procedure.
4Mandatory Input Paramenternot Mandatory.Mandatory.
5DML/SelectAllow DML/Select.Allow Select.
6Exceptioncan be handled.can not be handled .

Jun 10, 2014

Primary Key vs Unique Key

Primary Key vs Unique Key
S.NoParticularsPrimary KeyUnique Key
1null valuecan't accept null values.can accept Only One null value.
2keyonly one Primary key in a table.more than one Unique key in a table.

Jun 9, 2014

Primary Key vs Foreign Key

Primary Key vs Foreign Key
S.NoParticularsPrimary KeyForeign Key
1null valuecan't accept null values.can accept Only One null value.
2keyonly one Primary key in a table.more than one foreign key in a table.

Jun 8, 2014

IENUMERABLE vs IQUERYABLE

IENUMERABLE vs IQUERYABLE
S.NoParticularsIENUMERABLEIQUERYABLE
1NamespaceSystem.CollectionsSystem.Linq
2Suitable forLINQ to Object and LINQ to XML.LINQ to SQL.
3custom querydoesn’t supports.supports custom query using CreateQuery and Execute methods.
4lazy loadingdoesn’t supports.supports.

Jun 7, 2014

ILIST vs IENUMERABLE

ILIST vs IENUMERABLE
S.NoParticularsILISTIENUMERABLE
1Add/Remove ItemSupport.doesn't support.
2Filteringdoesn't support.Support.

Jun 6, 2014

Store Procedure Vs LINQ

Store Procedure Vs LINQ
S.NoParticularsStore ProcedureLINQ
1FasterFaster than LINQ.Slower than Store Procedure.
2DebugNot Allowed.Allowed.
3writing complex queriesBest Way.Not Possible.
4DeploySQL script for deployment.easy and simple.