Solved

Looking for deleted files in SharePoint by using SQL backups.

Posted on 2014-11-20
7
81 Views
Last Modified: 2015-10-21
I have a project where I have multiple SharePoint SQL databases from different points in time.  These different points in time are being retrieved from full SQL backups.  I am trying to determine if any documents were deleted between each backup.  This is in SharePoint 2010 RTM.

There are two methods that come to mind to accomplish this.  I wanted to get input regarding this.  If there is another method to do this, it would be great to hear.

1)      In the dbo.AllDocs table use the DirName and LeafName column to build the path of the file.  Once I have the path, I can do a comparison to see if it exists in the other databases.

2)      Use the Id column in the dbo.AllDocs table to uniquely identify files.  I am assuming this would be unique across all databases.  It would also help determine if a user deleted a document then try to put it back in place.

Any input would be greatly appreciated.
0
Comment
Question by:rye004
  • 3
  • 2
  • 2
7 Comments
 
LVL 39

Expert Comment

by:lcohan
ID: 40455884
If you have the Audit Log reports already configured then you could use that  one to check for "Deleted and restored items" and many more - please see details at:

http://office.microsoft.com/en-ca/sharepoint-server-help/view-audit-log-reports-HA102039795.aspx

http://neelb.wordpress.com/2011/08/04/find-who-deleted-files-on-sharepoint-2010/
0
 
LVL 37

Accepted Solution

by:
Neil Russell earned 500 total points
ID: 40455942
Doing anything that relies on direct queries of the SharePoint Database itself is a very time consuming, last resort, effort  due mainly to a system that has not been configured and managed correctly.

Sharepoint is not designed to managed or monitored by access to the SQL database.  Not to overstress the fact but if you are having to access the physical SQL tables then your SharePoint system is set up optimally.

Concentrate on the configuration and setup of SharePoint as it is meant to be used first and foremost.
0
 

Author Comment

by:rye004
ID: 40456048
Icohan, I do not have the audit log files.
0
Complete VMware vSphere® ESX(i) & Hyper-V Backup

Capture your entire system, including the host, with patented disk imaging integrated with VMware VADP / Microsoft VSS and RCT. RTOs is as low as 15 seconds with Acronis Active Restore™. You can enjoy unlimited P2V/V2V migrations from any source (even from a different hypervisor)

 
LVL 37

Expert Comment

by:Neil Russell
ID: 40456076
Correction to my above post. Should say....

"Not to overstress the fact but if you are having to access the physical SQL tables then your SharePoint system is NOT set up optimally."
0
 
LVL 39

Expert Comment

by:lcohan
ID: 40456081
In that case I think you could use the same script from link below to get the delta's - it is under "Ran the following SQL Script to review all files that had changed since 17th March against the mounted "


https://social.technet.microsoft.com/Forums/sharepoint/en-US/c6d92b2c-e4a1-4ecd-bd82-d3b84e71ccce/extract-doc-from-dboalldocs?forum=sharepointadminlegacy
0
 

Author Comment

by:rye004
ID: 40456084
Neilsr,
This is the last resort and a onetime deal.  Performance is not a concern.
Thank you for your comment.
0
 

Author Comment

by:rye004
ID: 40456557
Thank you everyone for your input.  I ended up going with my second option in my list above.
0

Featured Post

Microsoft Certification Exam 74-409

Veeam® is happy to provide the Microsoft community with a study guide prepared by MVP and MCT, Orin Thomas. This guide will take you through each of the exam objectives, helping you to prepare for and pass the examination.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Why is this different from all of the other step by step guides?  Because I make a living as a DBA and not as a writer and I lived through this experience. Defining the name: When I talk to people they say different names on this subject stuff l…
The Delta outage: 650 cancelled flights, more than 1200 delayed flights, thousands of frustrated customers, tens of millions of dollars in damages – plus untold reputational damage to one of the world’s most trusted airlines. All due to a catastroph…
Via a live example, show how to extract insert data into a SQL Server database table using the Import/Export option and Bulk Insert.
Viewers will learn how to use the INSERT statement to insert data into their tables. It will also introduce the NULL statement, to show them what happens when no value is giving for any given column.

863 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now