Hi,
I am trying to update a db using adodb module. The query seems to be fine
and I tested this on db directly.
But when I run the same query thru Perl it is not working. I.e database is
not getting updated. It not returning any error also.
Can someone pls let me know hat the problem could be?
Thanks a lot for your help,
Paramesh
use strict;
use Win32;
use Win32::OLE;
my $Pass = $_[0];
my $Fail = $_[1];
my $LogPath = qw( \\paramesh\log\68\0217\\ );
my $conn = new Win32::OLE("ADODB.Connection");
my $RS = "";
my %Response;
$conn->Open(<<EOT);
Data Source=Brooktest1;
Provider=SQLOLEDB.1;
Password=valid;
Persist Security Info=True;
User ID=user;
Initial Catalog=mydb;
EOT
if($conn->Errors->{Count} > 0)
{
print "Error while attempting a connection to db: "
$conn->Errors(0);
}
my $query = "UPDATE LogTbl set PassCount=\'10\', FailCount=\'21\'
where (LogPath LIKE \'$LogPath\')";
print $query;
$conn->Execute($query) || die "Failed to update db: " .
Win32::OLE->LastError();
_______________________________________________
ActivePerl mailing list
[EMAIL PROTECTED]
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs