title: Insufficient privilege to run as user SSRS and CRM2011
body: <p>I am attempting to generate a Dynamics CRM 2011 SSRS report programatically. </p>
  
  <p>I am receiving the following error:</p>
  
  <pre><code>Microsoft.Crm.Reporting.DataExtensionShim.Common.ReportExecutionException: Caller S-1-5-21-3239909829-2541432921-3578859411-1114 has insufficient privilege to run report as user 519f1b51-1f3a-e411-80be-00155d823202
  </code></pre>
  
  <p>The second Guid is the id of the CRM user that I use to authenticate against the CRM and the credntials of who are passed to the report. (CRM Reports take the userid as a username and the organisation id as the password).</p>
  
  <p>The first Guid is, I suspect, the user that my SSRS reporting service runs under (domain\sql_reports)</p>
  
  <p>Firstly, this works fine in my development environment (I hate saying that).
  Secondly, I have checked the following:</p>
  
  <ul>
  <li>sql_reports user is a member of the appropriate PrivUserGroup, PrivReportingGroup, SqlAccessGroup and ReportingGroup</li>
  <li>I can correctly run the report via CRM</li>
  <li>I can correclty run the report via the <code>http://server/reports</code> interface when I supply the appropriate credentials</li>
  </ul>
  
  <p>The error I receive is only when I programtically attempt to generate this report from a custom application. As mentioned above, this is only an issue in the production environment. I have other components of this application that read/write to the CRM without any issue in the production environment.</p>
  
  <p>I am running SQL Server 2012 &amp; Reporting Services, and Dynamics CRM 2011 (all components are patched to UR17).</p>
  
  <p>The SQL Server, Reporting Services &amp; Dynamics Reporting Extensions are installed on one machine and CRM is installed on another.</p>
  
  <p>Any help would be greatly appreciated!</p>