SQL Server Reporting Studio report showing “ERROR#

2020-06-08 05:32发布

I struggled with this issue for too long before finally tracking down how to avoid/fix it. It seems like something that should be on StackOverflow for the benefit of others.

I had an SSRS report where the query worked fine and displayed the string results I expected. However, when I tried to add that field to the report, it kept showing "ERROR#". I was eventually able to find a little bit more info:

The Value expression used in [textbox] returned a data type that is not valid.

But, I knew my data was valid.

3条回答
劫难
2楼-- · 2020-06-08 05:49

Found the answer here.

Basically, it's a problem with caching and you need to delete the ".data" file that is created in the same directory as your report. Some also suggested copying the query/report to a new report, but that appears to be the hard way to achieve the same thing. I deleted the .data file for the report I was having trouble with and it immediately started working as-expected.

查看更多
不美不萌又怎样
3楼-- · 2020-06-08 06:02

After you preview the report, click the refresh button on the report and it will pull the data again creating an updated rdl.data file.

查看更多
对你真心纯属浪费
4楼-- · 2020-06-08 06:14

Another solution to this issue is to click Refresh Fields in the Dataset Properties menu.

This will update the list of fields, and force SSRS to get new data, rather than relying on a cached version.

查看更多
登录 后发表回答