Print Page | Close Window

"The table (-1) does not exists in the document"

Printed From: Crystal Reports Book
Category: Crystal Reports 9 through 2022
Forum Name: Technical Questions
Forum Discription: Formulas, charting data, Crystal syntax, etc.
URL: http://www.crystalreportsbook.com/forum/forum_posts.asp?TID=17896
Printed Date: 02 May 2025 at 5:50pm


Topic: "The table (-1) does not exists in the document"
Posted By: Renuka
Subject: "The table (-1) does not exists in the document"
Date Posted: 01 Nov 2012 at 2:25am

We are facing below exception when Crystal report 2008 is upgraded from SP3 to SP5.

"The table (-1) does not exists in the document"

We were using Visual Studio 2010 .NET framework 4.0 and Crystal report 2008 SP3.

Now it is upgraded to SP5.

.rpt file is read using Filestream and rpt object is created and saved in database.

This rpt file is saved at temporary location and loaded in Report Document object aRptdoc

 

  Database crDatabase = aRptDoc.Database;

Tables crTables = crDatabase.Tables;

 

for

 

(int i = 0; i < crTables.Count; i++)

{

crTable = crTables; 

TableLogInfo crTableLogonInfo = crTable.LogonInfo;

crTableLogonInfo.ConnectionInfo = aCrConnectionInfo;

crTable.ApplyLogonInfo(crTableLogonInfo);

bool test = crTable.TestConnectivity();

 

}

crTable.Testconnectivity is throwing the exception.

This issue is faced for report that were created using SP3 and trying to acess after upgradation is done.

If we download the report, change database setting and run in crystal report SP5 and upload in the application.

Testconnectivity method doesn't throw exception.

Can anyone help in understanding why this happens?

What happens when SP3 is upgraded to SP5?

How can this problem be resolved?




Print Page | Close Window