Post on 14-Feb-2016
description
dive into linqivan towlsonmindscape
imagine there’s no sql
three worlds
ObjectsXMLRelational
ObjectsXMLRelationalWeb ServicesNoSQL
ObjectsXMLRelationalWeb ServicesNoSQLWMIEmail
ObjectsXMLRelationalWeb ServicesNoSQLWMIEmail
three worlds…for large values of three
“queries should just ‘be there,’like for loops”
anders hejlsberg
linqlanguage integrated query
language syntax
standard query operators
query implementation framework
language syntax
standard query operators
query implementation framework
putting the lin into linq
LINQ…
…to Objects
IEnumerable
…to XML
XDocumentfamily
…to SQL
Table<T>SQL Server
language syntax
standard query operators
query implementation framework
language syntax
standard query operators
query implementation framework
when syntax runs out
everything is query operators
language syntax
standard query operators
query implementation framework
language syntax
standard query operators
query implementation framework
I plan to query overONE… MILLION… OBJECTS!
what is the meaning ofx.Select(…)?
what is the meaning ofx.Select(…)?
IEnumerable<T> x;
IQueryable<T> x;
what is the meaning ofx.Select(…)?
IEnumerable<T> x;Enumerable.Select(x, …)
IQueryable<T> x;Queryable.Select(x, …)
IQueryable<T> x;Queryable.Select(x, …)
Table<T> x;Queryable.Select(x, …)
Queryable
IQueryProvider
SQL Entities LightSpeed NH ….
Queryable
IQueryProvider
SQL Entities LightSpeed NH ….
Queryable
IQueryProvider
SQL Entities LightSpeed NH ….
Expression tree
IQueryable
.Provider
Native query
xs.Where(…).Select(…) Table<X>
SELECT …FROM X
WHERE …
linq to sql
xs.Where(…)
.Select(…)Query<X> Find<X>(qx)
linq to lightspeed
xs.Where(…).Select(…) WmiQuery<X> WqlObjectQuer
y
linq to wmi
Expression tree
IQueryable
.Provider
Native query
language syntax
standard query operators
query implementation framework
language syntax
standard query operators
query implementation framework
thinking in linq
what is a query?
what is a query?extract, transform and load
what is a query?‘what am i interested in’
i am interested in…drag and drop
i am interested in…a mouse down
followed by mouse movesuntil i get a mouse up
ObjectsXMLRelationalalmostanythingactually…
ObjectsXMLRelationalalmostanythingactually…
“queries should just ‘be there,’like for loops”
anders hejlsberg
thanks!
ivan@mindscape.co.nzwww.mindscape.co.nz
ivan@hestia.cchestia.typepad.com/flatlander