Manage runtime report errors

Zolotoy 226 Reputation points
2020-10-15T14:24:52.54+00:00

When an runtime error occurs the report server returns a stack trace. Is it possible to suppress that or provide a custom error?

Thanks

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.
3,061 questions
0 comments No comments
{count} votes

3 answers

Sort by: Most helpful
  1. Joyzhao-MSFT 15,631 Reputation points
    2020-10-16T04:00:05.937+00:00

    Hi,
    I'm not sure if you need to write a runtime error reporting function, if so, please refer to: Writing a runtime error reporting function.
    Regards,
    Joy


    If the answer is helpful, please click "Accept Answer" and upvote it.
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


  2. mark goldin 696 Reputation points
    2020-10-16T10:11:13.963+00:00

    Is there an example in C#?

    0 comments No comments

  3. mark goldin 696 Reputation points
    2020-10-19T21:47:27.717+00:00

    can this be supressed:
    ystem.Data.SqlClient.SqlException (0x80131904): Could not find server '<server name>' in sys.servers. Verify that the correct server name was specified. If necessary, execute the stored procedure sp_addlinkedserver to add the server to sys.servers. at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection, Action1 wrapCloseInAction) at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection, Action1 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.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, TaskCompletionSource1 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 System.Data.SqlClient.SqlCommand.ExecuteReader() at InStep.Prism.Common.Services.Reports.CustomReportProxyData.ReportData(List1 queryParameters) in ReportViewer.aspx.cs:line 202 ClientConnectionId:e90f91ad-d7dd-4535-88f3-cf4b3b3850d2 Error Number:7202,State:2,Class:11


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.