Page 1 of 1

dsn-less connection , php to a ms-access database in linux

Posted: Tue Jun 12, 2007 6:30 am
by jayakrishnan
Hi

My first post here. I created a small project using php+ms access+apache under windows and used the following code to connect to the access database

Code: Select all

$db_conn = new COM("ADODB.Connection");
$connstr = "DRIVER={Microsoft Access Driver (*.mdb)}; DBQ=". realpath("./auth.mdb").";";
$db_conn->open($connstr);
We have now moved to a linux server which obviously wont support the above code as it uses COM. Is there any way to create dsn-less connection to access database under linux using php?

Thanks & Regards
JayaKrishnan

Posted: Tue Jun 12, 2007 9:11 am
by timvw
(afaik) you'll have to search for the 'unix'-odbc driver and go down the odbc route...