Learn how to a build a cloud-first strategyRegister Now

x
?
Solved

Export Sharepoint 2010 LIST to SQL nightly

Posted on 2014-03-27
4
Medium Priority
?
3,569 Views
Last Modified: 2014-12-07
I have a SharePoint 2010 Foundation and I would like to have a single list exported and then imported into my SQL 2008 (or 2005) machine. I need this because I need to build a clean automated email report nightly. Currently I have Data Source with SharePoint List data source type but the reporting is limited.

What is my best option? My true goal is to get this list into a SQL table so I can build real reports using Visual Studio.
0
Comment
Question by:allenkent
4 Comments
 
LVL 20

Expert Comment

by:Walter Curtis
ID: 39963856
You could do this with PowerShell. There are other ways of course, but PowerShell might be a good solution for you.
0
 
LVL 28

Accepted Solution

by:
Ryan McCauley earned 2000 total points
ID: 39965773
You could always query the WSS Content database directly in SQL and ETL the data out :) MSFT discourages direct querying of the content databases, but we've done it a number of times without issue and it's the most straightforward way to do it.

Alternatively, and in a totally supported fashion, you could go the route of creating a .NET SQL-CLR assembly that queries the SharePoint Webservice to fetch the contents of your list, and then returns them to SQL in the form of an output table you can merge directly into your data warehouse:

http://www.sharepointjohn.com/sharepoint-2010-sql-server-2008-query-the-sharepoint-object-model-from-a-net-sql-server-clr-function/

We've also done this before, and it works excellently. It's a bit more work up front, but it's smooth once it's deployed, and a random service pack won't break it because you're going through the official channels to get your data (as opposed to a query on the WSS Content database, which could break at any time as, again, it's unsupported).
0
 

Author Closing Comment

by:allenkent
ID: 40016324
This got me on the right path. The following video ended up answering step by step on how to do this process.

https://www.youtube.com/watch?v=O0OjT_VEObI
0
 
LVL 1

Expert Comment

by:G4lly
ID: 40485821
You can also look at AxioWorks SQList which will continuously export SharePoint Online and SharePoint onpremise lists, libraries, files and attachments into normalised SQL Server Tables.

Really useful when wanting to write complex SSRS reports or if you want to surface the data on the web etc via ASP .NET etc.
0

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Question has a verified solution.

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

A Stored Procedure in Microsoft SQL Server is a powerful feature that it can be used to execute the Data Manipulation Language (DML) or Data Definition Language (DDL). Depending on business requirements, a single Stored Procedure can return differe…
When trying to connect from SSMS v17.x to a SQL Server Integration Services 2016 instance or previous version, you get the error “Connecting to the Integration Services service on the computer failed with the following error: 'The specified service …
Via a live example, show how to set up a backup for SQL Server using a Maintenance Plan and how to schedule the job into SQL Server Agent.
Viewers will learn how to use the SELECT statement in SQL to return specific rows and columns, with various degrees of sorting and limits in place.
Suggested Courses

810 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