1. TempDB只能运行在Simple Recovery Model下

2. 由于TempDB不需要Recovery,因此在TempDB中发生的操作不需要REDO,因此在日志记录上有别于其他数据库。

3. 不是所有在Tempdb中的object都被记录日志。

4. Improved cahcing for tempory objects, SQL Server chaches 1 IAM Page and 1 data page with the associated query plan.First, if the same plan is exected multiple times, the tmeporary table needs to be created once there by reducing ddl contention and reduceing allocation contention.(如果存储过程中包含创建临时表,那么临时表只会在存储过程编译的时候被创建),Temp objects are only cached when none of the following conditions is violated:

1. Data definition languaged(DDL) statements that affects the table are not run after the temp table has been created, such as create index or create statistics statements.

2. named constraints are not created.

3. Temp objects is not created by using dynamic SQL, such as:sp_executesql

系统对一些临时对象进行优化以减少重复创建和删除临时对象造成的Allocation Bottleneck

Internal object: created internally by sql server to execute user command, like the temprory result set(worktable) which created by hash join.

The operation on internal objects are not logged because internal objects are created/destoryed in the scope of a single statement.

内部对象有系统创建和清理,对内部对象的操作不记录入日志。

Tempdb--TempDB Basic的更多相关文章

  1. SQL Server 2008性能故障排查(四)——TempDB

    原文:SQL Server 2008性能故障排查(四)--TempDB 接着上一章:I/O TempDB: TempDB是一个全局数据库,存储内部和用户对象还有零食表.对象.在SQLServer操作过 ...

  2. 移动tempdb导致数据库服务不能启动

    事情的起因是因为数据库的IO操作过大,于是新加了个硬盘,发现在执行写入操作的时候,服务器的压力依然是比较大的,于是想到了内存盘.内存盘是"魔方"系统优化提供的一个小工具,就是将内存 ...

  3. Tempdb总结

    Tempdb 系统数据库是一个全局资源,可供连接到 SQL Server 实例的所有用户使用,并可用于保存下列各项: 显式创建的临时用户对象,例如全局或局部临时表.临时存储过程.表变量或游标. SQL ...

  4. Sql Server Tempdb原理-日志机制解析实践

    笔者曾经在面试DBA时的一句”tempdb为什么比其他数据库快?”使得95%以上的应试者都一脸茫然.Tempdb作为Sqlserver的重要特征,一直以来大家对它可能即熟悉又陌生.熟悉是我们时时刻刻都 ...

  5. SQLServer临时库文件太大,迁移tempdb数据库

    问题描述: 最近公司这边tempdb库文件很大,几百GB的节奏 不过安装数据库的时候,tempdb最好不要放在C盘是放在D盘其他数据盘的 如果没有放在其他盘符下面,就需要做迁移了 解决方法: 如果te ...

  6. SQL SERVER-修改TempDB路径

    --查看tempdb文件信息 use tempdb go sp_helpfile go --修改路径 use master go Alter database tempdb modify file ( ...

  7. SQL Server 系统数据库

    Sql Server的系统数据库分为:master.model.msdb,resouce和tempdb,这五个数据库在SQL Server中各司其职,作为研发人员,很有必要了解这几个数据库的职责,下面 ...

  8. SQL Server-语句类别、数据库范式、系统数据库组成(一)

    前言 终于等到这一天,我要开始重新系统学习数据库了,关于数据库这块,不出意外的话,每天会定时更新一篇且内容不会包含太多,简短的内容,深入的理解,Always to review the basics. ...

  9. SQL 统计整个服务器上各个数据库占用的空间

    create procedure [dbo].[P__SpaceUsedView]asbegin if not exists (select 0 from tempdb..sysobjects whe ...

  10. 人人都是 DBA(V)SQL Server 数据库文件

    SQL Server 数据库安装后会包含 4 个默认系统数据库:master, model, msdb, tempdb. SELECT [name] ,database_id ,suser_sname ...

随机推荐

  1. C++和C# WebService相互调用

    C#调用C++ gSOAP: 调用http://blog.csdn.net/ggz631047367/article/details/44567411的服务http://127.0.0.1:8089/ ...

  2. 关于&&和||

    从alert(1&&2)输出为2谈起 一.先来说说||(逻辑或),从字面上来说,只有前后都是false的时候才返回false,否则返回true. alert(true||false); ...

  3. canvas设置渐变

    canvas设置渐变 方法 createLinearGradient(x1, y1, x2, y2) 线性渐变 createRadialGradient(x1, y1, r1, x2, y2, r2) ...

  4. cmd变量,参数,for循环,

    @echo offrem  *****************************************************rem  Create By Q_rui CopryRight@_ ...

  5. C++Builder STL 泛型

    STL(Standard Template Library)标准模板库, 包括了算法,容器,迭代器.就是泛型. 向量(vector) 连续存储的元素<vector>列表(list) 由节点 ...

  6. $(function(){})理解

    $(function(){})  =  jQuery(function(){}) = jQuery(document).ready(function(){ });

  7. ansible模块学习

    ansible的功能: 模块化任务,调用特定的模块,完成特定的任务 基于python语言实现,由paramiko.pyyaml和jinja2三个模块构建 部署简单,agentless,ansible基 ...

  8. MobaXterm 错行,乱码

    最近使用MobaXterm ssh,发现进入ssh显示中文没问题.但如果用VIM编辑文件时如果有中文,修改插入操作有时就会有串行乱码情况,改vim编码也不行.都没有完美解决.最后发现只需要在MobaX ...

  9. 3D 点云特征

    博客参考: https://blog.csdn.net/shaozhenghan/article/details/81346585 和 https://www.cnblogs.com/li-yao77 ...

  10. Halcon二维仿射变换实例探究

    二维仿射变换,顾名思义就是在二维平面内,对对象进行平移.旋转.缩放等变换的行为(当然还有其他的变换,这里仅论述这三种最常见的). Halcon中进行仿射变换的常见步骤如下: ① 通过hom_mat2d ...