Data access

TwitterFacebook
Get flash to fully experience Pearltrees

SQL Server 2008 Connection String Samples - ConnectionStrings.com

.NET Framework Data Provider for SQL Server Type .NET Framework Class Library Usage System.Data.SqlClient.SqlConnection Manufacturer Microsoft Standard Security Server = myServerAddress ; Database = myDataBase ; User Id = myUsername ; Password = myPassword ; Trusted Connection Server = myServerAddress ; Database = myDataBase ; Trusted_Connection = True ; http://www.connectionstrings.com/sql-server-2008
http://msdn.microsoft.com/en-us/library/bb738695(v=vs.90).aspx

Adding, Modifying, and Deleting Objects (Entity Framework)

Objects in an object context are instances of entity types that represent data in the data source. You can modify, create, and delete objects in an object context, and Object Services tracks the changes made to these objects. When the SaveChanges method is called, Object Services generates and executes commands that perform the equivalent insert, update, or delete statements against the data source. For more information, see Saving Changes and Managing Concurrency (Entity Framework) .

Mixing LINQ Providers and LINQ to Objects

http://msdn.microsoft.com/en-us/vstudio/ff963710.aspx var records = this .CreateQuery<EntityType>() .Where(item => item.PartitionKey == region) .AsEnumerable() .OrderByDescending(item => item.DateUpdated); Notice the AsEnumerable() call in the middle of the query above. Why do you suppose that was added to this query? Equally important, why do you suppose it was added at that location in the query?

ADO.NET

ADO.NET is a set of classes that expose data access services for .NET Framework programmers. http://msdn.microsoft.com/en-us/library/e80y5yhx.aspx

Working with ObjectSet

[This topic is pre-release documentation and is subject to change in future releases. http://msdn.microsoft.com/en-us/library/ee473442.aspx
http://blogs.msdn.com/b/efdesign/archive/2008/12/02/pluralization.aspx

Pluralization - Entity Framework Design

Unfortunately in the current version of the Entity Framework, which ships in .NET 3.5 SP1, we don't make any attempt to Singularize or Pluralize names when reverse engineering a model from the database. So if, for example, your database has a table called Orders you will get an EntityType called Orders too, which clearly doesn't make for the most read-able code: Orders order = new Orders (); //?
http://msdn.microsoft.com/en-us/library/ee382825.aspx The Entity Data Model (EDM) is a set of concepts that describe the structure of data, regardless of its stored form. The EDM borrows from the Entity-Relationship Model described by Peter Chen in 1976, but it also builds on the Entity-Relationship Model and extends its traditional uses.

Entity Data Model