Presentation is loading. Please wait.

Presentation is loading. Please wait.

Eric Nelson Developer & Platform Group Microsoft Ltd

Similar presentations


Presentation on theme: "Eric Nelson Developer & Platform Group Microsoft Ltd"— Presentation transcript:

1 Eric Nelson Developer & Platform Group Microsoft Ltd eric.nelson@microsoft.com http://blogs.msdn.com/ericnel http://twitter.com/ericnel

2 Relational Improved XML UDTs New Filestream Hierarchy ID Date & Time Spatial data Sparse columns and wide tables Filtered indexes Change tracking Table parameters to SP calls Resource governor SP control and monitoring Database compression Declarative management... SQL Server Integration Services VSTA replaces VSA ADO.NET Performance Merge... Reporting Services “IIS free” Tablix New designer... BI Cube design Deisgn alerts Performance...

3 ADO.NET Data Services ADO.NET Entity Framework

4 Accessing data in 1990 ODBC, embedded SQL Accessing data in 2000 ADO, Stored Procedures Accessing data in 2005 ADO.NET, Datasets, DataReaders Accessing data in 2010 ORM baby!

5 What is it? Technique for working with relational tables as if they were objects in memory Intention is to hide away the complexity of the underlying tables and give a uniform way of working with data Why use it? Productivity Retain database independence Notes There are many ORMs for.NET developers already in existence. E.g. LLBLGen Pro http://www.llblgen.com/http://www.llblgen.com/ Nhibernate http://www.hibernate.org/343.htmlhttp://www.hibernate.org/343.html EntitySpaces http://www.entityspaces.net/Portal/Default.aspxhttp://www.entityspaces.net/Portal/Default.aspx Objects vs Classes vs Entities

6

7 What is it? Tools and services to create an Entity Data Model EDM gives ORM to SQL Server, Oracle, DB2 etc Tools and services for consuming an Entity Data Model Why use it? Productivity Complex mapping between entities and database tables Works great with ADO.NET Data Services Notes Strategic but just released...

8 Application model Mapped to a persistence store Comprised of three layers: Conceptual (CSDL) Mapping (MSL) Storage (SSDL) Database agnostic Comprised of: Entities Associations Functions Conceptual Mapping Storage Entity Data Model

9 { Creating the EDM }

10 Entity Client Entity SQL Object Services Entity SQL LINQ To Entities

11 Familiar ADO.NET object model: EntityCommand EntityConnection EntityDataReader EntityParameter EntityTransaction Text-based results Read-only Uses Entity SQL

12 Queries materialized as Objects ObjectContext ObjectQuery Built on top of Entity Client Two query options: Entity SQL LINQ Runtime services: Unit of work Identity tracking Eager/explicit loading

13 LINQ To Entities Object Services Entity SQL Entity Client ADO.NET Provider

14 { Using LINQ to Entities }

15 VendorDB Support MicrosoftSQL Server Oracle Sample, Generic Sample DevartOracle, MySQL, Postgress PhoenixSQLite IBMDB2, Informix Dynamic Server MySQL ABMySQL NpgsqlPostgreSQL OpenLinkMany via OpenLink ODBC or JDBC DataDirectOracle, Sybase, SQL Server, DB2 Firebird

16 LINQ to SQLLINQ to Entities Database Support SQL ServerMany Object Relational Mapping Capabilities SimpleComplex Requires Attributed.NET Code NoYes StatusReleasedJust Released

17 LINQ to SQL var products = from prod in db.Product where prod.Color == "Blue" select prod; LINQ to Entities var products = from prod in db.Product where prod.Color == "Blue" select prod; In general – LINQ to Entities does more – but not always! Only migration that will ever happen is LINQ to SQL migration to LINQ to Entities

18

19 What is it? HTTP access to an object model exposed as RESTful Web Services Data and/or methods Data returned using ATOM or JSON Read/Write Why use it? Easy to expose data over the internet accessible by any client

20 Data Access Layer Entity Framework Relational database Other sources Data Services Runtime Hosting/HTTP Listener CustomCustom Iqueryable/Ienumerable [+ IUpdatable] [+ IUpdatable] HTTPHTTP

21 Resources Res 1 Res 2 Res 3 Res 4 HTTP Request URL VERB Payload HTTP Response Status GET POST PUT DELETE XMLJSON Payload XMLJSON

22 Provide a type with public properties which are; IQueryable, IEnumerable Also get write access if your type implements; IUpdatable Works well with generated code from; ADO.NET Entity Framework (ObjectContext) LINQ to SQL (DataContext*)

23 { Data Services }

24 Data Access technology remained reasonably static Procedural, API access Surfaced the database schema 1990 to 2007 - Tables LINQ – excellent addition to the.NET languages Entity Framework and the EDM – strategic investment Data Services – as easy as it gets? Productivity leap 2008 – Objects

25 http:// blogs.msdn.com/ericnel http:// blogs.msdn.com/ericnel - all the links General ADO.NET Team Blog http://blogs.msdn.com/adonethttp://blogs.msdn.com/adonet Mike in our team http://www.miketaulty.com ( search Entity or LINQ )http://www.miketaulty.com Data Platform Developer Centre http://msdn.microsoft.com/en- gb/data/default.aspxhttp://msdn.microsoft.com/en- gb/data/default.aspx ADO.NET Entity Framework EF DM http://blogs.msdn.com/dsimmonshttp://blogs.msdn.com/dsimmons FAQ http://blogs.msdn.com/dsimmons/pages/entity-framework-faq.aspxhttp://blogs.msdn.com/dsimmons/pages/entity-framework-faq.aspx Entity Framework Design http://blogs.msdn.com/efdesign/default.aspxhttp://blogs.msdn.com/efdesign/default.aspx ADO.NET Data Services Team blog http://blogs.msdn.com/astoriateamhttp://blogs.msdn.com/astoriateam

26 © 2008 Microsoft Ltd. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

27

28 EDM = Entity Data ModelEF = ADO.NET Entity FrameworkESQL = Entity SQLLINQ = Language Integrated QueryCSDL = Conceptual Schema Definition LanguageSSDL = Store Schema Definition LanguageMSDL = Mapping Schema Definition LanguageLambda Syntax = customer.Select(...)Comprehension Syntax = from c in customer...SQL = Structured Query Language

29 Entity Client Entity Data Model SSDLSSDL SQLSQL OracleOracle OtherOther CSDLCSDLMSLMSL ADO.NETADO.NET Object Services ESQL “select o from orders” ESQL LINQ to Entities “from o in orders...” LINQ to Entities “from o in orders...” ADO.NET Data services ProviderProvider ProviderProvider ProviderProvider SSDLSSDL SSDLSSDL HTTPHTTP CustomCustom Interceptors (Query, Update) Interceptors Service Operations (Methods) Entity Data Model

30 REpresentational State Transfer Server-side resources identified by a URI Access is over HTTP, verb tied to action GET to read the value of a resource POST to create a new resource PUT to update an existing resource DELETE to delete a resource Returned data is “plain” – XML or JSON Is this “the death of SOAP”?


Download ppt "Eric Nelson Developer & Platform Group Microsoft Ltd"

Similar presentations


Ads by Google