There's a typo in your $DSN assignment where you swap ; and " - I can only assume that means you typed rather than copy/pasted your handle. Try this and see how it works. Note that to avoid escaping errors, I set a file name separately from my driver specification.
my $filename = 'Z:\\temp\KernelLog.mdb'; my $dsn = "dbi:ODBC:driver=Microsoft Access Driver (*.mdb); dbq=$filen +ame"; my $dbh = DBI->connect( $dsn, '', '', { PrintError => 1, RaiseError => 0, AutoCommit => 0, } ) or die "DB connect failed $DBI::errstr.";
As a coincidence, I am just now migrating an Access database to Oracle. An Access database with non-alphanumeric table and column names. Oy.
Update: Your issue appears to be that your driver specification requires a space between Driver and (*.mdb).
In reply to Re: How do I connect to MS Access database
by kennethk
in thread How do I connect to MS Access database
by pravlm
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |