문제

I am a programmer who has done a very bad thing and somehow didn't select the WHERE clause before hitting F5 on an update query in SQL Server 2008. I know this isn't a programming question but it is a question from a desprate programmer ...

Is there anyway to get the one column's data back from the transaction log or a log kept by the mirroring system?

Oh and yes, it gets better: the nightly maintenance plan for backups seems to have been turned off.

Any ideas please? -Mike stunned at reading "(197875 row(s) affected)"

도움이 되었습니까?

해결책

Call off the dogs. I regenerated the database from an old backup and the source log files used to populate it.

In a more lucid moment I came to understand my question as:

Is the original value of a row stored in the transaction log of an update operation? I'm almost sure the answer is no.

Thanks for listening.

-Mike

다른 팁

Mike, glad to hear you were able to recover the data. Now is the time to implement some sort of backup strategy :)

To your question, the transaction log can be backed up (every 10 minutes, etc.), but no... the original value is not persisted anywhere unless you explicitly build that functionality in. A great place to start is Ola Hallengren's great set of free maintenance scripts.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top