日期:2014-05-20 浏览次数:20841 次
using (BirthdayRemindEntities2 db = new BirthdayRemindEntities2())
{
System.Data.Objects.ObjectSet<car> orders = db.CreateObjectSet<car>();
foreach (car item in orders)
{
item.proname = item.proname + item.ID;
}
db.SaveChanges();
foreach (car item in orders)
item.type = item.type + item.ID;
db.SaveChanges();
}
public class ObjectSet<TEntity> : ObjectQuery<TEntity>,
IObjectSet<TEntity>, IQueryable<TEntity>, IEnumerable<TEntity>,
IQueryable, IEnumerable
where TEntity : class