<?
  include 'include/db.php';
  include 'include/connect.php';
  //$today = date("m/d/Y");
  mysql_query("BEGIN");
  $s = $db->findByPK('tbtrip','trip_ex','0')->execute();
  while($aa = mysql_fetch_assoc($s)){
      $data['trip_wait'] = '0';
      $tup = $db->update('tbiv',$data,'iv_id',$aa['trip_id']);
      if($tup){
        mysql_query("COMMIT");
        echo 'ได้';
      } else {
        mysql_query("ROLLBACK");
        echo "พัง";
      }
  }
?>