Trouble with PervasiveOLEDB 9.5 from dotNET C#

Last post 03-28-2013 3:54 AM by bhushan.nankar. 7 replies.
Page 1 of 1 (8 items)
Sort Posts: Previous Next
  • 08-16-2007 10:48 AM

    Trouble with PervasiveOLEDB 9.5 from dotNET C#

    We have a C# web service that is used to query several databases from various vendors. The program reads in SQL and connect string from a config file and uses the System.Data.Oledb package to access various OLE DB providers -- It works very well with all other databases. Using the Pervasive OLE DB provider, I am able to access the data in our customer's Pervasive database only intermittently. But more times than not, I receive the following exception:
    ========
    Source: PervasiveOLEDB.9.50
    Message: Unable to connect to the relational engine (is Database Name and Server Available?)
    ========
    And then sometimes I wait a minute and try again at it works. The data is on a remote server. I have tried many versions of connect string, but here is the latest one that works:
    ========
    Provider=PervasiveOLEDB;Data Source=\\DBSERVER\RMSDATA;Location=DBSERVER;User ID=XXX;Password=XXX
    ========
    As instructed in the documentation, when using a UNC path, I have an entry in the Windows registry for \\DBSERVER\RMSDATA so that the dialog box does not prompt. I have Pervasive.SQL 9 SP2 installed on the local machine and access to the database via Control Center is solid and consistent. Why am I having intermittent access via the OLE DB provider??
    Any help is greatly appreciated.
    Thanks,
    -Jonathan
  • 08-16-2007 11:24 AM In reply to

    Re: Trouble with PervasiveOLEDB 9.5 from dotNET C#

    Have you tried using the database name instead of the path? Does that reduce the error you are seeing?
  • 08-16-2007 11:43 AM In reply to

    Re: Trouble with PervasiveOLEDB 9.5 from dotNET C#

    Thanks for your suggestion! I tried using database name, rather than path, for the Data Source parameter. It appears to be the same frequency of errors (and same error message text). Some successes and some failures. And out of the times it is successful, the performance varies: sometimes a very fast response, sometimes very slow. There doesn't seem to be much rhyme or reason... I have tried several different SQL statements (queries) and several different combinations of connect string values with each SQL statement and all of them have worked at one point, but only some of the time, and no method more reliable than the another. I'm confused.
  • 08-16-2007 11:56 AM In reply to

    Re: Trouble with PervasiveOLEDB 9.5 from dotNET C#

    What PSQL is actually running on the remote machine? Is is PSQL 9.50? If so, which one (WGE, Server)?
    Also, is there anything in the PVSW.LOG on either the client or the server?
  • 08-16-2007 12:34 PM In reply to

    Re: Trouble with PervasiveOLEDB 9.5 from dotNET C#

    I really appreciate your help. There are not many resources on the OLE DB Provider.

    On the client, there is nothing in the PVSW.log since a week ago, the day PSQL Server was installed. But I have been testing this throughout the week.

    Unfortunately, I don't have direct access to the remote server, so I'll have to get w/ the customer's admin to answer your other questions. I'll do that ASAP and get back to you. In the meantime, I believe it was installed from the same disk so they should have PSQL Server 9 SP2 as well. My Control Center (working like a champ) on the client is version 9.50.077.002, in case that helps.
  • 08-20-2007 7:27 AM In reply to

    Re: Trouble with PervasiveOLEDB 9.5 from dotNET C#

    OK...

    1) PSQL 9.50 running on the remote machine.
    2) Only 3 lines have been written to the PVSW.LOG on the remote machine in the last month since I have been trying to connect from the client. These don't seem to me to be related, but here they are:

    08-17-2007 10:56:22 Resources allocated
    08-17-2007 11:14:21 The file G:\RMSDATA\NARR.DAT is rolling back.
    08-17-2007 11:14:21 The file G:\RMSDATA\NARRHEAD.DAT is rolling back.
  • 08-20-2007 3:45 PM In reply to

    Re: Trouble with PervasiveOLEDB 9.5 from dotNET C#

    I was able to get an ODBC connection working from my C# code. The ODBC connection is much faster, and so far, 100% reliable. This will likely satisfy our requirement, but I would still be interested if anyone else can figure out why the OLE DB provider isn't working.

    Thanks!
  • 03-28-2013 3:54 AM In reply to

    Re: Trouble with PervasiveOLEDB 9.5 from dotNET C#

    Please can you elaborate, how you are connecting to pervasive database on remote location using ODBC. Your help is really appreciated. Thanks
Page 1 of 1 (8 items)