I have one datatable named Report_DT, this datatable have one column called “Trade Amount”
2.This datatable have one column called “aa[ Trade Amount ]”, the value have positive and negative numbers(EG:-12.34, 45.67)
3.I want to use LINQ
4.My Linq is: Report_DT.Select(“(abs(Cdbl([aa[ Trade Amount \]]))='Cdbl(”+OracleItem(“Trans. Debits”).ToString+“)’ or abs(Cdbl([aa[ Trade Amount \]]))='Cdbl(”+OracleItem(“Trans. Credits”).ToString+“)')”)
5.System prompt Error “Assign: The expression contains undefined function call Cdbl().”
Please help to solve this issue, or tell me how to use abs and cdbl function using LINQ
If you need to filter rows using LINQ, Enumerable.Where method works and it supports any .net function such as CDbl and Math.Abs etc. For example. as the following.