Transient error in SSRS reports.

Nivedita Rao 0 Reputation points
2025-01-22T05:16:44.49+00:00

When we open a report in SSRS web service url it sometimes fails with the below error. When the same report is opened in web portal url with the same account, it opens with no errors. If we open an SSMS session with the same user and run any stored procedure, and then open the SSRS reports from the web service url, the error goes away and does not appear again for sometime. It seems to be some kind of user caching issue, but I am not able to understand where or how to fix it. Any idea what the problem could be?

e ERROR: Throwing Microsoft.ReportingServices.ReportProcessing.ProcessingAbortedException: [AbnormalTermination:ReportProcessing], Microsoft.ReportingServices.ReportProcessing.ProcessingAbortedException: An error has occurred during report processing. ---> Microsoft.ReportingServices.ReportProcessing.ReportProcessingException: Query execution failed for dataset 'Data'. ---> System.Data.SqlClient.SqlException: String or binary data would be truncated.

The statement has been terminated.

at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action`1 wrapCloseInAction)

at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj, Boolean callerHasConnectionLock, Boolean asyncClose)

at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady)

at System.Data.SqlClient.SqlDataReader.TrySetMetaData(_SqlMetaDataSet metaData, Boolean moreInfo)

at System.Data.SqlClient.TdsParser.TryRun(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj, Boolean& dataReady)

at System.Data.SqlClient.SqlDataReader.TryConsumeMetaData()

at System.Data.SqlClient.SqlDataReader.get_MetaData()

at System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds, RunBehavior runBehavior, String resetOptionsString, Boolean isInternal, Boolean forDescribeParameterEncryption, Boolean shouldCacheForAlwaysEncrypted)

at System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean async, Int32 timeout, Task& task, Boolean asyncWrite, Boolean inRetry, SqlDataReader ds, Boolean describeParameterEncryptionRequest)

at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method, TaskCompletionSource`1 completion, Int32 timeout, Task& task, Boolean& usedCache, Boolean asyncWrite, Boolean inRetry)

at System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String method)

at System.Data.SqlClient.SqlCommand.ExecuteReader(CommandBehavior behavior, String method)

at Microsoft.ReportingServices.DataExtensions.SqlCommandWrapperExtension.CreateDataReader(CommandBehavior behavior)

at Microsoft.ReportingServices.DataExtensions.SqlCommandWrapperExtension.ExecuteReader(CommandBehavior behavior)

at Microsoft.ReportingServices.OnDemandProcessing.RuntimeLiveQueryExecutor.ExecuteReader(IJobContext jobContext, DataSourceErrorInspector errorInspector, String commandText)

--- End of inner exception stack trace ---

at Microsoft.ReportingServices.OnDemandProcessing.RuntimeLiveQueryExecutor.ExecuteReader(IJobContext jobContext,

library!ReportServer_0-1!4184!01/22/2025-11:22:17:: w WARN: Microsoft.ReportingServices.ReportProcessing.ProcessingAbortedException: An error has occurred during report processing. ---> Microsoft.ReportingServices.ReportProcessing.ReportProcessingException: Query execution failed for dataset 'Data'. ---> System.Data.SqlClient.SqlException: String or binary data would be truncated.

The statement has been terminated.

SQL Server
SQL Server
A family of Microsoft relational database management and analysis systems for e-commerce, line-of-business, and data warehousing solutions.
14,377 questions
SQL Server Reporting Services
SQL Server Reporting Services
A SQL Server technology that supports the creation, management, and delivery of both traditional, paper-oriented reports and interactive, web-based reports.
2,983 questions
{count} votes

3 answers

Sort by: Most helpful
  1. Greg Low 1,930 Reputation points Microsoft Regional Director
    2025-01-24T09:39:08.9366667+00:00

    In the end, it's telling you that somewhere in your code, you are retrieving a string value into a column that's declared as too small for it.
    Check the size of any string values in your datasets, and also the size of any temporary table columns, if you've used any in the stored procedure.

    0 comments No comments

  2. Ravi Garg 0 Reputation points
    2025-01-24T13:10:11.51+00:00

    in SSRS , rdl uses stored procedure to fetch the data as source of the report. Than the RDL perform ETL operations as designed. As per error it seems strings in original source is of higher size while on report output ( where conversion is done) is of small size.

    0 comments No comments

  3. Ravi Garg 0 Reputation points
    2025-01-24T13:10:36.95+00:00

    in SSRS , rdl uses stored procedure to fetch the data as source of the report. Than the RDL perform ETL operations as designed. As per error it seems strings in original source is of higher size while on report output ( where conversion is done) is of small size.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.