Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

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');


Comment on Re: Can I set the DSN for an ODBC connection?
Download Code
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.

    -Tats
      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?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (10)
As of 2014-11-25 22:29 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My preferred Perl binaries come from:














    Results (160 votes), past polls