hi, i have checked the previous post and none of them is similar as my case
my case is some users are able to print (administrator, and some users have relatively higher right in the security roles), but some of them cannot. thus, i think maybe i can just trigger some security roles to let them able to print the reports instead
of changing the sql string.
this is the error thread when i tried to open the report in event handler:
Thread information:
Thread ID: 11
Thread account name: NT AUTHORITY\NETWORK SERVICE
Is impersonating: False
Stack trace: at Microsoft.Crm.Web.Reporting.SrsReportViewer.ReportErrorHandler(Object sender, ReportErrorEventArgs e)
at Microsoft.Reporting.WebForms.ReportViewer.OnError(Exception e)
at Microsoft.Reporting.WebForms.ReportViewer.OnPreRender(EventArgs e)
at System.Web.UI.Control.PreRenderRecursiveInternal()
at System.Web.UI.Control.PreRenderRecursiveInternal()
at System.Web.UI.Control.PreRenderRecursiveInternal()
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
actually i can open the report if i erased some user information dataset from the CRM default report (which fetching the user name/date from CRM database, such as CRM_CalendarType). i knew it is the security roles problem , but i dont know which switchs
is required to change, and i dont want to erase the user information dataset from the reports.
this is one of the sql strings caused the error (default from CRM default report)
SELECT DateFormat, DateFormat + ' ' + TimeFormat AS DateTimeFormat, NumberLanguageCode, CalendarType, NumberFormat_0_Precision, NumberFormat_1_Precision, NumberFormat_2_Precision, NumberFormat_3_Precision, NumberFormat_4_Precision, NumberFormat_5_Precision,
CurrencyFormat_0_Precision, CurrencyFormat_1_Precision, CurrencyFormat_2_Precision, CurrencyFormat_3_Precision, CurrencyFormat_4_Precision, CurrencyFormat_5_Precision FROM dbo.fn_GetFormatStrings().
but if i remove all of them that required dbo.fn_GetFormatStrings() or dbo.fn_FindUserGuid(), the user can open report contains the datatable such as FilteredAccount and so on with no problem.
thanks