When should I use a CompiledQuery?

后端 未结 5 1288
慢半拍i
慢半拍i 2020-12-08 08:09

I have a table:

-- Tag

ID  | Name
-----------
1   | c#
2   | linq
3   | entity-framework

I have a class that will have the following metho

5条回答
  •  死守一世寂寞
    2020-12-08 08:51

    Compiled queries offer a performance improvement, but it's not huge. If you have complex queries, I'd rather go with a stored procedure or a view, if possible; letting the database do it's thing might be a better approach.

提交回复
热议问题