MySQL Forums
Forum List  »  Italian

Problema con recupero dati
Posted by: Alberto Sinatra
Date: October 11, 2009 12:52PM

Ciao ragazzi.
Ho un problema con MySQL.
Praticamente ho dei dati su una tabella che non riesco a recuperare.
Per prova sto cercando di recuparare il valore massimo del campo 'id' tramite "SELECT MAX" ma no riesco.
Sicuramente sbaglio io qlks ma รจ tutto il giorno che ci provo e ne sto uscendo pazzo.

<?
$db_host = "localhost";
$db_user = "teamhydra";
$db_password = "";
$db_database = "my_teamhydra";
$db = mysql_connect($db_host,$db_user,$db_password);
mysql_select_db($db_database, $db);
$id1 = mysql_query("SELECT MAX(`id`) FROM `match`") or die(mysql_error());
mysql_close($db);
echo $id1;
?>



Edited 1 time(s). Last edit at 10/11/2009 12:52PM by Alberto Sinatra.

Options: ReplyQuote


Subject
Views
Written By
Posted
Problema con recupero dati
3936
October 11, 2009 12:52PM
2592
October 12, 2009 04:21PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.