0

Hi All,

Can anyone please help me.
I am trying to connect to a Pervasive SQL v9 database using a PHP script.
I have been trying for hours to make a connection but all my browsers keep loading with no response from the server.
The PHP code is as follows:

$sConnection = odbc_connect("DRIVER={Pervasive ODBC Engine Interface};ServerName=127.0.0.1;DBQ=wmtest;","Master","master");
if(!$sConnection) die("Could not connect<br>");
else die('Connected');

Strangely, i tried using this script on a Windows 7 machine, and it worked but now i am on a Windows Vista, it won't work.

Thanks in advance.

1
Contributor
1
Reply
8
Views
6 Years
Discussion Span
Last Post by wilch
0

I think i finally solved the problem after some clues from the internet.
Solution:
I had to copy the 4 dll files:
- w3odbcci.dll
- w3odbccs.dll
- w3odbcei.dll
- w3odbces.dll
from the pervasive bin directory to a new folder c:\perv_ext\
I then included this directory in my php.ini file, by altering the 'extension_dir' to also include c:\perv_ext
I restarted my webserver, and i saw my script being executed and the connection had gone through.
Thanks.

This question has already been answered. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.