1
我有一个查询:在LINQ查询乘以不同的数据类型为sql
var list_transaction = from i in Dt.Transactions
join c in this.Dt.Customers on i.CustomerID equals c.ID
join e in this.Dt.Employees on i.EmployeeID equals e.ID
join p in this.Dt.Projects on i.ProjectID equals p.ID
where
i.CustomerID == idCus &&
i.TransactionStep == 3 &&
i.EmployeeID == e.ID &&
i.ProjectID == p.ID
select new {
VAT = (i.Taxable * i.Total * p.VATRate/100)
};
问题:增值税具有不同的数据类型三种价值的倍增。应税是int,Total是货币,VATRate是浮动。
所以任何人都可以告诉我,我该如何在这个查询中进行转换?
非常感谢。
谢谢Socheata酒店。它运作良好。 – titi 2012-02-07 09:14:05