cancel
Showing results for 
Search instead for 
Did you mean: 

Crystal Reports Java - replaceConnection

Former Member
0 Kudos

Hi,

I'm trying to integrate a Pervasive SQL Database with Crystal in an Java application covered with Maven.

I have the the Psql driver as a Maven dependency in my Artfactory repository.

I have the scenary where user uploads a File.rpt to the server and I replace their connections by mine that are registered in a DB when him request a PDF exportation of report.

All works well when the PSQL server is in my computer, the problem occours when I have the server in another host. My DB has security enable and I have a user to login, when I try from my host and DB is also in same host, I got success but when it's in different hosts I'm getting a :

[LNA][PSQL][SQL Engine][Data Record Manager]Invalid user authorization specification.

URI is formed by:

URI = "!" + driver + "!jdbc:pervasive://server:port/database;user=%s;password=%s"

In property bag I'm settings

propertyBag.put("Server Name", SERVERNAME); //Optional property.
propertyBag.put("Database Name", DATABASE_NAME);
propertyBag.put("URI", URI);
//propertyBag.put("JDBC Connection String", URI);
//propertyBag.put("Server Type", "JDBC (JNDI)");
propertyBag.put("Use JDBC", "true");
propertyBag.put("Database DLL", DATABASE_DLL);


connectionInfo.setAttributes(propertyBag);

Authentication:

// Set database username and password.
connectionInfo.setUserName(DBUSERNAME);
connectionInfo.setPassword(DBPASSWORD);
connectionInfo.setKind(ConnectionInfoKind.SQL);

from PSQL.

Any ideias to try to solve the problem?

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Anyone?