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

Re: connecting Perl with MS SQL Server on NT using ODBC

by peacemaker1820 (Pilgrim)
on Jul 01, 2002 at 19:27 UTC ( [id://178654]=note: print w/replies, xml ) Need Help??


in reply to connecting Perl with MS SQL Server on NT using ODBC

Instead of the statement my $DSN...... use:
my ( $server_name, $database, $user_id, $password ) =qw ( SERVER DATABASE USER PASSWORD );

my $DSN = "driver={SQL Server}; Server=$server_name; Database=$database; UID=$user_id; PWD=$password";

  • Comment on Re: connecting Perl with MS SQL Server on NT using ODBC

Replies are listed 'Best First'.
Re: Re: connecting Perl with MS SQL Server on NT using ODBC
by Mission (Hermit) on Jul 02, 2002 at 13:19 UTC
    peacemaker1820,

    TIMTOWTDI

    I chose to post code that was legible from a beginner viewpoint, to hopefully help you and others (Anonymous Monk's | lurkers) who may not know what qw does. That's also the reson for the glorified comment tags. When I do research and development on something that is not functioning, I start with the basics until I get something to work, then I move up. That's how I do development, and that's why I posted simple code.

    If you still need assistance, feel free to /msg me.

    Welcome to the Monestary, peacemaker1820.

    - Mission

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others pondering the Monastery: (3)
As of 2024-04-16 05:46 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found