How Do I View the Contents of the Transaction Log?

  • I have a 700mb Transaction log file, and I want to see what was happening at a certain time yesterday. I've searched BOL to find a way to view the transaction list, to no avail. Is this even possible?

    I'm new at this... thanks.

    -PD

  • No decent way except to buy Log Explorer by Lumigent.

    Andy

    http://www.sqlservercentral.com/columnists/awarren/

  • You know, I figured there would be money involved...

    : )

    Thanks for the quick reply!

  • DBCC LOG

    This command is used to view the transaction log for the specified database.

    Syntax:

    DBCC log ({dbid|dbname}, [, type={-1|0|1|2|3|4}])

    where:

    dbid or dbname - Enter either the dbid or the name of the database

    type - is the type of output, and includes these options:

    0 - minimum information (operation, context, transaction id)

    1 - more information (plus flags, tags, row length, description)

    2 - very detailed information (plus object name, index name, page id, slot id)

    3 - full information about each operation

    4 - full information about each operation plus hexadecimal dump of the current transaction log's row.

    -1 - full information about each operation plus hexadecimal dump of the current transaction log's row, plus Checkpoint Begin, DB Version, Max XDESID

    by default, type = 0

    To view the transaction log for the master database, run the following command:

    DBCC log (master)

    This may be of some help.....

    Cheers,

    Prakash

    Prakash Heda
    Lead DBA Team - www.sqlfeatures.com
    Video sessions on Performance Tuning and SQL 2012 HA

  • The problem with DBCC LOG is the output for the query is not text but varbinary/encrypted or something like that and I have found no details on this. Log Explorer does offer you the best solution. Also, if you only need once you could download the trial and try for this, thus it you like what it does you may purchase for future needs.

    "Don't roll your eyes at me. I will tape them in place." (Teacher on Boston Public)

  • Prakash, thanks, for the bit I need that'll work.

    Antares, I did download LogExplorer, and it is awesome. Need to convince my boss of the cost, however...

    -PD

  • Log Explorer by Lumigent is the best tool to use. Course money will be involved.

    Goog luck.

Viewing 7 posts - 1 through 6 (of 6 total)

You must be logged in to reply to this topic. Login to reply