
sreedhargudur
New User
Mar 15, 2003, 3:20 PM
Post #1 of 2
(4757 views)
|
Execute Procedure in Perl
|
Can't Post
|
|
Hi, I am very new to this perl script and I need to solve this problem with in 2 days. So Can any one let me know the syntax's of perl to execute a procedure. The procedure does updating the values into table. proedure name: update_lang_iso_char_set.sql In perl I have written the code to initialize the database connection. use DBI; $dbh = undef; $dbh = DBI->connect( "dbi:Sybase" . ":interfaces=" . $ENV{'SYBASE'} . '/interfaces' . ";server=" . $ENV{'BV_DB_SERVER'} . ";database=" . $ENV{'BV_DB_DATABASE'} . ";hostname=" . $ENV{'HOSTNAME'} . ";scriptName=convTrans.pl" , $ENV{'BV_DB_USER'}, $ENV{'BV_DB_PASSWD'}, { PrintError => 1, AutoCommit => 1 } ); if (!$dbh) { die "Connection to DBMS could not be established"; exit 1; } @sql = update_lang_iso_char_set.sql; dbh->do(@sql); It is giving error and the sql file is stored under same path. Thanks in advance, Sreedhar
|