Update record with OLE connection : update « Database « Perl






Update record with OLE connection

   

#!c:/perl/bin

use Win32::OLE;
use Win32::OLE::Const 'Microsoft ActiveX Data Objects';

$table = "addresstable";
$conn = Win32::OLE->new("ADODB.Connection");
$rs   = Win32::OLE->new("ADODB.Recordset");

$conn->Open("address");
$conn->Execute("UPDATE $table SET address='A' WHERE firstname='A'");

print "Content-type: text/html\n\n";
print "Record Updated ...";

$rs->Close;
$conn->Close;

   
    
    
  








Related examples in the same category

1.Update a record in the database
2.Update statement and DBI ODBC connection