Showing posts with label SharePoint error. Show all posts
Showing posts with label SharePoint error. Show all posts

Saturday, May 21, 2011

Create Reports Using PowerPivot Data Source

You can create new SSRS reports, Excel reports, or PPS Dashboard reports based on PowerPivot workbooks that are published in a SharePoint PowerPivot Gallery. PowerPivot data access on a server is supported through SharePoint 2010 with SQL Server 2008 R2.

SSRS Reports

You can use either Report Designer in BIDS or Report Builder to access the PowerPivot data.  The Reporting server could be in native mode or in SharePoint integrated mode.  Not like the Excel reports which include embedded data, SSRS reports always access PowerPivot data as an external data source.

In order to support PowerPivot connections from Report Designer, you must have the SQL Server 2008 R2 OLE DB Provider for Analysis Services installed.  Windows authentication is also required to integrate between the SSRS server and the PowerPivot server.  More information could be found at http://msdn.microsoft.com/en-us/library/ee210631.aspx.

Steps for SSRS Reports:

  • Create a new Report Server Project in Visual Studio 2008 or BIDS
  • Add new data source in Share Data Source

image

  • Using the Microsoft SQL Server Analysis Services Type with Connection String pointed to the SharePoint location for the PowerPivot spreadsheet, for example: Data Source="http://SharepointServerName/PowerPivot Gallery/PowerPivotDemo.xlsx"

image

  • Click on the Credentials tab to set the Authentication to be Windows and click on OK button.

image

  • Add a new report and select the Share data source just created, then click on Next.

image

  • Click on the Query Builder button

image

  • The Query Designer will be opened with a Sandbox cube

image

  • You now should be able to work on your MDX query to get your result as needed.

image

 

Excel Reports

You could also create new Excel reports to access the PowerPivot workbooks that you have permissions with.

Steps for Excel Reports:

  • Open Excel, go to Data tab and select From Data Connection Wizard on Other Sources menu

image

  • On the Data Connection Wizard window, select the Other/Advanced option and click on Next button

image

  • Select the Microsoft OLE DB provider for Analysis Services 10.0 and click on Next

imageimage

image

  • The Select Database and Table window will then be opened with Sandbox Cube been selected to be used. Click on the Next to save the data connection file and finish the wizard. Here’s what the connection string may look like:

Provider=MSOLAP.4;Persist Security Info=True;Initial Catalog=PowerPivotDemo Sandbox 6042a0d5-355c-47ed-b24c-d458bfecd529;Data Source=http://SharePointServerName/PowerPivot Gallery/PowerPivotDemo.xlsx;MDX Compatibility=1;Safety Options=2;MDX Missing Member Mode=Error;Data Source Version=5/9/2011 5:27:11 PM

    image

  • You now should be able to use the Data from the PowerPivot data source to create your excel report

image

 

Performance Point Server Reports

Performance Point Server on SharePoint 2010 also supports PowerPivot data source.

Steps for PPS Reports:

  • Open PPS Designer and connect to the SharePoint site
  • Create a new Analysis Service data source

image

image

Since Excel Pivot Tables that go against PowerPivot data do not support the write back, offline cubes, and drill through,  there are some known issues when using the PowerPivot data source in PPS reports such as:

  • Show Details error

image_thumb9[1] image_thumb10[1]

  • Error running data source query. DrillThrough is not supported because the server is running in VertiPaq mode.

 image_thumb12[1]

 
Additional References:

PowerPivot Connection Type (SSRS)

Plan for PowerPivot Integration with Reporting Services

PowerPivot Features

ErrorCode Enumeration

Tuesday, March 1, 2011

Create SSRS Report with SharePoint 2010 Integrated Mode

With SharePoint 2010, lots people would like to use SSRS Integrated mode. The advantage is that you can deploy data sources, reports, etc. to the SharePoint document library instead of the Report Manager web application. In addition, you could also use the new version of Report Builder that came with SQL Server 2008 R2 and deploy the reports to SharePoint.  Derek Sanderson posted a blog entry: How to Switch from SSRS Native Mode to SharePoint Integrated Mode with detailed graphic information to show step by step how to do it. Once you completed all the installation steps, you may want to create the SSRS reports on it. The following steps show you how to do it.

Create SSRS Report Document Library

In order to deploy or create SSRS artifacts, you need to add a document library with the appropriate content types.

  • Create a new document library called SSRS Report

image

  • Go to the Library tab and click on the Library Settings menu to configure the content type

image

  • In the General settings section, click on the Advanced settings link

image

  • Change the Allow management of content types? to “Yes” and click the OK button to apply the change

image 

  • In the Content Types section, click on the Add from existing site content types link

image

  • Select the Report Builder Model, Report Builder Report, and Report data source content types from the Available Site Content Types list to be added, then click the OK button to apply the change.

image

  • If you want to change the default or the visible order of the content types, you could click on the Change new button order and default content type link and modify accordingly.

image

image

  • Return back to the SSRS Report Document library, and click on the New Document from the Documents tab. Now you should be able to see the Report Builder menus that have been created.

image

  • To launch the Report Builder, click the Report Builder Report menu.  You can now use it to create the SSRS reports and save them to the SharePoint document library.

image

Deploy SSRS Report from Visual Studio to SharePoint
  • To deploy the SSRS report using Visual studio 2008, you will need to point to the SharePoint Server site, not the Report Manager site. Using the example we created, you will need to set the TargetServerURL to be the http://localhost/, and set the TargetReportFolder to be http://Localhost/SSRS Report

image

  • Make sure you don’t append the “/” at end of the TargetReportFolder such as http://Localhost/SSRS Report/, otherwise you will get the following deployment error:

    Error rsItemNotFound : The item 'http://Localhost/SSRS Report//Demo SSRS.rdl' cannot be found.
    Deploy complete -- 1 errors, 1 warnings

image

Manage SSRS Data Sources, Parameters, and Permissions
  • Go to the right side of the report and click the drop down to open the Context Menu. You could set the data source, configure the parameters, or manage the permissions for the report by clicking on the corresponding context menu.

image

View SSRS Report
  • You could now view the report from SharePoint Site by clicking on the report itself.

image

  • Or view the report from the Report Server Site by navigating to the report directory.

image

Wednesday, February 16, 2011

View the error detail for SharePoint unexpected error

During setting up a SharePoint 2010 development machine, I often experience a generic SharePoint error (A dialog box with “An unexpected error has occurred.” message) that telling me nothing but error. Most naive SharePoint developer/designer/user will have no clue what is wrong and how to correct it. Sometime there is not enough information could be provided to the administrator or ask for help.

UnexpectedError 

Derek Sanderson recently posted a blog entry about how to get the REAL error to show on web page which helped me a lot to view the error detail on the screen, so I could Google/fix it without dig into the logs files that I may not have permission with.

Since there are two web applications, one for the SharePoint default site, another is the SharePoint Central Admin, I modified the web.config file on both sites accordingly.  I will only leave those settings on for a development machine or sandbox/QA servers.

You may also want to check this out now:

http://dereksan.blogspot.com/2011/02/sharepoint-20072010an-unexpected-error.html