Looking for LINQ to SQL N-Tier example

G

Guest

I'm looking for an example / guidelines for leveraging LINQ to SQL in an
N-Tier environment. Specifically I'm looking for an example where there is a
presentation layer, an application layer, and a database. There are plenty
of examples showing how to create LINQ objects and then connect them as
datasources directly to web controls that consume datasources. I"m looking
for a way to create the LINQ objects on the application server and then
propagate them to the web server to have them consumed as datasources there.

Any help is appreciated,
Thanks.
 
J

James Crosswell

groknroll said:
I'm looking for an example / guidelines for leveraging LINQ to SQL in an
N-Tier environment. Specifically I'm looking for an example where there is a
presentation layer, an application layer, and a database. There are plenty
of examples showing how to create LINQ objects and then connect them as
datasources directly to web controls that consume datasources. I"m looking
for a way to create the LINQ objects on the application server and then
propagate them to the web server to have them consumed as datasources there.

If you've already got your linq objects, with all their properties set,
then you just need to return these objects to the client (using Remoting
or WCF or whatever). So you just take the linq examples you already have
an use them in the application server in the methods that are used to
fetch/update/insert/delete the persistent instances of these objects in
the underlying datasource (MSSQL Server).... what goes on between the
client and server has nothing to do with linq though, so the fact that
you're programming n-tier really doesn't matter.

Best Regards,

James Crosswell
Microforge.net LLC
http://www.microforge.net
 
M

Michael Nemtsev, MVP

Hello groknroll,

I recommend you to look at any 3 tier application sample, like there http://www.15seconds.com/issue/011023.htm

and start thinking about the LINQ from "data layer" like LINQ to SQL - it's
simplies way to get tuned to LINQ

after that u will understand where and how apply LINQ to other collections

---
WBR,
Michael Nemtsev [.NET/C# MVP] :: blog: http://spaces.live.com/laflour

"The greatest danger for most of us is not that our aim is too high and we
miss it, but that it is too low and we reach it" (c) Michelangelo


g> I'm looking for an example / guidelines for leveraging LINQ to SQL in
g> an N-Tier environment. Specifically I'm looking for an example where
g> there is a presentation layer, an application layer, and a database.
g> There are plenty of examples showing how to create LINQ objects and
g> then connect them as datasources directly to web controls that
g> consume datasources. I"m looking for a way to create the LINQ
g> objects on the application server and then propagate them to the web
g> server to have them consumed as datasources there.
g>
g> Any help is appreciated,
g> Thanks.
 
G

Guest

Thank you... that makes sense.

James Crosswell said:
If you've already got your linq objects, with all their properties set,
then you just need to return these objects to the client (using Remoting
or WCF or whatever). So you just take the linq examples you already have
an use them in the application server in the methods that are used to
fetch/update/insert/delete the persistent instances of these objects in
the underlying datasource (MSSQL Server).... what goes on between the
client and server has nothing to do with linq though, so the fact that
you're programming n-tier really doesn't matter.

Best Regards,

James Crosswell
Microforge.net LLC
http://www.microforge.net
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top