SQL to LINQ

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • shapper

    SQL to LINQ

    Hi,

    I wonder, is there some tool that transforms SQL procedures to
    LINQ? :-)

    I want to use LINQ but I have so much work done in SQL that would be
    great to transform my SQL code to LINQ.

    Thanks,
    Miguel
  • Michel Walsh

    #2
    Re: SQL to LINQ

    Not an answer to your question, but a question: LINQ will translate what you
    throw at it into an expression tree, tree which will be re-evaluated to
    produce an SQL statement. That seems slower than using the already known SQL
    statement. Why would you want to do that in the first place?

    Furthermore, about your question, LINQ does not have concepts for every
    thing MS SQL Server exposes through its SQL, neither ( I think, can be
    wrong ) can a lambda expression for an expression tree provide some flow
    control, at least, not as T-SQL can. I am not even sure an expression tree
    can hold more than one SQL 'statement' (such as multi-line stored procedure
    which can update, delete, and append rows to multiple tables within its
    execution). So the translation tool will be quite limited, no?


    Vanderghast, Access MVP


    "shapper" <mdmoura@gmail. comwrote in message
    news:1ec0c4d3-11ff-40d6-b8e0-f870fdc403e9@a1 g2000hsb.google groups.com...
    Hi,
    >
    I wonder, is there some tool that transforms SQL procedures to
    LINQ? :-)
    >
    I want to use LINQ but I have so much work done in SQL that would be
    great to transform my SQL code to LINQ.
    >
    Thanks,
    Miguel

    Comment

    Working...