I have the following code in C#:
public async Task<List<Table>> GetRows()
{
return await db.Table.ToListAsync();
}
where db is an EF 6 DbContext.
How do I write the equivalent thing in F# assuming that I access the same DbContext?
I came up with this code but I am stuck:
let getRows = async {
let q = query {
from r in db.Table
select r
}
q |> Seq.map(fun row -> ...) // <-- Here I might want to do some custom function
}
Thank you