Sunday, March 11, 2012
Apply Log File Transactions
file was on another disk and it is apparently good thru
this morning. My last complete backup was last Friday
morning. I made two copies of the good log file and
restored the database using the option to restore more
log files. I would like to apply the log file I saved to
this database but the restore process needs a file
created by backup. I cannot figure out how to back up the
saved log file using a file name. How can I do this?
BACKUP LOG XXX FILE = ? TO DISK
= 'D:\MSSQL\BACKUP\SAFE.BKP'
Hi
Perform BACKUP LOG databasename WITH NO_TRUNCATE (For more details please
refer to BOL)
"pbrattin" <pbrattin@.removethis-bigfoot.com> wrote in message
news:181501c426d5$a693f360$a101280a@.phx.gbl...
> I lost my mdf because of a failure on the RAID. The log
> file was on another disk and it is apparently good thru
> this morning. My last complete backup was last Friday
> morning. I made two copies of the good log file and
> restored the database using the option to restore more
> log files. I would like to apply the log file I saved to
> this database but the restore process needs a file
> created by backup. I cannot figure out how to back up the
> saved log file using a file name. How can I do this?
> BACKUP LOG XXX FILE = ? TO DISK
> = 'D:\MSSQL\BACKUP\SAFE.BKP'
>
>
Apply Log File Transactions
file was on another disk and it is apparently good thru
this morning. My last complete backup was last Friday
morning. I made two copies of the good log file and
restored the database using the option to restore more
log files. I would like to apply the log file I saved to
this database but the restore process needs a file
created by backup. I cannot figure out how to back up the
saved log file using a file name. How can I do this?
BACKUP LOG XXX FILE = ' TO DISK
= 'D:\MSSQL\BACKUP\SAFE.BKP'Hi
Perform BACKUP LOG databasename WITH NO_TRUNCATE (For more details please
refer to BOL)
"pbrattin" <pbrattin@.removethis-bigfoot.com> wrote in message
news:181501c426d5$a693f360$a101280a@.phx.gbl...
> I lost my mdf because of a failure on the RAID. The log
> file was on another disk and it is apparently good thru
> this morning. My last complete backup was last Friday
> morning. I made two copies of the good log file and
> restored the database using the option to restore more
> log files. I would like to apply the log file I saved to
> this database but the restore process needs a file
> created by backup. I cannot figure out how to back up the
> saved log file using a file name. How can I do this?
> BACKUP LOG XXX FILE = ' TO DISK
> = 'D:\MSSQL\BACKUP\SAFE.BKP'
>
>
Apply Log File Transactions
file was on another disk and it is apparently good thru
this morning. My last complete backup was last Friday
morning. I made two copies of the good log file and
restored the database using the option to restore more
log files. I would like to apply the log file I saved to
this database but the restore process needs a file
created by backup. I cannot figure out how to back up the
saved log file using a file name. How can I do this?
BACKUP LOG XXX FILE = ' TO DISK
= 'D:\MSSQL\BACKUP\SAFE.BKP'Hi
Perform BACKUP LOG databasename WITH NO_TRUNCATE (For more details please
refer to BOL)
"pbrattin" <pbrattin@.removethis-bigfoot.com> wrote in message
news:181501c426d5$a693f360$a101280a@.phx.gbl...
> I lost my mdf because of a failure on the RAID. The log
> file was on another disk and it is apparently good thru
> this morning. My last complete backup was last Friday
> morning. I made two copies of the good log file and
> restored the database using the option to restore more
> log files. I would like to apply the log file I saved to
> this database but the restore process needs a file
> created by backup. I cannot figure out how to back up the
> saved log file using a file name. How can I do this?
> BACKUP LOG XXX FILE = ' TO DISK
> = 'D:\MSSQL\BACKUP\SAFE.BKP'
>
>
Thursday, March 8, 2012
Application-controlled transactions, isolation level and commit/rollbacks
Are you talking about application controlled transactions as in the application only works through stored procedures? Or do you mean it use DTC Transactions? Either way, you should be able to catch these with SQL Profiler.
|||Yes, Peter, the application uses stored procs in all cases.. there is no Transaction handling inside the procs... no begin trans, rollback/commits... that is all on the app side, and I'm not sure how it's being sent to SQL Server, via DTC or what... I'll try tracing again and seeing if they can force a rollback, and see what comes thru in SQL Server... Thanks, Bruce|||I was also hoping to see what Isolation Level my stored procedures are being executed at via the profiler. I just don't see how I can do that, or anything like it.I would be grateful of any further information or help.
Regards
Darren
|||
Bruce dBA wrote:
Yes, Peter, the application uses stored procs in all cases.. there is no Transaction handling inside the procs... no begin trans, rollback/commits... that is all on the app side, and I'm not sure how it's being sent to SQL Server, via DTC or what... I'll try tracing again and seeing if they can force a rollback, and see what comes thru in SQL Server... Thanks, Bruce
In .NET 2.0 and above there are two other kinds of transactions that uses isolation levels and rollbacks one is atomic like the SQL Server transactions while the other is not but SQL Server 2005 is equiped to handle the none atomic transaction while 2000 is not so DTC is needed to run the none atomic in SQL Server 2000. The transactions from ADO.NET System.Data is atomic while the transaction from System.Transaction which uses TransactionScope it not. Try the links below for details.
http://msdn2.microsoft.com/en-us/library/system.transactions.aspx
http://msdn2.microsoft.com/en-us/library/system.data.isolationlevel.aspx
Application-controlled transactions, isolation level and commit/rollbacks
Are you talking about application controlled transactions as in the application only works through stored procedures? Or do you mean it use DTC Transactions? Either way, you should be able to catch these with SQL Profiler.
|||Yes, Peter, the application uses stored procs in all cases.. there is no Transaction handling inside the procs... no begin trans, rollback/commits... that is all on the app side, and I'm not sure how it's being sent to SQL Server, via DTC or what... I'll try tracing again and seeing if they can force a rollback, and see what comes thru in SQL Server... Thanks, Bruce|||I was also hoping to see what Isolation Level my stored procedures are being executed at via the profiler. I just don't see how I can do that, or anything like it.I would be grateful of any further information or help.
Regards
Darren
|||
Bruce dBA wrote:
Yes, Peter, the application uses stored procs in all cases.. there is no Transaction handling inside the procs... no begin trans, rollback/commits... that is all on the app side, and I'm not sure how it's being sent to SQL Server, via DTC or what... I'll try tracing again and seeing if they can force a rollback, and see what comes thru in SQL Server... Thanks, Bruce
In .NET 2.0 and above there are two other kinds of transactions that uses isolation levels and rollbacks one is atomic like the SQL Server transactions while the other is not but SQL Server 2005 is equiped to handle the none atomic transaction while 2000 is not so DTC is needed to run the none atomic in SQL Server 2000. The transactions from ADO.NET System.Data is atomic while the transaction from System.Transaction which uses TransactionScope it not. Try the links below for details.
http://msdn2.microsoft.com/en-us/library/system.transactions.aspx
http://msdn2.microsoft.com/en-us/library/system.data.isolationlevel.aspx