Crystal reports connecting to Azure SQL database.

2019-08-26 18:10发布

I have a vb.net application which currently uses crystal reports for VS and connects to an SQL Server 2008 database. The application now needs to use an SQL Azure database but when connected to the SQL Azure database is raising the following error for all of my crystal reports: -

The table '' could not be found. Error in file . The table could not be found. This error is being thrown by Crystal reports when the database connection is set. The stack trace is raised from my code but with the following Crystal reports trace: -

CrystalDecisions.ReportAppServer.Controllers.DatabaseControllerClass.SetTableLocation(ISCRTable CurTable, ISCRTable NewTable) at CrystalDecisions.CrystalReports.Engine.Table.set_Location(String value)

The report actually uses a stored procedure which I have verified is on the Azure database.

To try and resolve this I went to the database expert in the report designer, connected to the database and intended to just check the stored procedure was actually showing for the report, however when connected the database expert is only showing tables and views and no stored procedures. The username I am using is actually the master user for the Azure SQL Database and when using any other tool (for example using Microsoft SQL Server management studio or SQL Server object explorer) the stored procedures and visible and accessible and can be run without any issues.

As soon as I switch back to the SQL Server 2008 database the report runs fine. I would normally assume this is a database permissions issue but given the above evidence I don't believe it to be so. Is anyone using Crystal reports for visual studio connecting to an Azure SQL database from within an application?

I am using the crystal reports for visual studio 13.2 libraries.

2条回答
孤傲高冷的网名
2楼-- · 2019-08-26 19:02

I found I was getting the error "The table %s could not be found" when using an Azure database and the Report Option "Verify Stored Procedures on First Refresh" was on.

Turning this off and the error no longer occurred. This did not occur with non-Azure databases.

However, another problem is that both SAP Crystal Reports, version for Visual Studio (SP 10) and The full Crystal 2013 (SP4) cannot see Azure SQL stored procs in the designer.

I had to work-around that by exporting the database from Azure and restoring it to a local SQL server, build the report against the local server. I could then run the report against the Azure database.

EDIT: It should be noted the the official stance from SAP is that Crystal Reports does not support Azure SQL and there are currently no plans to do so. Source: http://scn.sap.com/thread/3430662

查看更多
We Are One
3楼-- · 2019-08-26 19:07

Check the Firewall Rules in Azure.

In Panel -> Configure

Israel

查看更多
登录 后发表回答