SSRS 2012 Custom Code .NET Framework 4.0 not supported - reporting-services

I was very hopeful that since SQL Server 2012 SQLCLR supports .NET 4.0 that SQL Server Reporting Services (SSRS) 2012 would support .NET 4.0 custom code assemblies. When attempting to upload an rdl (via the Report Manager or via RSBuild) that references .NET 4.0 assemblies, the Reports Manager throws an error stating
This assembly is built by a runtime newer than the currently loaded
runtime and cannot be loaded. (rsErrorLoadingCodeModule)
Is there something I can configure to get SSRS 2012 to load .NET 4.0 assemblies? Will we be waiting until the next major release of SQL Server before we see .NET 4.0 support for custom assemblies in SSRS?

SSRS 2014 is now released and custom code still does not support the .Net 4.0 Framework.
See prerequisites in the "Hardware and Software Requirements for Installing SQL Server 2014"
(http://msdn.microsoft.com/en-us/library/ms143506(v=sql.120).aspx)
It's very amusing that SQL Server 2014 has just RTM'ed a few days ago and is already considered a "legacy application" by the .Net Framework guys who say:
.NET Framework 3.5 is not included by default in Windows 8 or Windows
Server 2012, but you can download and deploy it for legacy application
compatibility.
... see "Microsoft .NET Framework 3.5 Deployment Considerations"
(http://technet.microsoft.com/en-us/library/dn482066.aspx)
I think the bigger issue is whether the support lifecycle of .Net 3.5 SP1 can actually be tied to the OS'es for which it was a default component. Whatever they say, I can't see Microsoft quitting support on .Net 3.5 as long as SQL Server continues making it a prerequisite in a product they are releasing today. The .Net Framework guys can't be too happy with the lazy SQL guys right now...

Actually, I find that reports using .Net 4.0 assemblies will work fine in VS 2010 (PreviewProcessingService.exe)...
And the reports may also work for you when deploying them to SSRS 2012 SP1 in SharePoint 2013 integrated mode.
Here is the authoritative answer on when/where the .Net 4.0 CLR is supported by SSRS: http://support.microsoft.com/kb/2869522/en-us
For those of us who use SSRS in standalone mode (without SharePoint), we might be stuck on the .Net 2.0 CLR for a while.

I might be wrong and there might be more differences but having compared reports downloaded from reporting services and "identical" ones made in Visual Studio using .Net framework 4.0+ I think the only difference is that puts a ReportParametersLayout section in the xml. If you manually remove this from the xml version of the report file then upload hopefully it will work for you

Related

Change .NET Framework in Integration Services Project

When creating a new Integration Services Project in Visual Studio 2013 I can select the .NET framework to target. How can I see what .NET framework is being targeted on an existing project and potentially change it?
You need to open one of the Script Tasks and click the "Edit script..." button. This will open the script on a new instance of Visual Studio with the script in its own project. There you can change the properties of that project to modify the targeted framework for that particular Script Task.
There is no .NET Framework targeting for SSIS packages. However, there IS SQL Server version targeting. Prior to Visual Studio (VS) 2015, it was a bit of a mess: you could only target a specific version of SQL Server with a specific version of Visual Studio. For example:
SQL 2008 = VS 2008
SQL 2012 = VS 2012
SQL 2014 = VS 2013
With the release of VS 2015, however, Microsoft alleviated some of the headache by introducing SQL Server targeting within VS by just right clicking on the solution, going to properties, and selecting the version of SQL Server that the SSIS package would run on. This is important because it determines what components are available to use.
Now, with that being said, there is .NET Framework targeting within script tasks/components. To read more about that, check my answer at:
SSIS Script Keeps Reverting To .Net Framework 4.5

Visual Studio 2015 Community with MS SQLServer 2008 Express

Is there anybody having successfully connecting VS2015 to SQLServer 2008 (original, not R2) Express? the SQLServer seems to be running fine (connection using Management studio is okay) but I could not get connected to it using VS15. The error says something about the Microsoft.SqlServer.Management.Sdk.Sfc, Version=12.0.0.0 assembly
This post provides a nice solution to some cases but it does not seem to work in mine. If I understand correctly, the VS15 assumes the use of SharedManagementObject assembly 12.0.0.0 for Sqlserver 2014. But I'm running 2008 version and this package certainly cannot be installed.
Anybody knows a workaround for it?
== UPDATED according to my answer ==
So what if I deploy my application, which uses Entity Framework (for which I need to connect VS to SQLServer), on a machine that does not run VS2015, nor some items from the feature pack?
Thank you!
Well I was stupid. And it turns out, indeed, to be the problem of visual studio 2015 always assuming the assembly for SQLServer2014. I ended up installing 2 items from the SQL server 2014 feature pack including:
System CLR Types, which is the prerequisites for
Management Objects
And restart the Visual Studio (it would not work without this damn critical step).

Cannot find ReportViewer and ScriptManager controls in .NET Framework 2.0

I have a project developed on .NET Framework 2.0. Now I want to include an SSRS Report to this project but I am unable to find ScriptManager and ReportViewer controls in my toolbox. These are available in .NET Framework 4.0, so what do I have to do to create SSRS report for Framework 2.0
.Net Framework 2.0 was released ten years ago, so ideally you should look to upgrade to a more recent version. However if you are stuck with 2.0 then you will need to use the Report Viewer control from SQL Server 2005, which can be downloaded from the Microsoft website:
https://www.microsoft.com/en-us/download/details.aspx?id=21916

Is the .Net 4.0 Runtime supported in SSRS + Sql Server 2008 R2?

In the upcoming release of Sql Server 2008 R2 (aka Sql Server 2010) can I write:
a) SSRS Extensions (eg Custom Authentication) against the .Net 4.0 runtime?
b) Sql Server CLR procedures in .Net 4.0?
Thanks,
Dan
It appears not according to a post by Doug Holland.
Work does appear to be happening to ensure that SQL 2008 (Express at least) will install on a machine with .NET 4.0, but even then it still only uses the 2.0 CLR.

SQLXML with Windows 2008 and SQL Server 2008

I have an application that uses SQLXML to access data on the database. We have it working on a Windows 2003 server and SQL Server 2005. Now the client wants to install it on Windows 2008 and SQL Server 2008 and we are getting errors like:
Microsoft.Data.SqlXml.SqlXmlException: Class not registered ---> System.Runtime.InteropServices.COMException (0x80040154): Class not registered at Microsoft.Data.SqlXml.Common.UnsafeNativeMethods.
ISQLXMLCommandManagedInterface.ExecuteToOutputStream() at Microsoft.Data.SqlXml.SqlXmlCommand.innerExecute(Stream strm)
... etc etc
This is driving me crazy. SQLXML is quite an obsolete technology, and we are trying to use it with the latest SO. I can't find official information about SQLXML and Windows 2008, it seems it's not officially supported but they don't say it's not supported either.
The SQLXML4.0SP1 installation seems to work fine, but it seems like it fails on runtime.
Do you have any ideas? Has someone tried anything like this?
The packages for SQLXML 4.0 SP1 were only available for download in the April 2009 release of the Microsoft SQL Server 2008 Feature Pack. Not sure why they don't appear in the 2008 R2 Feature Pack but they don't.
Here's your link to the Feature Pack
Direct links to the appropriate versions of SQLXML 4.0 SP1 can be found on that page
My recommendation would be to take advantage of the fact that it works on SQL 2005 to convert the code to not use SQLXML. You can take advantage of the fact it works to create tests that prove it works. Then do the conversion, and test again. If the tests still show it works, you've rid yourself of obsolete technology while there's still someone living who knows what the obsolete technology was meant to do.
Otherwise, after finding the fix for this immediate problem (maybe reinstall MSXML) you'll be having this discussion 20 years from now, but with the difference that nobody living knows what SQLXML used to be.
SQLXML is not installed to SQLServer by default. You should run SQL Server Installer, and add SQLXML feature.
I mean SQL Server 2008.
You are probably using ISAPI functionality, which is not supported in SQLXML 4.x
Install SQLXML 3.0 on Win 2008 Server (Vista,7) and for IIS 7.x change IIS 6 Management Compatibilty - allow IIS 6 Metabase Compatibility and IIS 6 Management Console (in Administrative Tools/Server Manager/"Roles - Webserver (IIS)"/ "Role Services" ).
On 64bit Win Server 2008 'Enable 32-bit Applications' for IIS/Application Pools.