how to translate a linq expression for example
var query = (from article in ArticleRepository.GetAll()
join read in ArticleReadRepository.GetAll() on read.ArticleId equals article.Id
where article.Id>10
select new
{
article.Title,
read.ReadCount
}).ToList();
into sql string
select article.Title,
read.ReadCount
from ArticleTable as article
join ArticleReadTable as read on read.ArticleId = article.Id
where article.Id>10
use c# code