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. TCL数据类型

    原始数据类型在Tcl中是字符串,我们常常可以找到字符串和引用在Tcl语言中.这些原始数据类型依次创建复合数据类型列表和关联数组.在Tcl中,数据类型可以表示不仅是简单Tcl的对象,但也可以代表相同的句 ...

  2. 精《Linux内核精髓:精通Linux内核必会的75个绝技》一HACK #5 使用checkpatch.pl检查补丁的格式

    HACK #5 使用checkpatch.pl检查补丁的格式 本节介绍发布前检查补丁格式的方法.Linux内核是由多个开发者进行开发的.因此,为了保持补丁评估与源代码的可读性,按照统一的规则进行编写是 ...

  3. RPM包下载网址

    https://pkgs.org/ (最爱) http://rpm.pbone.net/ http://rpmfind.net/linux/RPM/index.html

  4. centos7上mysql无法启动也没有日志

    报错的原因就是 [root@localhost duanxinli]# journalctl -xe-- Subject: Unit mysqld.service has begun start-up ...

  5. leetcode172

    public class Solution { public int TrailingZeroes(int n) { ) { ; } else { ; var y = TrailingZeroes(x ...

  6. 用VB6.0实现串口通信

    Then       ' 1位或2位          'byte 类型取值范围为 0-255 ,不能为-1                   = ) & )     End IfstrHe ...

  7. MVC4中压缩和合并js文件和样式文件

    1.在App_Start文件夹中BundleConfig.cs类中添加相应的文件 1.1bundles.Add(new ScriptBundle("~/bundles/adminJs&quo ...

  8. Go Packages、Variables、functions

    [Go Packages.Variables.functions] 1.定义包名. 2.引入Package. 3.定义导出的变量.首字母必须大写. 4.函数.Notice that the type ...

  9. ios 解决Wkwebview闪烁问题

    // 网页闪烁问题    if ([self.webView.realWebView isKindOfClass:[WKWebView class]]) {         ((WKWebView * ...

  10. asp.net安装指令

    cd \ cd C:\WINDOWS\Microsoft.NET\Framework\v4.0.30319aspnet_regiis.exe -i注册.NET4到IIS