View Single Post
Old 08-16-2009, 07:13 PM  
Sex9
Confirmed User
 
Join Date: May 2007
Location: Los Angeles
Posts: 155
oops, just saw where you wanted y to always be 95% of x so I revised it a bit
$x = 1000;
$y = 950;
$result = mysql_query ("SELECT * FROM $table WHERE x > '$x' && y > '$y' ORDER BY id DESC");
$nRows = mysql_num_rows($result);

for ($i=0; $i< $nRows; $i++){
$row = mysql_fetch_array($result);
$theid = $row['id'];
$x2 = $row['x'];
$y2 = $row['y'];
if($y2 > ($x2 * .95)){
$query124 = "DELETE FROM $table WHERE id= '$theid'";
mysql_query($query124) or die;
}
}
__________________
The coolest Porn Tube
Sex9 is offline   Share thread on Digg Share thread on Twitter Share thread on Reddit Share thread on Facebook Reply With Quote