min_int AND NOT has_alarm AND NOT inactive"; // execute query $stmt = $con->prepare($query); $stmt->bindValue(':p1', $time, PDO::PARAM_INT); $succ = $stmt->execute(); if (!$succ) throw new Exception("Statement execution not succeeded"); return RemoteWatchdogPeer::populateObjects($stmt); } public function getWatchdogsToReset($time, PropelPDO $con = null) { if ($con === null) { $con = Propel::getConnection(RemoteWatchdogPeer::DATABASE_NAME, Propel::CONNECTION_READ); } $query = "select * from rem_wdog where (:p1 - last_ping) < min_int AND has_alarm"; // execute query $stmt = $con->prepare($query); $stmt->bindValue(':p1', $time, PDO::PARAM_INT); $succ = $stmt->execute(); if (!$succ) throw new Exception("Statement execution not succeeded"); return RemoteWatchdogPeer::populateObjects($stmt); } } // RemoteWatchdogQuery