locked
Customization Points RRS feed

  • Question

  • Looks like LinQ to SQL library is a very close system that does not allow any customization at all, unless you want to write a complete new provider.
    I am just wondering if anybody know where I can customize the generated SQL. Or add new aggregates, supported operators, functions .. etc to the existing provider. It's unpratical to create a new provider give all the complicated SQL statements you need to create.
    Thursday, January 28, 2010 9:30 AM

Answers

  • There's some room for customization, but some things (e.g. custom aggregators etc) requires playing around with reflection.

    If you want more control over the provider itself, take a look at Matt Warren's IQueryable provider:
    http://blogs.msdn.com/mattwar/

    It provides functionality very similar to the L2S IQueryable provider but it is open source and you can use it as a base for a custom IQueryable provider. Comes with support for other DBs besides MSSQL too...

    .
    Kristofer - Huagati Systems Co., Ltd.
    Cool tools for Linq-to-SQL and Entity Framework:
    huagati.com/dbmltools (add-in with new features for Visual Studio 2008's L2S and EF designers)
    huagati.com/L2SProfiler (Query profiler for Linq-to-SQL and LLBLGen Pro)
    Thursday, January 28, 2010 12:47 PM
    Answerer