When I run a report that has run for a few years with no problems, the report runs but I get the following error:
[rsFieldReference] The Value expression for the text box 'FieldName' refers to the field 'FieldName'.
Report item expressions can only refer to fields within the current dataset scope or, if inside an aggregate, the specified dataset scope. Letters in the names of fields must use the correct case.
However, the Value and the field name are identical ['FieldName']. And, the report runs correctly in Visual Studio [in spite of the error] and on the Report Server when it is deployed.
How do I get the error to stop showing up?
I suspect it is a 'residual' error that is persisting even though I can't see an actual 'error'.
We recently switched to a newer version of Visual Studio [2017] and I have made a slight change to the SQL in the Dataset [nothing to do with 'FieldName'].
Thanks!
Related
Adding a new parameter between parameters or reordering parameters in a ssrs report breaks it.
Using text only, can't upload any images... (Failed to upload image; an error occurred on the server)
I created a report that works using the cube "Analysis Services Tutorial".
Parameters: City, State-Province.
Table: State Province, City, Internet Sales Count
This report works fine, but when I change the order of parameters to:
State-Province, City
Then I get that error when previewing the report:
An error has occurred during report processing.
The Value expression for the query parameter 'CustomerCity' contains an error: The expression references the parameter 'CustomerCity', which does not exist in the Parameters collection. Letters in the names of parameters must use the correct case.
One solution that I currently see is modifying the content of the rdl-file.
Hope anyone has any other ideas/solutions what I can do...
Ah well only need to change the order of the parameters in the DataSet and with the context menu on right click I can also move the parameter up/down.
I am trying to create deployment job that would checkout from git and builds all the reports in the solution. If it can't build then I want that job to fail. I've created the simple report with dataset as "select 1 as one" and then added 1 non existing column reference in the report. When I tried to build it with Visual Studio it is failing, however it is successfully build with the MSBuild ... What can be the issue?
Severity Code Description Project File Line Suppression State
Error [rsFieldReference] The Value expression for the text box ‘one’
refers to the field ‘one1’. Report item expressions can only refer to
fields within the current dataset scope or, if inside an aggregate,
the specified dataset scope. Letters in the names of fields must use
the correct case. C:\Users\kultasev\Repos\mfi-online-reports\MFI
Online Reports\broken_report.rdl 0
I'm working on a complex SSRS report that contains a number of subreport, with a total of five levels of nested sub-reports. This is a lot, but necessary due to the complicated nature of the top level report.
I've encountered an odd error with the last subreport I've added:
Warning 1 [rsErrorExecutingSubreport] An error occurred while executing the subreport 'ThingRateQuotaWrapper' (Instance: T0R0S0S1T0R0x0S0): Object reference not set to an instance of an object. C:\Users\mmxxxxxxx\Documents\Visual Studio 2012\ThingsReporting\ThingsReporting\Thing 2014 Consolidated Report.rdl 0 0
The problem here is that when I run the second level report (one of the reports contained in the top level "consolidated" report), everything works fine. But in the top level report, I get this unepected error.
The specific subreport mentioned is four levels down from the top report, so I would expected the second level report to fail if there was an issue, however as just mentioned that works perfectly.
In addition, the RDL and line number mentioned in the error message tells me nothing useful.
I've tried everything I can think of to solve this problem, including deleting, saving, re-inserting and configuring all the subreports from the ThingRateQuotaWrapper upwards. At this point I can think of nothing else to try that makes any sense.
How can a report fail because of a sub report four levels down, when other reports in between work correctly?
Anyone got any ideas or tips? I'm using SQL Server 2012 Business Intelligence and Visual Studio Premium 2012.
I've solved this problem, however I don't entirely understand the solution so I welcome any comments which might expand on it.
My approach was to look through each expression in the set of reports and subreports that make up my consolidated report, looking for any that might fail for any reason. I discovered that the visibility expression for the tablix row which contains the ThingRateQuotaWrapper subreport had the dreaded red squiggly line beneath it.
I believe the cause of the field warning is that the visibility expressed used a dataset other than the primary dataset of the tablix. I reworked the tablix dataset to contain the required column to determine visibility of the subreport, then updated the visibility expression to use the new column in the primary dataset. This fixed the problem.
This issue still impact SSRS in Visual Studio 2017 when renaming a sub-report.
Delete all the object in the \bin\ folder and VS will rebuild it without the error.
In my case, sub report's name had been changed (params and everything were correct) just name had been changed. Lead to this error.
This tends to happen when you change the names on reports. I accomplished this by deleting the .data files in my project directory as this stores the cached data of your reports. Then restart visual studios and the problem should be resolved.
In short:
Delete .DATA files in directory
Restart Visual Studios
Hope this helps.
Thanks
Gavin
To anyone coming to this old thread, I had the exact same error message with the following configuration:
Main report (top parent level report) calls 5 sub report hierarchy deep
The sub report is crashing only when generating from the Main report. Everything is fine when calling from each sub report level (all!) including the sub report itself
Pre-requisite explanation
The business wants me to show either a Bar chart OR a textbox on a dedicated condition.
To avoid empty spaces produced by a ReportItem (my subReport outputing a bar chart) that is hidden, I usually put them inside a Tablix and manage the Row visibility. Like that, no empty spaces is generated !
Old structure causing issue
I have one tablix with two rows :
The first one contains my sub report outputting a bar chart
The second one contains a simple TextBox
The tablix's dataset is a dataset containing the Textbox's text value (and that's the key of the problem !)
New structure fixing the issue
I have now 2 tablix :
One tablix with a dummy dataset ("SELECT 1 as 'Dummy') associated to the tablix. This tablix calls the bar chart's sub report
A second tablix with the same dataset as before (containing the Textbox's text value)
UPDATE 29.06.2022
The solution described above worked without RowVisibility condition. As soon as I've added my expression it fails again :
=IIF(RowNumber("myDataSetName")=0, True, False)
Solution: replace by this condition instead :
=IIF(Count(Fields!MyFieldName.Value) = 0, True, False)
This produces the same : When there the SQL query returns no row, I want to hide it.
It's very strange that SSRS doesn't tell my expression is wrong somehow, and last but not least, it's very weird that the expression works in all report levels except from the Main report. Either an expression is wrong or not.
Looks like a bug in SSRS (SQL Server 2017...maybe it's fixed in SQL Server 2019)
I am using Sql Server Reporting Services 2008 R2. When "previewing" my current report, I see everything appearing as it should. The displayed query values are correct in my table, which reads straight from the single dataset.
However, I see this as a warning:
Warning 1 [rsRuntimeErrorInExpression] The Value expression for the textrun ‘Textbox20.Paragraphs[0].TextRuns[0]’ contains an error: Input string was not in a correct format. E:\SSRS_Projects\Custom Reports\Attendance\Attendance\MIA_1B_Math_Absence_Detail.rdl 0 0
The puzzling thing is that I have no objects named "Textbox20."
I tried browsing thorough the object list on the "Properties" panel
and didn't see it.
I did a Ctrl+F search for "Textbox20" and couldn't find anything.
I'm not sure what else I can describe at this point.
Does anyone know how I can isolate the cause of this warning?
Thank you
If I understand correctly, the warning message was caused by the incorrect previous expression, however, the warning message persists although the values displays correctly in the report after you modified the expression. Besides, the warning message came out even though you create a new report and use the right expression.This is a known issue in Report Designer. When there is a warning message generated in the "Error List" pane of the Report Designer, the warning message still pops up after we correct the previous error. Actually, it always pops up whenever we preview any report in the same project. To avoid the issue, we only need to close the project and reopen the project. That way, the previous error lists will be cleared and the warning message won't pop out unless there is still an error in the report design.And your table's columns and rows are here text box.so please select the table column and see the property name.
Try Using this code
=IIF(IsNumeric(Fields!Data.Value),CSTR(FormatNumber(IIF(IsNumeric(Fields!Data.Value),Fields!Data.Value,0),2)),Fields!Data.Value)
I'm working with Visual Studio Reporting Services 2008, and I've come across an irritating problem. I have a cell in a table that uses a Lookup from one dataset to find the information to display in another. The code is as follows:
=Lookup(Fields!place_id.Value,
Fields!id.Value,
Fields!name.Value,
"Centres")
The place_id and id are from one dataset (Dataset1) and the other is from the dataset "Centres". This works fine in the preview, but not after deployment. When I try to deploy, I get an error message (where textbox22 is the cell in question):
The Value expression for the text box ‘Textbox22’ refers to the field ‘name’. Report item expressions can only refer to fields within the current dataset scope or, if inside an aggregate, the specified dataset scope.
Surely, by having "Centres" there in the expression, that is the specified scope. Any ideas?
Based on your shared information, I can say that your SSRS development version is SSRS2008R2 and your report server version is SSRS2008. Since Lookup function is not supported in SSRS2008 and lower version. This is the reason that you are getting this error in deployment whereas preview in working fine.
For any additional information regarding Lookup Function, you can take a look into Lookup Function