惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

T
Threatpost
V
Vulnerabilities – Threatpost
TaoSecurity Blog
TaoSecurity Blog
C
Cybersecurity and Infrastructure Security Agency CISA
P
Proofpoint News Feed
G
GRAHAM CLULEY
S
Securelist
P
Palo Alto Networks Blog
MongoDB | Blog
MongoDB | Blog
A
Arctic Wolf
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
WordPress大学
WordPress大学
Project Zero
Project Zero
T
Threat Research - Cisco Blogs
L
Lohrmann on Cybersecurity
C
Cyber Attacks, Cyber Crime and Cyber Security
F
Fortinet All Blogs
博客园 - 叶小钗
B
Blog RSS Feed
C
Cisco Blogs
Google DeepMind News
Google DeepMind News
cs.CL updates on arXiv.org
cs.CL updates on arXiv.org
Apple Machine Learning Research
Apple Machine Learning Research
G
Google Developers Blog
K
Kaspersky official blog
D
Docker
Latest news
Latest news
Cisco Talos Blog
Cisco Talos Blog
T
Tor Project blog
Cyberwarzone
Cyberwarzone
Security Latest
Security Latest
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
D
Darknet – Hacking Tools, Hacker News & Cyber Security
Spread Privacy
Spread Privacy
Microsoft Azure Blog
Microsoft Azure Blog
C
Check Point Blog
J
Java Code Geeks
Simon Willison's Weblog
Simon Willison's Weblog
T
Tenable Blog
Recent Announcements
Recent Announcements
T
Tailwind CSS Blog
H
Help Net Security
L
LINUX DO - 热门话题
T
The Exploit Database - CXSecurity.com
Jina AI
Jina AI
S
SegmentFault 最新的问题
MyScale Blog
MyScale Blog
NISL@THU
NISL@THU
美团技术团队
腾讯CDC

博客园 - 天浩

页面传值 服务器控件生命周期 ASP.NET 2.0页面框架的几处变化 序列化 ASP.NET 2.0个性化配置(profile) .net 中通用的formatstring格式符整理 连接到 SQL Server 2005 时出现的问题 什么是VRML 怪哉!天气! 有点懒散! 计算机维修网项目分析 重新学习C语言 汉诺塔问题 六十六条经典禅语 纪念周总理:他从未离去 完成了数据库的作业 无限存 图解弗洛伊德之冰山理论 纪念我的硬盘
开学一星期
天浩 · 2006-02-27 · via 博客园 - 天浩

     淅淅沥沥的小雨陆陆续续下了一星期了,天气预报有说明天又有冷空气来到,可能还会下雪,郁闷!
     开学的第一天,就逃课看NBA全明星,比赛很精彩,O'NEL的搞笑功夫一流,麦蒂的表现精彩,遗憾的是西部又输了,麦蒂也离MVP一步之遥。不过现在火箭的战绩回升,保留了进军季后赛的希望。明天打太阳,希望火箭能赢。
     本来是打算上自习的,下着雨就不愿去了,待在寝室里,没什么事,看了一个微软的一个ADO讲座,简记之。
    
       ADO.NET特征

         1  

面向非连接的分布式数据源
         2   集成XML的支持
         3   支持企业级多层应用程序开发
         4   由经典ADO发展而来,保留了一些经典ADO的组件特性

        ADO.NET体系结构

      数据集结构

          

       面向非连接模型
         
          

     ADO.NET性能设计的考虑

       1  更据数据的使用方式来设计数据访问层
       2  缓存数据,避免不必要的操作
       3  使用服务帐户进行连接
       4  必要时连接,尽早释放
       5  关闭可关闭的资源
       6  减少往返
       7   仅返回需要的数据
       8   选择适当的事务类型
       9   使用存储过程
      10  根据性能、可维护性、及实现难度来决定跨层数据传递的方式
     数据库连接比较
 
     

     连接
         1  在方法中打开和关闭连接
         2  明确地关闭连接
         3  当使用DataReaders, 指定CommandBehavior.CloseConnection
         4  当使用Fill或Update方法时,不要手工打开连接
         5  避免检查OleDbConnection 的State属性
         6  使用连接池

    SQL指令
          1  校验SQL的输入并使用参数
          2  仅返回需要的行和例
          3  对大的数据集使用分页功能
          4   批次执行SQL ,减少往返
          5   如果没有数据返回则使用ExecuteNonQuery方法

          6   当返回一个标量时,使用ExecuteScalar方法
          7  不要在运行时间使用CommandBuilder

     存储过程
         1   尽量使用存储过程
         2   对于OleDbCommand,指令类型为CommandType.Text
         3  使用SqlCommand时,指令类型为CommandType.StoredProcedure
         4   考虑使用Command.Prepare()
         5  尽可能使用输出参数
         6  考虑在SQL Server上SET NOCOUNT ON