This project is read-only.
Northwind public OData Service

Category:
TypeProviders.ODataService
Description: Consume Northwind public OData Service published by http://www.odata.org
Code:

type Northwind = Microsoft.FSharp.Data.TypeProviders.ODataService< "http://services.odata.org/Northwind/Northwind.svc/" >

let typeProviderODataSample1() =
let db = Northwind.GetDataContext()

query {
for n in db.Customers do
select n
take 2
}|> Seq.iter (fun n -> printfn "%s\n" n.ContactName)

// sample output
// Maria Anders
// Ana Trujillo


Execution Result:
Maria Anders

Ana Trujillo


Last edited Mar 1, 2012 at 8:04 PM by ttliu2000, version 3

Comments

No comments yet.