Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

PERVASIVE LIBRARIES FOR DIRECT ACCESS

Status
Not open for further replies.

manza

IS-IT--Management
Sep 26, 2001
20
ES
Hi.

I have configured a report in CR 8.5 Prof with the direct access to Data Files for Pervasive 8.

If I execute the report, everything works fine.

If I try Verify Database, CR tells me: "Choose Database File". Then I select the .ddf (FILE.DDF) and the answer is:

Crystal Reports: Database Error. Betrieve error status: 0

I have tested that the necesary dll's are loaded: p2bbtrv.dll, p2ctbtrv.dll, s2dtconv.dll, wbtrv32.dll, sbtrvd32.dll

The problem is that I have created a VB .NET program that execute a Report with parameters and export it to pdf format, and it gives me the following error:

"Excepción no controlada: CrystalDecisions.CrystalReports.Engine.DataSourceException: No es posible cargar la información de la base de datos."

... I think the translation will be:

"Not controlled exceptiom: CrystalDecisions.CrystalReports.Engine.DataSourceException: It is not possible to load the information from the data base."

I supose that if I solve the problem with "Verify Database" I will correct the problem with the program.



Thanks in advance.
 
Well, a Btrieve status 0 is a successful return. If Crystal is reporting it as an error, then Crystal needs to address it.
As for the problem at hand, I have seen strange errors like this one when there are no records in the result.
Since you're using PSQL v8 and you have the DDFs, you might try using ODBC rather than the native Btrieve drivers to see if it helps.


Mirtheil
Certified Pervasive Developer
Certified Pervasive Technician
 
Hello.
Well, I've discovered that the DDF I was pointing was nos the correct one. But, even pointing the correct one (trhough Pervasive Control Center I add the Database using this DDF) the response from "Verify Database" is:
Betrieve [4]: key value not found
Please give location of Info View or dictionary used to create this report

I have used the ODBC option, but the performance is very poor: with direct access the report takes 15 secs, with ODBC it takes 3 mins.

Thanks in advance
 
Sounds like you've got some incomplete or incorrect DDFs. If you're getting a status 4 (key value not found), the PSQL engine may not be able to optimize properly.
Since you're using V8, I would suggest running a Database CHeck (right click the database name in the PCC and select "Tasks" then "Check Database"). Make sure to test the tables in your query and the system tables (tables that start with "X$"). Post the results.

Mirtheil
Certified Pervasive Developer
Certified Pervasive Technician
 
Hello.
I have run the Database Check.
The tables included on my report, and the system tables pass the consistency test.

Several tables (not included on my report) don't pass the check consistency. I receive 3 types of error:
- Illegal table name: TTTT/TTTT
- Illegal column name: CCCC/CCCC
- The data file index is not defined on the dictionary
- DCM Error 0x510. The table data file doesn't exist.

Regards.
 
Yes, the 3 system tables passed the check.
 
Strange:

- When I open the DDF on Crystal, I always have to change the location of the data files, because Crystal "interpretes" DDF and "think" that the Data File is on the same path as the DDF.
- When I open the PCC and select properties on the Data File, the path is correctly set.
- When I try to change the path on PCC (trhough statistics), nothing seems to change on PCC, but when I open Crystal, the new location of the data file has changed to 'C:\DOCUME~1\ADMINI~1\ESCRIT~1\DATA...'
- Through PCC, I've created another DB and copy (drag & drop) tables from my "bad" DB to the new one. Everything works fine.

CR and PCC seem to interprete the DDF on different ways, relating to Data File Path.

The solution of copying tables between DBs is not good for me. I would rather prefer to regenerate the DDFs if it is possible.

Regards.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top