Which backups have been restored is kept in the msdb database. Look in the database for tables that start with backup or restore. That's where the information is kept. You can also look in the ERRORLOG file as each restore should be logged in there.
Last Wiki Answer Submitted: June 17, 2009 3:17 am by Denny Cherry64,520 pts.
All Answer Wiki Contributors: Denny Cherry64,520 pts.
If you live outside the United States, by submitting your email address you consent to having your personal data transferred to and processed in the United States.
what i want to do is pull the last lsn number applied to the database to view with a tsql statement, is there a way to do that? And also i want to pull the lsn to view from the transaction log using tsql
Thanks Mr. Denny, I used the msdb.
select bs.backup_start_date,
bs.first_lsn,
bs.last_lsn,
bs.checkpoint_lsn
from dbo.backupset bs
where bs.database_name = ‘YourDatabaseNameHere’
and bs.backup_set_id > (select max(backup_set_id) from dbo.backupset where database_name = bs.database_name and type = ‘D’)
what i want to do is pull the last lsn number applied to the database to view with a tsql statement, is there a way to do that? And also i want to pull the lsn to view from the transaction log using tsql
Thanks Mr. Denny, I used the msdb.
select bs.backup_start_date,
bs.first_lsn,
bs.last_lsn,
bs.checkpoint_lsn
from dbo.backupset bs
where bs.database_name = ‘YourDatabaseNameHere’
and bs.backup_set_id > (select max(backup_set_id) from dbo.backupset where database_name = bs.database_name and type = ‘D’)