Results 1 to 6 of 6
  1. #1
    Join Date
    Mar 2016
    Posts
    3

    Unanswered: Error retrieving error information - Connecting to database via jdbc

    I have locally hosted Pervasive PSQL 10. Workgroup is set up and engine is working. There is database and i want to connect to it via jdbc but whatever i try to do i get http://pastebin.com/7HKYse0U
    These are my properties:
    sale_system.connection.driver_class=com.pervasive. jdbc.v2.Driver
    sale_system.connection.url=jdbc:pervasive://localhost:1583/databasename
    sale_system.connection.username=user
    sale_system.connection.password=password

    I tried to add users to database and give them all permissions possible. I have also tried to connect via os user but nothing works.
    There was one topic on forum about it but links are not working, so i can't find the answer. Google is not my friend in this case too. Almost no results.
    I would appprieciate your help. Thanks in advance.

  2. #2
    Join Date
    Dec 2001
    Posts
    1,109
    Provided Answers: 4
    You mention that you are using the PSQL 10 workgroup. Are you running PSQL as a service or EXE? Is your application running as a scheduled task or a regular application?
    Is port 1583 open on the machine where the PSQL engine is running?
    Can you connect to the database using the PErvasive Control Center? If not, what error do you get? THe PCC uses JDBC to connect so it is a valid test of connectivity.
    Mirtheil Software
    Certified Pervasive Developer
    Certified Pervasive Technician
    Custom Btrieve/VB development
    http://www.mirtheil.com
    I do not answer questions by email. Please post on the forum.

  3. #3
    Join Date
    Mar 2016
    Posts
    3
    PSQL is running as EXE. I connect through web application(java based) deployed with jetty to database. Port 1583 is open, even tough i think it should make no difference as it is on the same machine(but i may be wrong). I can connect through PCC to database. Only problem is connection through JDBC with application. It seems that PCC uses different users and passwords to connect to databases. Somebody i talked with suggested it may be ownership related problem but i really can't tell where it may be.

  4. #4
    Join Date
    Dec 2001
    Posts
    1,109
    Provided Answers: 4
    If PCC can connect to the database then both the the engine and JDBC are working as PCC uses JDBC.
    If you use the same user / password from the PCC, does the JDBC application work?
    Since the engine is running as EXE, is the machine logged in when the JDBC web application is being run?
    Mirtheil Software
    Certified Pervasive Developer
    Certified Pervasive Technician
    Custom Btrieve/VB development
    http://www.mirtheil.com
    I do not answer questions by email. Please post on the forum.

  5. #5
    Join Date
    Mar 2016
    Posts
    3
    Machine is logged in when i test it. Either way, web app is configured in a way that allows it to work even if user is not logged.
    I tried to use master user and database users to connect to database, the same users were used to connect with PCC. These users had max permissions over database. I have also tried with user that had only permissions to select but effect was the same. Neither worked.
    In all cases there is ,,Error retrieving error information" stacktrace. To mention the same web app(i mean same jdbc driver) is running smoothly on another Pervasive PSQL but version 9 on another server(however this was set up long ago).

  6. #6
    Join Date
    Dec 2001
    Posts
    1,109
    Provided Answers: 4
    Machine is logged in when i test it. Either way, web app is configured in a way that allows it to work even if user is not logged.
    The web app may work, but if the PSQL engine is running as an EXE, it won't be running if no one is logged in. For a Web App, I would suggest running it as a Service.

    In all cases there is ,,Error retrieving error information" stacktrace.
    What's the full stack trace?

    If the app works fine in other environments and is set up the same way in this environment but doesn't work, then the problem is the environment.
    Mirtheil Software
    Certified Pervasive Developer
    Certified Pervasive Technician
    Custom Btrieve/VB development
    http://www.mirtheil.com
    I do not answer questions by email. Please post on the forum.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •