h1.post-title { color:orange; font-family:verdana,Arial; font-weight:bold; padding-bottom:5px; text-shadow:#64665b 0px 1px 1px; font-size:32px; } -->

Pages

Difference between Optimistic and Pessimistic locking

In Pessimistic locking when user wants to update data it locks the record and till then no one can update data. Other user’s can only view the data when there is pessimistic locking
In 
Optimistic locking multiple users can open the same record for updating, thus increase maximum concurrency. Record is only locked when updating the record

Difference between IN and BETWEEN, that are used inside a WHERE clause

   The BETWEEN clause is used to fetch a range of values, whereas the IN clause fetches data from a list of specified values.

Define Data Provider

A set of libraries  that is used to communicate with data source.
Eg: SQL data provider for SQL,  Oracle data provider for Oracle, OLE DB data provider for access, excel or   mysql.

New Features in ADO.NET Entity Framework 4.0

Today , we see the "New Features and Enhancements in ADO.NET Entity Framework 4.0"            ADO.NET Entity Framework 4.0 ships with Visual Studio 2010 and includes the following new features and enhancements:
  1. persistence ignorance
  2. lazy loading
  3. self-tracking entities
  4. POCO change tracking
  5. model-first development
  6. built-in functions and model-defined functions

SQL Server Naming conventions and Standards

Today , we will discuss about SQL Server Name Conventions and Standards

  1. Table >> tbl >>tblEmployees
  2. Primary Key Constraint >> PK >>PK_EmployeeId
  3. Foreign Key Constraint>> FK >> FK_Employeeid
  4. Unique Key Constraint>> UQ >>UQ_employee_EmailId
  5. Default Constraint >> DF >> DF_Employee_IsActive
  6. Check Constraint >> CHk >> CHK_Employee_DOB
  7. User defined Store Procedure >> usp Eg:usp_Insert_Employee
  8. User Defined Functions >> fn >> fn_CalculateAge
  9. Views >> vw >> vw_OrderDetails
  10. Triggers >> trg >> trg_Del_Employee
  11. Indexes >> IX >>IX_EmployeeEmailId

Supporting Namespace in Dotnet 4.5


S.NoParticular.Net 3.0.Net 3.5.Net 4.0.Net 4.5
1Microsoft.Build.Tasks.WindowsYYYY
2Microsoft.Win32YYYY
3Microsoft.Windows.ThemesYYYY
4System.Collections.ObjectModel YYYY
5System.Collections.SpecializedYYYY
6System.ComponentModel YYYY
7System.DiagnosticsYYYY
8System.IOYYYY
9System.IO.PackageYYYY
10System.PrintingYYYY
11System.Printing.IndexedPropertyYYYY
12System.Printing.InteropYYYY
13System.Security.PermissionsYYYY
14System.Security.RightsManagementYYYY
15System.WindowsYYYY
16System.Windows.AnnotationsYYYY
17System.Windows.Annotations.StorageYYYY
18System.Windows.AutomationYYYY
19System.Windows.Automation.PeersYYYY
20System.Windows.Automation.ProviderYYYY
21System.Windows.Automation.TextYYYY
22System.Windows.ControlsYYYY
23System.Windows.Controls.PrimitivesYYYY
24System.Windows.ConvertersYYYY
25System.Windows.DataYYYY
26System.Windows.DocumentsYYYY
27System.Windows.Documents.DocumentStructuresYYNY
28System.Windows.Documents.SerializationYYYY
29System.Windows.Forms.IntegrationYYYY
30System.Windows.InkYYYY
31System.Windows.InputYYYY
32System.Windows.Input.StylusPlugInsYYYY
33System.Windows.InteropYYYY
34System.Windows.Markup (shared)YYYY
35System.Windows.Markup.LocalizerYYYY
36System.Windows.Markup.PrimitivesYYYY
37System.Windows.MediaYYYY
38System.Windows.Media.AnimationYYYY
39System.Windows.Media.ConvertersYYYY
40System.Windows.Media.EffectsYYYY
41System.Windows.Media.ImagingYYYY
42System.Windows.Media.Media3DYYYY
43System.Windows.Media.Media3D.ConvertersYYYY
44System.Windows.Media.TextFormattingYYYY
45System.Windows.NavigationYYYY
46System.Windows.ResourcesYYYY
47System.Windows.ShapesYYYY
48System.Windows.ThreadingYYYY
49System.Windows.XpsYYYY
50System.Windows.Xps.PackagingYYYY
51System.Windows.Xps.SerializationYYYY
52UIAutomationClientsideProvidersYYYY

Supporting Namespace for Sliverlight in Net


S.NoParticularSliverlight
1 Microsoft.Win32 Y
2 Microsoft.Windows.Themes Y
3 System.Collections.ObjectModel Y
4 System.Collections.Specialized Y
5 System.ComponentModel Y
6 System.Diagnostics Y
7 System.IO Y
8 System.Security.Permissions Y
9 System.Windows Y
10 System.Windows.Automation Y
11 System.Windows.Automation.Peers Y
12 System.Windows.Automation.Provider Y
13 System.Windows.Automation.Text Y
14 System.Windows.Controls Y
15 System.Windows.Controls.Primitives Y
16 System.Windows.Data Y
17 System.Windows.Documents Y
18 System.Windows.Documents.DocumentStructures Y
19 System.Windows.Documents.Serialization Y
20 System.Windows.Forms.Integration Y
21 System.Windows.Ink Y
22 System.Windows.Input Y
23 System.Windows.Interop Y
24 System.Windows.Markup (shared) Y
25 System.Windows.Media Y
26 System.Windows.Media.Animation Y
27 System.Windows.Media.Effects Y
28 System.Windows.Media.Imaging Y
29 System.Windows.Media.Media3D Y
30 System.Windows.Navigation Y
31 System.Windows.Resources Y
32 System.Windows.Shapes Y
33 System.Windows.Threading Y


Calling Constructor from another Constructor

Yes , it is possible. Please check this link

Constructor in C#.net

              A constructor is a method in the class which gets executed when its object is created. Usually, we put the initialization code in the constructor. 

Validate Text Box

Introduction:
      Today, we discussed about How to validate Text Box with Error Provider in C#.Net? .
Conditions:
    TextBox should enter only integer.
    create one validation event for integer

Here the Code:
protected void textBox1_Validating (object sender,
   System.ComponentModel.CancelEventArgs e)
{
   try
   {
      int x = Int32.Parse(textBox1.Text);
      errorProvider1.SetError(textBox1, "");
   }
   catch (Exception ex)
   {
      errorProvider1.SetError(textBox1, "Not an integer value.");
   }
}

Call this event in constructor
this.textBox1.Validating += new
System.ComponentModel.CancelEventHandler(this.textBox1_Validating);