SQL database: Message 'Dynamic SQL generation' displays when trying to run a report

Problem:
An error message stating: 'System.InvalidOperationException: Dynamic SQL generation for the UpdateCommand is not supported against a SelectCommand that does not return any key column information' displays when trying to run a report.

Solution: 
This 'Dynamic SQL generation for the UpdateCommand' error message comes from a lack of permissions on the SQL Server database called TEMPDB.
To correct this situation, please:
  • Reach the tempdb database with SQL Server Enterprise Manager;
  • Check that the PROMODAG Reports user belongs to the public and  db_datareader roles;
  • Run the report again after having set those rights.
Notes:
  • TEMPDB is deleted and recreated each time your SQL server restarts and therefore permissions disappear. You should add these permissions to the model database in SQL Server.
  • This problem has only been reported by customers using Microsoft SQL Server 2000. It does not occur with SQL Server 2005 or SQL Server 2008.

Add Feedback