Hernan Arredondo wrote:
Hi all, I'm new in DBI and I'm really stuck, some can explain me this
code:
use DBI;
my $dbh = DBI->connect( 'dbi:Oracle:db',
'$username',
'$passwd',
) or die "$DBI::errstr";
EOF
Hi all, I'm new in DBI and I'm really stuck, some can explain me this
code:
use DBI;
my $dbh = DBI->connect( 'dbi:Oracle:db',
'$username',
'$passwd',
) or die "$DBI::errstr";
EOF
$passwd, which means you are passing those literal strings as the username
and password, rather than the contents of the variables. You don't need
quotes at all around individual variables:
my $dbh = DBI->connect( 'dbi:Oracle:db',
$username,
$passwd,
) or die $DBI::errstr;
(with the correct SID still needing to be inserted)
Ronald