LINQ批量删除符合条件的数据

批量处理数据的方法:<?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" />

CCPressDataContext cp = new CCPressDataContext();

IQueryable<BookInfoMaterial> aa =from a in cp.BookInfoMaterial

where a.AuthorName.Contains("aa")

select a;

cp.BookInfoMaterial.DeleteAllOnSubmit(aa);

cp.SubmitChanges();

你可能感兴趣的:(xml,Microsoft,Office,LINQ)