mysql - Connecting php to mdb or sql on Mac locally -


i'm running local apache server on mac, , want connect local database (have same db both .sql , .mdb). php

$dbname = "\db\dbname.mdb"; $db = new pdo("odbc:driver={microsoft access driver (*.mdb)}; dbq=$dbname; uid=; pwd=;"); 

i have web stuff in local server , databases in db folder. if or explain how can done locally sql.

thanks!

working access database php can challenging @ best of times. on os x (or linux) more tenuous (in opinion) if 1 tries use middleware unixodbc , mdb tools.

if .sql file indeed mysql (as suggested 1 of question tags) you'll save fair bit of aggravation using local install of mysql server (instead of access .mdb) database storage.


Comments

Popular posts from this blog

windows - Single EXE to Install Python Standalone Executable for Easy Distribution -

c# - Access objects in UserControl from MainWindow in WPF -

javascript - How to name a jQuery function to make a browser's back button work? -