Printed 2017/01/19 12:13PM

Time Pass With Transaction Log - Part 1

By Ramkumar (LivingForSQLServer), 2012/11/05

Hundreds of expert level books, articles, videos and blogs has talked much about Transaction Logs and How well to manage it.

Everything from basics to best practices are documented in various format except "How to read Transaction Log Entries"

Yes. this series of articles is just an attempt to try reading  transaction log records *of some basic DDL & DML commands*

Eventhough We are going to confirm our learning with examples, We can expect mistakes or inaccuracy in this journey.

Is this so easy to understand? Nope. good level understanding about storage internals and system tables and little experience is required.

Is this so hard to understand? Nope. good level of storage internals and system tables knowledge is enough to understand how this works.

Who are all the target audiences? dedicated SQL Server students having curious minds.

Are We going to learn everything about T-Logs? Its an Ocean. Our focus is only around Understanding T-Logs & Interpreting T-Log records.

Prerequisites (for the first time I am suggesting my blog posts as reference):

Storage Internals:

1. Storage Internals Basics -

2. Partitions and Allocation Units -

3. Architecture of Heaps -

4. How to read a Heap Page -

5. Properties of Clustered and Non Clustered Index Pages -

Understanding Logging and Recovery in SQL Server (By Paul Randal)



Not satisfied with this? Here are some simple excercises for you

1. Create a database.  Just run below statement and check how many columns are familiar to you?

SELECT * FROM fn_dblog(null, null)

Not familiar with lots of columns? Don't worry. You have a friend. Lets learn together.

2. Create some test databases with different log file sizes such as 1 MB, 50 MB, 100 MB and 2 GB an run below statement.

Do you observe any difference in output?


Paul Randal and Kalen Delaney

Copyright © 2002-2017 Redgate. All Rights Reserved. Privacy Policy. Terms of Use. Report Abuse.