通过linq查询datatable数据集合满足条件的数据集 1.首先定义查询字段的变量,比方深度 string strDepth=查询深度的值: var dataRows = from datarow in dataTable(须要查询的datatable数据集).AsEnumerable() where string.Compare(datarow.Field<string>(…
自定义列 .Select( p = >new{ test = p.id}) // 同sql 列名 as 新列名 如下是 自己在写代码的例子,查询,分页,where条件,排序 var where = new Where<INCOM_TERMINALFAULT>(); ); ")); DataTable table = Db.Context.From<INCOM_TERMINALFAULT>() .Select( p = >new{ test = p.CARID}…