re: parallel execution of code

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



U might try omthing like this::

$query = "SELECT id FROM mytable WHERE bla LIKE " . $x .";

$result = mysql_query($query, $cnn) or die(mysql_error());
					
$totalRows_result = mysql_num_rows($result);
						
if($totalRows_result>0) {
      //display error tht id already exists
}
else
{

  //insert code goes here
}

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [Apache Users]     [PHP on Windows]     [Kernel Newbies]     [PHP Install]     [PHP Classes]     [Pear]     [Postgresql]     [Postgresql PHP]     [PHP on Windows]     [PHP Database Programming]     [PHP SOAP]

  Powered by Linux