摘要:
C#中Linq的表关联查询尽量使用Contains代替。 Linq中表关联查询如果数据量大,效率会比较低。使用Contains代替会提升很大的效率。 var result = from A in list1 from B in list2 where A.ID1== B.ID2 select A; 阅读全文
摘要:
1 根据数据库名获取所有表名 select name from sysobjects where xtype='u' 2 根据表名获取所有列名 select name from syscolumns where id = object_id('HIS_OperationList'); 3 根据表名 阅读全文
摘要:
如果是C# 6.0 public int X { get; set; } = 100 如果语法不支持,只能改回.net 2.0的写法。 public class UserType { private int _UserType = 1; public int UserTypeID { get { r 阅读全文