First, read the examples at the bottom of DBD::ODBC pod file
(visible when you do
perldoc DBD::ODBC.
You will find the file contains links to a number of documents
about DBD::ODBC. (I won't repeat the links - it's better if you read the doc).
It also contains this example:
my $DSN = 'driver=Microsoft Access Driver (*.mdb);dbq=\\\\cheese\\g$\\
+perltest.mdb';
my $dbh = DBI->connect("dbi:ODBC:$DSN", '','') or die "$DBI::errstr\n"
+;
As well as caveats about what you should check if
the connection is failing.