[wp-testers] mysql_insert_id() problem?
Stefano
steagl at people.it
Tue Jan 31 11:37:11 GMT 2006
ON italian wp forum an user asked us about this:
The PHP manual state:
Caution:
mysql_insert_id() converts the return type of the native MySQL C API
function mysql_insert_id() to a type of long (named int in PHP). If
your AUTO_INCREMENT column has a column type of BIGINT, the value
returned by mysql_insert_id() will be incorrect. Instead, use the
internal MySQL SQL function LAST_INSERT_ID() in an SQL query.
At line 162 of wp-db.php there is:
$this->insert_id = mysql_insert_id($this->dbh);
ad in the database quite every ID filed is a Bigint(20).
Should there is needs for a chamge to this line or it's all ok ?
I didn't opened a ticket about this before to hear your suggestion.
--
Stefano Aglietti - StallonIt on IRCnet - ICQ#: 2078431
Email: steve at 40annibuttati.it steagl at people.it
Sites: http://www.40annibuttati.it
http://www.wordpress-it.it
More information about the wp-testers
mailing list