Beefy Boxes and Bandwidth Generously Provided by pair Networks
Don't ask to ask, just ask

Re: Can I set the DSN for an ODBC connection?

by phydeauxarff (Priest)
on Jan 08, 2004 at 17:05 UTC ( #319867=note: print w/replies, xml ) Need Help??

in reply to Can I set the DSN for an ODBC connection?

There appears to be

This from the the docs for DBD::ODBC

use DBI; $dbh = DBI->connect('dbi:ODBC:DSN', 'user', 'password');

Replies are listed 'Best First'.
Re: Re: Can I set the DSN for an ODBC connection?
by Itatsumaki (Friar) on Jan 08, 2004 at 19:17 UTC

    I read the question to be asking for a way to actually create a DSN for an ODBC driver. I don't think that can be done via DBI at all. On the other hand, the syntax you gave is correct for accessing an ODBC source via DBI, which might be what was wanted. I'm not really clear what the OP is asking.

      ah...good point.

      I dug around and it seems that Win32::ODBC supports a ConfigDSN method to add a new DSN but I have no way to test such an animal in my working environ.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://319867]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others romping around the Monastery: (8)
As of 2016-10-26 14:14 GMT
Find Nodes?
    Voting Booth?
    How many different varieties (color, size, etc) of socks do you have in your sock drawer?

    Results (341 votes). Check out past polls.