By:Dallas Snider || Related Tips: > Reporting Services Development

Problem

When deploying a report in SQL Server Reporting Services, I am receiving an exception error stating "Maximum request length exceeded" as shown below. How do I resolve this?


Resolving the Maximum Request Length Exceeded Exception in SQL Server Reporting  ...
Solution

By default, the maximum file size that can be deployed to SQL Server Reporting Services is 4 megabytes. In this tip we will walk through the steps on how to resolve this exception error. The examples shown here are on windows 10 using SQL Server 2016.

The first step is to go to the directory holding the Report Definition Language (*.rdl) files to examine the size of the files we are attempting to deploy. Notice the highlighted file exceeds 4 MB so we know we are on the right track. This particular report file has an ESRI map embedded in it.


Resolving the Maximum Request Length Exceeded Exception in SQL Server Reporting  ...

The second step requires us to edit the web.config file for the ReportServer. Go to the ReportServer sub-directory where SQL Server Reporting Services is installed. In this example, the path to the ReportServer directory is C:\Program Files\Microsoft SQL Server\MSRS13.mssqlSERVER\Reporting Services\ReportServer.


Resolving the Maximum Request Length Exceeded Exception in SQL Server Reporting  ...

Make a backup copy of the web.config file.


Resolving the Maximum Request Length Exceeded Exception in SQL Server Reporting  ...

Open the web.config file with a text editor such as Notepad. If Visual Studio is installed, double-clicking on web.config should open the file in Visual Studio.


Resolving the Maximum Request Length Exceeded Exception in SQL Server Reporting  ...

Search the web.config file for httpRunTime.


Resolving the Maximum Request Length Exceeded Exception in SQL Server Reporting  ...

Add maxRequestLength with a file size in bytes. In this example we are setting the maxRequestLength to 8388608 which is 8 MB. Save the web.config file.


Resolving the Maximum Request Length Exceeded Exception in SQL Server Reporting  ...

The changes to the web.config file do not become effective until Reporting Services is restarted. We can restart the service through the Reporting Services Configuration Manager, the Services application, or by rebooting.

To restart the service through the Reporting Services Configuration Manager, start the Reporting Services Configuration Manager.


Resolving the Maximum Request Length Exceeded Exception in SQL Server Reporting  ...

Connect to the server.


Resolving the Maximum Request Length Exceeded Exception in SQL Server Reporting  ...

Stop the service.


Resolving the Maximum Request Length Exceeded Exception in SQL Server Reporting  ...

Start the service. After the service has started the changes should be in place.


Resolving the Maximum Request Length Exceeded Exception in SQL Server Reporting  ...

To restart Reporting Services through the Services application, scroll down to SQL Server Reporting Services, right click and then select restart.


Resolving the Maximum Request Length Exceeded Exception in SQL Server Reporting  ...

Deploy the report(s) again from Visual Studio.


Resolving the Maximum Request Length Exceeded Exception in SQL Server Reporting  ...

This time the deployment was successful.


Resolving the Maximum Request Length Exceeded Exception in SQL Server Reporting  ...
Next Steps

Please make sure that your report renders correctly in the SQL Server Reporting Services Web Portal. Also, please check out the following tips onwww.mssqltips.com.

Create a Greenbar Report in SQL Server Reporting Services Remove Question Mark and Show Correct Total Number of Pages in SSRS Report SQL Server Reporting Services Expression Builder to Reformat or Convert Text Box Values Determining who is viewing reports in SQL Server 2012 Reporting Services Plotting a Bell Curve in SQL Server Reporting Services

Last Update: 2/7/2017


Resolving the Maximum Request Length Exceeded Exception in SQL Server Reporting  ...
Resolving the Maximum Request Length Exceeded Exception in SQL Server Reporting  ...
About the author
Resolving the Maximum Request Length Exceeded Exception in SQL Server Reporting  ...
Dr. Dallas Snider is an Assistant Professor in the Computer Science Department at the University of West Florida and has 18+ years of SQL experience. View all my tips

Related Resources

More Business Intelligence Tips...

本文数据库(mssql)相关术语:熊片数据库 mssql数据库 oracle数据库 pubmed数据库 access数据库 万方数据库

分页:12
转载请注明
本文标题:Resolving the Maximum Request Length Exceeded Exception in SQL Server Reporting ...
本站链接:http://www.codesec.net/view/531772.html
分享请点击:


1.凡CodeSecTeam转载的文章,均出自其它媒体或其他官网介绍,目的在于传递更多的信息,并不代表本站赞同其观点和其真实性负责;
2.转载的文章仅代表原创作者观点,与本站无关。其原创性以及文中陈述文字和内容未经本站证实,本站对该文以及其中全部或者部分内容、文字的真实性、完整性、及时性,不作出任何保证或承若;
3.如本站转载稿涉及版权等问题,请作者及时联系本站,我们会及时处理。
登录后可拥有收藏文章、关注作者等权限...
技术大类 技术大类 | 数据库(mssql) | 评论(0) | 阅读(73)