SP2013: dealing with $Resources:ReportServerResources… error

Working with SharePoint site templates is one of those dark sides of SharePoint, which often ends up with errors, leaves you solely with a correlation GUID and takes some more hours of your worktime. I’m not sure if it happens more often when saving template, or creating site from a template. Anyway, I’ll describe one of such problems and the *workaround* that worked for me. Beware, I’m not an expert in subject, I just needed to solve this case quickly.

The problematic Report Server content types

There’s a problem that might appear when the site is created from a previously saved template. The message shows:

The content type name ‘$Resources:ReportServerResources,DataSourceContentTypeName;’ cannot contain: \ / : * ? “ # % < > { } | ~ & , two consecutive periods (..), or special characters such as a tab.

From what I suppose, the problem comes from the fact, that the template has been created on the server with SSRS integration with SharePoint installed. If the sharepoint content database was migrated, or copied from another server (e.g. on upgrading development environment), or you removed ReportServer feature after creating the template, the template will contain reference to the ReportServer resources that are now missing. Therefore, it can’t be used to create new site on its base.

Re-create missing resources

What might help then? I’d try the following:

  1. If only one template is problematic, and it’s not very complicated one (you can recreate it in under 30 minutes), recreate the template. You will avoid disappointment, if it turns out not to be the only problem with the template.
  2. You might try to rename the invalid content types. For some people this seem to work well (here’s another example). I wasn’t able to do this in my environment, because update had no effect on those particular content types.
  3. If both of the above failed, install rsSharePoint.msi. Even if you don’t need the integration, simply installing the add-in will add missing resources/content types, and the problem should go away.

I was able to resolve this problem twice this way. Good luck!