I have an Angular / Asp.Net Core web application. The report viewer component is working in the Angular application. Parameters are passed correctly. But when the report is loaded I get the error message in the viewer:
An error has occurred while processing Table 'crosstab1': Invalid key value.
The passed parameters values are displayed in textboxes so the report is loaded and rendered.
I guess it has something to do with the connection string that cannot be found.I created the report in the Report Designer application (so no class library/project which contains the reports) and the name of the connection string is "Reports" in the designer.
In the appsettings.json file I added an entry into the ConnectionStrings section with the name "Reports" (just as in the examples)
"ConnectionStrings": [ {"name": "Reports", "connectionString": "Data Source=.;Initial Catalog=DatabaseName;Integrated Security=True", "providerName": "System.Data.SqlClient" }]
I also created an app.config file with the connection strings
<?xml version="1.0" encoding="utf-8"?><configuration> <!-- To customize the asp.net core module uncomment and edit the following section. For more info see https://go.microsoft.com/fwlink/?linkid=838655 --> <!-- <system.webServer> <handlers> <remove name="aspNetCore"/> <add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModule" resourceType="Unspecified"/> </handlers> <aspNetCore processPath="%LAUNCHER_PATH%" arguments="%LAUNCHER_ARGS%" stdoutLogEnabled="false" stdoutLogFile=".\logs\stdout" /> </system.webServer> --> <connectionStrings> <add name="Reports" connectionString="Data Source=.;Initial Catalog=DatabaseName;Integrated Security=True" providerName="System.Data.SqlClient" /> </connectionStrings></configuration>
It seems that the Report Engine cannot find the connection string. Or does the Report Engine use another name for finding the connection string?