DBSet Class(EF基础系列11)
|
Method Name |
Return Type |
Description |
|
Add |
Added entity type |
Adds the given entity to the context the Added state. When the changes are being saved, the entities in the Added states are inserted into the database. After the changes are saved, the object state changes to Unchanged. Example: |
|
AsNoTracking<Entity> |
DBQuery<Entity> |
Returns a new query where the entities returned will not Entities Example: |
|
Attach(Entity) |
Entity which was passed as parameter |
Attaches the given entity to the context in the Unchanged Example: |
|
Create |
Entity |
Creates a new instance of an entity for the type of this Example: |
|
Find(int) |
Entity type |
Uses the primary key value to attempt to find an entity Example: |
|
Include |
DBQuery |
Returns the included non generic LINQ to Entities query Example: |
|
Remove |
Removed entity |
Marks the given entity as Deleted. When the changes are Example: |
|
SqlQuery |
DBSqlQuery |
Creates a raw SQL query that will return entities in this Example: |
DBSet Class(EF基础系列11)的更多相关文章
- 【Basics of Entity Framework】【EF基础系列1】
EF自己包括看视频,看MSDN零零散散的学了一点皮毛,这次打算系统学习一下EF.我将会使用VS2012来学习这个EF基础系列. 现在看看EF的历史吧: EF版本 相关版本特性介绍 EF3.5 基于数据 ...
- 1.翻译:EF基础系列--什么是Entity Framework?
大家好,好久不见,EF系列之前落下了,还是打算重新整理一下. 先说说目前的打算:先简单了解一下EF基础系列-->然后就是EF 6 Code-First系列-->接着就是EF 6 DB-Fi ...
- 10.翻译:EF基础系列---EF中的持久性
原文链接:http://www.entityframeworktutorial.net/EntityFramework4.3/persistence-in-entity-framework.aspx ...
- 6.翻译:EF基础系列---什么是EF中的实体?
原文地址:http://www.entityframeworktutorial.net/basics/what-is-entity-in-entityframework.aspx EF中的实体就是继承 ...
- 8.翻译:EF基础系列----EF中实体的状态
原文链接:http://www.entityframeworktutorial.net/basics/entity-states.aspx 在实体的生命周期中,EF API维护着每一个实体的状态,对于 ...
- EF中的开放式并发(EF基础系列--28)
好久没更新EF这个系列了,现在又重新开始. 这次学习,开放式并发.首先拿出数据库脚本: 说明一下,这个数据库脚本是之前的章节中稍作修改的: USE [SchoolDB] GO /****** Obje ...
- 9.翻译:EF基础系列---使用EF开发的方式有哪些?
原文链接:http://www.entityframeworktutorial.net/choosing-development-approach-with-entity-framework.aspx ...
- 4.翻译:EF基础系列--EF架构
原文地址:http://www.entityframeworktutorial.net/EntityFramework-Architecture.aspx 下面的图形,展示了EF的总体架构: 让我们来 ...
- 3.翻译:EF基础系列--EF怎么工作的?
原文链接:http://www.entityframeworktutorial.net/basics/how-entity-framework-works.aspx 这里,你将会大概了解到EF是怎么工 ...
随机推荐
- 如何利用OCS缓存TomcatSession全局变量(转)
转: 首先非常感谢阿里云给我们提供了一个如此省事的平台. 我们公司是一家物流公司,主要提供运输和仓储的服务.我们现在正在把我们的系统往阿里云迁移.当然,还在迁移过程中,所以还有很多是没办法现在说得太清 ...
- 百度Web富文本编辑器ueditor在ASP.NET MVC3项目中的使用说明
====================================================================== [百度Web富文本编辑器ueditor在ASP.NET M ...
- WPF TextBlock 绑定 换行
最近有个小需求 需要在textblock中换行 其实textblock换行有很多写法,比如: Xaml: <TextBlock Text="AAAAA BBBBB" /> ...
- SQL Server如何启用xp_cmdshell组件
[错误描述]: SQL Server阻止了对组件‘xp_cmdshell’的过程‘sys.xp_cmdshell’的访问.因为此组件已作为此服务嚣安全配置的一部分而被关闭.系统管理员可以通过使用sp_ ...
- 用 Jenkins 打包 iOS
需要安装插件: 1.GIT plugin 2.Xcode integration 1.新建 Job 填入“Item名称”,选择“构建一个自由风格的软件项目”,OK: 2.填入“项目名称” ...
- 构建基于WinRT的WP8.1 App 01:页面导航及页面缓存模式
本篇博文主要阐述基于Windows Runtime的Windows Phone 应用页面间导航相关知识,主要分为以下几个方面: Window.Frame和Page概览 页面间实现跳转 处理物理后退键 ...
- jar包制作
1,利用jdk自带的工具制作 1) 首先要确保所有的java文件都被编译成了.class文件,可以用javac批量编译多个文件 javac c:\java\src\wz\learning\*.java ...
- .NET 相关工具
加密工具,反DUMP,反调试,反编译,加密代码资源内容,混淆流程,变量.Confuser is a protector/obfuscator for .NET, providing great sec ...
- HttpListenerCS客户端监听http
using System; using System.Collections.Generic; using System.ComponentModel; using System.Data; usin ...
- Adobe Flash Builder 4.6破解方法
http://hi.baidu.com/cm186man/blog/item/148658ce557c0323b700c853.html 1.到Adobe官网下载FlashBuilder 4.6,有简 ...