Help for this page

Select Code to Download


  1. or download this
    my $iface_result = $dbh->prepare("UPDATE device_iface_cache SET interf
    +ace_status='$stat', lastcheck='$date', hostname='$host' WHERE hostnam
    +e='$host' AND interface_name='$int_table{$key}';");
    $iface_result->execute();
    
  2. or download this
    my $iface_result = $dbh->prepare("UPDATE device_iface_cache SET interf
    +ace_status=?, lastcheck=? WHERE hostname=? AND interface_name=?");
    $iface_result->execute($stat, $date, $host, $int_table{$key});
    
  3. or download this
    $db->update('device_iface_cache',
        { interface_status => $stat, lastcheck => $date },
        { hostname => $host, interface_name => $int_table{$key} }
    );